Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion common/option-model.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,8 @@ bool option_model::draw( std::string & error_message,
}

auto advanced = dev->dev.as< rs400::advanced_mode >();
if( opt == RS2_OPTION_HDR_ENABLED && advanced && advanced.is_enabled() )
auto supports_auto_hdr = std::string(dev->dev.get_info(RS2_CAMERA_INFO_NAME)).find("D45") != std::string::npos; // auto HDR is only supported on D45*
if( opt == RS2_OPTION_HDR_ENABLED && advanced && advanced.is_enabled() && supports_auto_hdr)
{
ImGui::SameLine( 0, 10 );

Expand Down
6 changes: 6 additions & 0 deletions src/ds/advanced_mode/advanced_mode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -878,6 +878,12 @@ namespace librealsense

void ds_advanced_mode_base::set_hdr_preset(const preset& p)
{
auto& dev = _depth_sensor.get_device();
if (!dev.supports_info(RS2_CAMERA_INFO_NAME) ||
dev.get_info(RS2_CAMERA_INFO_NAME).find("D45") == std::string::npos)
{
throw std::runtime_error("HDR preset is not supported on the connected device"); // feature only works for D45* cameras
}
// if auto exposure is not enabled, enable it if needed - temporary W/A until FW enable it
auto& auto_exp = _depth_sensor.get_option(RS2_OPTION_ENABLE_AUTO_EXPOSURE);
if (auto_exp.get_value() == 0 && p.auto_hdr.is_auto)
Expand Down
3 changes: 2 additions & 1 deletion unit-tests/live/d400/test-hdr-preset.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# License: Apache 2.0. See LICENSE file in root directory.
# Copyright(c) 2025 RealSense, Inc. All Rights Reserved.

# test:device D400*
#test:device:jetson D457
#test:device:!jetson D455

import pyrealsense2 as rs
from rspy import test, log
Expand Down
Loading