How to obtain the time corresponding to the pose while obtaining the pose data?
How to obtain the time corresponding to the pose while obtaining the pose data?
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#).