Skip to content

Commit

Permalink
removing if (false) statement
Browse files Browse the repository at this point in the history
  • Loading branch information
remibettan committed Oct 27, 2022
1 parent 553b39e commit 9c1c3ab
Showing 1 changed file with 0 additions and 36 deletions.
36 changes: 0 additions & 36 deletions src/ds5/ds5-device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1129,42 +1129,6 @@ namespace librealsense
lazy<float>([default_depth_units]()
{ return default_depth_units; })));
}

// D457 dev - auto gain and exposure limits disabled for all devices
if (false) // D457 dev - this condition should be removed after bug resolved in FW
{
// Auto exposure and gain limit
if (_fw_version >= firmware_version("5.12.10.11"))
{
auto exposure_range = depth_sensor.get_option(RS2_OPTION_EXPOSURE).get_range();
auto gain_range = depth_sensor.get_option(RS2_OPTION_GAIN).get_range();

option_range enable_range = { 0.f /*min*/, 1.f /*max*/, 1.f /*step*/, 0.f /*default*/ };

//GAIN Limit
auto gain_limit_toggle_control = std::make_shared<limits_option>(RS2_OPTION_AUTO_GAIN_LIMIT_TOGGLE, enable_range, "Toggle Auto-Gain Limit", *_hw_monitor);
_gain_limit_value_control = std::make_shared<auto_gain_limit_option>(*_hw_monitor, &depth_sensor, gain_range, gain_limit_toggle_control);
depth_sensor.register_option(RS2_OPTION_AUTO_GAIN_LIMIT_TOGGLE, gain_limit_toggle_control);

depth_sensor.register_option(RS2_OPTION_AUTO_GAIN_LIMIT,
std::make_shared<auto_disabling_control>(
_gain_limit_value_control,
gain_limit_toggle_control

));

// EXPOSURE Limit
auto ae_limit_toggle_control = std::make_shared<limits_option>(RS2_OPTION_AUTO_EXPOSURE_LIMIT_TOGGLE, enable_range, "Toggle Auto-Exposure Limit", *_hw_monitor);
_ae_limit_value_control = std::make_shared<auto_exposure_limit_option>(*_hw_monitor, &depth_sensor, exposure_range, ae_limit_toggle_control);
depth_sensor.register_option(RS2_OPTION_AUTO_EXPOSURE_LIMIT_TOGGLE, ae_limit_toggle_control);

depth_sensor.register_option(RS2_OPTION_AUTO_EXPOSURE_LIMIT,
std::make_shared<auto_disabling_control>(
_ae_limit_value_control,
ae_limit_toggle_control
));
}
}
}); //group_multiple_fw_calls


Expand Down

0 comments on commit 9c1c3ab

Please sign in to comment.