Skip to content

Add feature-interface to sensors #12384

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

Merged
merged 13 commits into from
Nov 26, 2023

Conversation

OhadMeir
Copy link
Contributor

@OhadMeir OhadMeir commented Nov 9, 2023

Added support_feature API to sensors.
Features derive from feature_interface and concrete sensor determines support for individual features.

Features can act as a flag to other logic about need to act in a certain way, or even have the logic implementation embodied.

@OhadMeir OhadMeir requested review from maloel and Nir-Az November 9, 2023 10:11

namespace librealsense {

class synthetic_sensor;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it requires roi_sensor_interface, why not put that right in the interface?


void register_feature( const std::string id, std::shared_ptr< feature_interface > feature )
{
_features[id] = feature;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It'll override any previous value... ok?

@OhadMeir OhadMeir merged commit 5fca898 into IntelRealSense:development Nov 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants