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

Document how plugins should transform data #915

Open
wants to merge 2 commits into
base: rolling
Choose a base branch
from

Conversation

sloretz
Copy link
Contributor

@sloretz sloretz commented Oct 5, 2022

Resolves #894

This documents how display plugins should handle time and transforms.

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
@sloretz sloretz self-assigned this Oct 5, 2022
@sloretz
Copy link
Contributor Author

sloretz commented Oct 5, 2022

Since this is only changing a markdown file, I think the PR job is enough CI.

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
```

Data without an associated time should be transformed using one of the functions that does not accept a time.
This will use the latest available transform data.
Copy link
Member

Choose a reason for hiding this comment

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

I'm wondering if this is the right thing to do. It may be that's what we're doing historically, but we do also have the sent and (sometimes) the received timestamps in the message info. One or both of these is likely to be more accurate.

There is an assumption with the current text that the time between the data being sent, being received, and being rendered are all very small. Which hopefully is the case, but maybe not.

Copy link
Member

Choose a reason for hiding this comment

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

So maybe just a mention that you should try to use the time sources in this order:

  • from a Header
  • the sent timestamp
  • the received timestamp
  • no time (latest transform)

I'm not sure there's really any situation where you have no timestamp, but it could be possible if the data comes from something other than a ROS topic (maybe a service call or maybe the user clicking on the screen or something).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Should have discoverable documentation on tf2::TimePointZero vs. other constructs
2 participants