From 5714a40e2c20c5e298983b4944233575c9becc3f Mon Sep 17 00:00:00 2001 From: Remi Bettan Date: Wed, 1 Jan 2025 15:26:35 +0200 Subject: [PATCH] cr --- tools/depth-quality/depth-quality-model.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tools/depth-quality/depth-quality-model.cpp b/tools/depth-quality/depth-quality-model.cpp index fb37b79f4d..5eeadad23f 100644 --- a/tools/depth-quality/depth-quality-model.cpp +++ b/tools/depth-quality/depth-quality-model.cpp @@ -46,8 +46,7 @@ namespace rs2 rs2::pipeline_profile active_profile; // Adjust settings according to USB type - bool usb3_device = true; - bool usb_device = false; + bool usb2_device = false; auto devices = _ctx.query_devices(); if (devices.size()) { @@ -57,16 +56,15 @@ namespace rs2 auto connection_type = dev.get_info(RS2_CAMERA_INFO_CONNECTION_TYPE); if (connection_type == std::string("USB") && dev.supports(RS2_CAMERA_INFO_USB_TYPE_DESCRIPTOR)) { - usb_device = true; std::string usb_type = dev.get_info(RS2_CAMERA_INFO_USB_TYPE_DESCRIPTOR); - usb3_device = !(std::string::npos != usb_type.find("2.")); + usb2_device = (std::string::npos != usb_type.find("2.")); } } } else return valid_config; - int requested_fps = (usb3_device || !usb_device) ? 30 : 15; + int requested_fps = usb2_device ? 15 : 30; // open Depth and Infrared streams using default profile {