ViveTrackers icon indicating copy to clipboard operation
ViveTrackers copied to clipboard

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

Open YongD0ng opened this issue 3 years ago • 1 comments

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

YongD0ng avatar Mar 03 '22 08:03 YongD0ng

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#).

ebadier avatar Mar 03 '22 12:03 ebadier