-
Notifications
You must be signed in to change notification settings - Fork 4.9k
revise dds metadata handling with overrides & depth-units #12394
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
{ | ||
if( auto value = rsutils::json::nested( md, keystr ) ) | ||
{ | ||
if( value->is_number_integer() ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we will get something else, don't we want to infrom the user?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No. This is metadata; we ignore anything we cannot parse.
Same behavior as before -- just doesn't throw exceptions as much (which in Debug mode are constantly triggered).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we getting bad values in debug? DDS layer is supposed to check the message...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, the exceptions were when we just didn't find the values for the metadata
for (auto&& p : s->get_stream_profiles()) | ||
profiles.push_back(p.get()); | ||
for( auto const & s : _software_sensors ) | ||
for( auto const & p : s->_sw_profiles ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Calling get_raw_stream_profiles()
is clearer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't exist any more :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is get_stream_profiles()
or something like it but it returns a vector, not a reference. Since we're a software device and these are software sensors, I elected to access directly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
nested
functionality inrsutils::json
(TS: C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 C0 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR4 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 IR6 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 D2 M8 M8)
(TS: C0 D2 IR4 IR6)
DLR_C
matcher, which is also overridable in the settings0.001
, without which depth shows up as blackTracked on [LRS-956]