diff --git a/include/librealsense2/h/rs_frame.h b/include/librealsense2/h/rs_frame.h index 51c8df2213..d8edfe6078 100644 --- a/include/librealsense2/h/rs_frame.h +++ b/include/librealsense2/h/rs_frame.h @@ -72,6 +72,7 @@ typedef enum rs2_frame_metadata_value RS2_FRAME_METADATA_INPUT_WIDTH, RS2_FRAME_METADATA_INPUT_HEIGHT, RS2_FRAME_METADATA_SUB_PRESET_INFO, + RS2_FRAME_METADATA_CALIB_INFO, RS2_FRAME_METADATA_CRC, RS2_FRAME_METADATA_COUNT diff --git a/src/ds5/ds5-device.cpp b/src/ds5/ds5-device.cpp index cfc1a0445d..af3f2eaea9 100644 --- a/src/ds5/ds5-device.cpp +++ b/src/ds5/ds5-device.cpp @@ -1314,10 +1314,14 @@ namespace librealsense make_attribute_parser(&md_mipi_depth_mode::input_height, md_mipi_depth_control_attributes::input_height_attribute, md_prop_offset)); - depth_sensor.register_metadata(RS2_FRAME_METADATA_SUB_PRESET_INFO, // added for mipi + depth_sensor.register_metadata(RS2_FRAME_METADATA_SUB_PRESET_INFO, make_attribute_parser(&md_mipi_depth_mode::sub_preset_info, md_mipi_depth_control_attributes::sub_preset_info_attribute, md_prop_offset)); + depth_sensor.register_metadata(RS2_FRAME_METADATA_CALIB_INFO, + make_attribute_parser(&md_mipi_depth_mode::calib_info, + md_mipi_depth_control_attributes::calibration_info_attribute, + md_prop_offset)); depth_sensor.register_metadata(RS2_FRAME_METADATA_CRC, // added for mipi make_attribute_parser(&md_mipi_depth_mode::crc, md_mipi_depth_control_attributes::crc_attribute, diff --git a/src/metadata.h b/src/metadata.h index 91e17dabea..f28d17a661 100644 --- a/src/metadata.h +++ b/src/metadata.h @@ -136,7 +136,8 @@ namespace librealsense input_width_attribute = (1u << 10), input_height_attribute = (1u << 11), sub_preset_info_attribute = (1u << 12), - crc_attribute = (1u << 13) + calibration_info_attribute = (1u << 13), // shall be used to stire the frame counter in calibration routines + crc_attribute = (1u << 14) }; /**\brief md_mipi_rgb_control_attributes - bit mask to find active attributes, @@ -368,7 +369,9 @@ namespace librealsense struct md_mipi_depth_mode { md_header header; - uint32_t version; // maybe need to replace by uint8_t for version and 3 others for reserved + uint8_t version; // maybe need to replace by uint8_t for version and 3 others for reserved + uint16_t calib_info; + uint8_t reserved; uint32_t flags; // Bit array to specify attributes that are valid uint32_t hw_timestamp; uint32_t optical_timestamp; //In microsecond unit diff --git a/src/to-string.cpp b/src/to-string.cpp index 1740b7bc8c..b28ded5b9b 100644 --- a/src/to-string.cpp +++ b/src/to-string.cpp @@ -530,6 +530,7 @@ const char * get_string( rs2_frame_metadata_value value ) CASE( INPUT_WIDTH ) CASE( INPUT_HEIGHT ) CASE( SUB_PRESET_INFO ) + CASE( CALIB_INFO ) CASE( CRC ) default: