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

How to obtain the time corresponding to the pose while obtaining the pose data? #1

Open
YongD0ng opened this issue Mar 3, 2022 · 1 comment

Comments

@YongD0ng
Copy link

YongD0ng commented Mar 3, 2022

How to obtain the time corresponding to the pose while obtaining the pose data?

@ebadier
Copy link
Owner

ebadier commented Mar 3, 2022

Good Question !
The TrackedDevicePose_t struct I use from openvr_api.cs to get pose data doesn't have a timestamp and I didn't found another way to get pose data with a timestamp. If you find one, I would be happy to implement it !

Another solution is to timestamp ourselves directly on the Unity side, when I effectively get pose data from TrackedDevicePose_t each frame. But even if C# offers high resolution clock APIs, such timestamping mechanism will not be accurate when Context Switching occurs (the application switch from one CPU core to another, and it occurs frequently with managed code like C#).

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

No branches or pull requests

2 participants