Skip to content
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

Enable applying render callbacks for specific cameras #19

Open
DavidPL1 opened this issue Feb 17, 2023 · 2 comments
Open

Enable applying render callbacks for specific cameras #19

DavidPL1 opened this issue Feb 17, 2023 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@DavidPL1
Copy link
Contributor

Based on a discussion about #17 we decided that we should somehow define which plugins should render to which cameras.

Use case example:
Two cameras are defined: workspace_cam and demo_cam.
We have to plugins that implement the render callback: plugin_a and plugin_b.
plugin_a renders objects that should be captured by all cameras and should be processed. plugin_b renders a helpful visualization that should not be processed by a data pipeline and thus should only be rendered on the image of camera demo_cam.

The current Idea is to

  • define which level of information (e.g. 0=data_relevant, 10=visualization) is rendered by a plugin (should be defined either in the plugin config or in the render callback)
  • and include a flag in the camera definition to set which information levels should be rendered. The flag should default to render only data relevant information.
  • A higher level of information should always contain all lower levels.
@DavidPL1 DavidPL1 added the enhancement New feature or request label Feb 17, 2023
@rhaschke
Copy link
Member

Hm. This introduction of information levels seems to be rather brittle. Why not explicitly specify for each camera, which plugins (by name) should get processed? I suggest defaulting to all, but allowing for exclusions as this seems to be more common?

@DavidPL1
Copy link
Contributor Author

Depends on where the lists of plugin names is configured.
The idea was not to cause too much overhead to enable/disable rendering plugin output and keep configurations as genericly applicable as possible. For instance, I wouldn't like specifying this explicitly in the model file, as it would tailor the model to a specific plugin setup.

But I'm also not a 100% convinced of the information level approach.

We could include this in the camera config on the parameter server, as it is a separate config that is also easily changeable e.g.:

cam_config:
  gripper_cam: # Will display content rendered by plugins except for ExamplePlugin0 and ExamplePlugin3
    stream_type: 3 # RGB and DEPTH
    frequency: 15
    width: 1080
    height: 720
    allow_plugin_rendering: true
    exclude_plugin_list:
      - ExamplePlugin0
      - ExamplePlugin3
  workspace_cam: # Will not display anything rendered by plugins
    stream_type: 3 # RGB and DEPTH
    frequency: 15
    width: 1080
    height: 720
  demo_cam: # Will display everything rendered by plugins
    stream_type: 3 # RGB and DEPTH
    frequency: 15
    width: 1080
    height: 720
    allow_plugin_rendering: true

However, I would disable plugin rendering by default, introduce a flag to enable it (e.g. allow_plugin_rendering above) and then use an exclude list.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants