mirror of
https://github.com/orbbec/OrbbecSDK_ROS2.git
synced 2026-10-04 20:17:47 +08:00
fix: skip setting AE ROI for color and depth based on reference stream
This commit is contained in:
@@ -3154,6 +3154,12 @@ void OBCameraNode::setDepthAutoExposureROI() {
|
|||||||
if (depth_roi_has_run) {
|
if (depth_roi_has_run) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (isGemini305SeriesPID(pid_) && ae_reference_stream_ == "color") {
|
||||||
|
RCLCPP_WARN_STREAM(logger_,
|
||||||
|
"Skip setting depth AE ROI because AE Reference Stream is color");
|
||||||
|
depth_roi_has_run = true;
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (device_->isPropertySupported(OB_STRUCT_DEPTH_AE_ROI, OB_PERMISSION_READ_WRITE)) {
|
if (device_->isPropertySupported(OB_STRUCT_DEPTH_AE_ROI, OB_PERMISSION_READ_WRITE)) {
|
||||||
auto config = OBRegionOfInterest();
|
auto config = OBRegionOfInterest();
|
||||||
uint32_t data_size = sizeof(config);
|
uint32_t data_size = sizeof(config);
|
||||||
@@ -3194,6 +3200,12 @@ void OBCameraNode::setColorAutoExposureROI() {
|
|||||||
if (color_roi_has_run) {
|
if (color_roi_has_run) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (isGemini305SeriesPID(pid_) && ae_reference_stream_ == "depth") {
|
||||||
|
RCLCPP_WARN_STREAM(logger_,
|
||||||
|
"Skip setting color AE ROI because AE Reference Stream is depth");
|
||||||
|
color_roi_has_run = true;
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (device_->isPropertySupported(OB_STRUCT_COLOR_AE_ROI, OB_PERMISSION_READ_WRITE)) {
|
if (device_->isPropertySupported(OB_STRUCT_COLOR_AE_ROI, OB_PERMISSION_READ_WRITE)) {
|
||||||
auto config = OBRegionOfInterest();
|
auto config = OBRegionOfInterest();
|
||||||
uint32_t data_size = sizeof(config);
|
uint32_t data_size = sizeof(config);
|
||||||
|
|||||||
Reference in New Issue
Block a user