Overview

Request 772200 superseded

- opendev() in input_v4l.c functional execution is not implemented
as described by the output messages it can display. One results
is that it reads the configuration width and height settings and
prepares them as the video source settings. But, it makes two
unrelated attempts to set the video device source channel and
if the second one succeeds it reads the current device grab
window settings into the same structure it used to load the
configuration, overwriting and losing the configuration. It then
sets the grab window using the value it just got from the same
device, i.e. redundant set device grab window to current grab
window. It has the effect that if another video application is
used before running camsource and for the device camsource will
use and the other application uses frame resolution different
from that in the camsource configuration then the application
exited and camsource started the frame resolution used by
camsource will be that used by the other application and not that
in the camsource configuration
- When reading what can be output to the console from the second
set channel it says the "set grab window failed: Trying _again_
without the fps option" and performs a "set grab window"
operation as the supposed "again" of a set video channel
operation (when a full set video channel was already performed
earlier in the code anyway).
I modified the logic to operate as the messaging describes:
* Perform a "get grab window" before loading the configuration
* Load the configuration over the get grab window result
* Perform a "set grab window" with the fps option
* If that "set grab window" fails:
* Perform a "set grab window" _again_ but without the fps
Matching the behavior described in the messaging and without losing the config

Loading...

Stefan Brüns's avatar

Please shorten the changelog.

Put the patch description in the patch header (git format). Also, remove the whitespace only changes from the patch.


David Mair's avatar

It depends what you mean by "whitespace only changes". Several lines have space indents in the location of tab indented surrounding code (the majority of the source is tab indented) making absurd appearance in an editor (conditional with higher indentation than the block it makes conditional). We can fight about it but the space indented code is broken source even though it is compile time functional.


David Mair's avatar

I believe as requested at submit request 772215

Request History
David Mair's avatar

dmair created request

- opendev() in input_v4l.c functional execution is not implemented
as described by the output messages it can display. One results
is that it reads the configuration width and height settings and
prepares them as the video source settings. But, it makes two
unrelated attempts to set the video device source channel and
if the second one succeeds it reads the current device grab
window settings into the same structure it used to load the
configuration, overwriting and losing the configuration. It then
sets the grab window using the value it just got from the same
device, i.e. redundant set device grab window to current grab
window. It has the effect that if another video application is
used before running camsource and for the device camsource will
use and the other application uses frame resolution different
from that in the camsource configuration then the application
exited and camsource started the frame resolution used by
camsource will be that used by the other application and not that
in the camsource configuration
- When reading what can be output to the console from the second
set channel it says the "set grab window failed: Trying _again_
without the fps option" and performs a "set grab window"
operation as the supposed "again" of a set video channel
operation (when a full set video channel was already performed
earlier in the code anyway).
I modified the logic to operate as the messaging describes:
* Perform a "get grab window" before loading the configuration
* Load the configuration over the get grab window result
* Perform a "set grab window" with the fps option
* If that "set grab window" fails:
* Perform a "set grab window" _again_ but without the fps
Matching the behavior described in the messaging and without losing the config


David Mair's avatar

dmair superseded request

- The camsource v4l1 module has logic errors opening the video
device that incorrectly perform a channel set when a grab window
set (frame size, fps, etc) is intended. The error handling from
the invalid channel set causes the configuration frame size and
fps settings to be discarded and replaced with the current
settings active on the video device. The result is that running a
v4l(1/2) application on a given camera before using camsource on
the same camera means camsource has the grab window attributes
from the other application not the one specified in camsource
configuration
- camsource-v4l-conf-video_window-overwrite.patch

openSUSE Build Service is sponsored by