Some SR300 camera settings (get_option/set_option) fail
| Required Info | |
|---|---|
| Camera Model | SR300 |
| Firmware Version | 3.15.0.0 |
| Operating System & Version | Windows 10 |
| Build System | VS2013 |
I was working on the RS300 camera and did some research on the SR300 Only Camera settings.
It seems like the values recieved by 'get_option_range' do not return the correct values.
(See below)
When I try to set one of the mentioned parameters (except for SR300_AUTO_RANGE_ENABLE_LASER and SR300_AUTO_RANGE_ENABLE_MOTION_VERSUS_RANGE)
the program crashes with an 'rs::error at memory location 0x000000197ADDE300' error.
I suppose that the range and steps are not correctly recieved from the RS300 camera edit : I checked the source of the 'get_option_range' command. It seems that those values are just hardcoded in f200.cpp . I guess that the parameter were not determined yet , and those are just placeholders ?
The error is then coused by setting an invalid parameter.
Is this a common problem with the librealses and SR300 and/or is there a workaround ?
Moreover, is there a documentation specifying the valid ranges and behaviors of each of these parameters ?
> rs.info: Reading option SR300_AUTO_RANGE_ENABLE_LASER
> min 0 max 1 step 1
> rs.info: Reading option SR300_AUTO_RANGE_ENABLE_MOTION_VERSUS_RANGE
> min 0 max 2 step 1
> rs.info: Reading option SR300_AUTO_RANGE_LOWER_THRESHOLD
> min 0 max 65535 step 1
> rs.info: Reading option SR300_AUTO_RANGE_MAX_LASER
> min -32768 max 32767 step 1
> rs.info: Reading option SR300_AUTO_RANGE_MAX_MOTION_VERSUS_RANGE
> min -32768 max 32767 step 1
> rs.info: Reading option SR300_AUTO_RANGE_MIN_LASER
> min -32768 max 32767 step 1
> rs.info: Reading option SR300_AUTO_RANGE_MIN_MOTION_VERSUS_RANGE
> min -32768 max 32767 1
> rs.info: Reading option SR300_AUTO_RANGE_START_LASER
> min -32768 max 32767 step 1
> rs.info: Reading option SR300_AUTO_RANGE_START_MOTION_VERSUS_RANGE
> min -32768 max 32767 step 1
SR300_AUTO_RANGE family of options is different from standard options. For once, the firmware is expecting to accept new values to all AUTO_RANGE options as a bulk, and it makes little sense to assign values to them one by one. In addition, it is very hard to determine the visual effect of each individual parameter. Intel Algo team has defined a set of suggested combinations, refered in librealsense as ivcam_presets. Here is a list of presets, with each preset being is optimized for a specific usage: ShortRange LongRange BackgroundSegmentation GestureRecognition ObjectScanning FaceAnalytics FaceLogin GRCursor Default MidRange IROnly Please see rsutils.h - rs_apply_ivcam_preset for the corresponding values of AUTO_RANGE options. It is not recommended to set AUTO_RANGE options by hand, and the fact that they are exposed in librealsense API as individual options is more of a technical constraint to enable rsutils.h rather then an intentional design decision. It is likely those options will get deprecated in the future, in favor of using presets. (obviously, if you wish to tinker with them you are still welcomed to, librealsense is an open-source)