Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

do not modify parameters unless explicitly set #24

Merged

Conversation

rjw57
Copy link
Contributor

@rjw57 rjw57 commented Nov 18, 2014

The contrast, saturation, brightness, sharpness and focus parameters were recently added to usb_cam in b25c293. This caused a regression for us (sigproc/robotic_surgery#17) whereby, unless reset explicitly, the default settings for a webcam are overridden in all cases by the hard-coded defaults in usb_cam. This caused a previously working setup to start behaving very strangely.

It's probably near impossible to find a set of "known good" defaults for all cameras and so this PR changes the behaviour of the node to simply avoid setting the contrast, saturation, etc unless they've been explicitly set in the launch file. This is an application of the "principle of least surprise".

The contrast, saturation, brightness, sharpness and focus parameters
were recently added to usb_cam. This caused a regression
(sigproc/robotic_surgery#17) whereby the default settings for a webcam
are overridden in all cases by the hard-coded defaults in usb_cam.

In the absence of a know good set of "default" values, leave the
parameters unset unless the user has explicitly set them in the launch
file.
@rjw57
Copy link
Contributor Author

rjw57 commented Nov 18, 2014

In case this PR is not appropriate, I have also documented the previously undocumented parameters on the wiki page.

rctoris added a commit that referenced this pull request Nov 18, 2014
do not modify parameters unless explicitly set
@rctoris rctoris merged commit d50fd40 into ros-drivers:develop Nov 18, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants