Forum Discussion
davidwyandgg
12 years agoExplorer
Using SensorFusion Prediction
Hey Rift Peeps.
I'm interested in making use of the C++ SDK's SensorFusion prediction feature and I had a couple of questions:
1. What are the units for the SensorFusion::SetPrediction()'s dt parameter? Is it in seconds, or ms? I thought of using SensorFusion::GetPredictionDelta() to determine this, but by default it returns a value of 0, so I couldn't guess on the units.
2. I assume that I should be using SensorFusion::GetPredictedOrientation() rather than SensorFusion::GetOrientation() when I want to use the predicted value?
None of the C++ examples make use of SensorFusion prediction so I didn't have anything to reference. I see that the Unity demo does allow you to adjust the prediction amount, so that may be something to add as an option to the C++ demos too, just for an example of usage.
Thanks!
- Dave
I'm interested in making use of the C++ SDK's SensorFusion prediction feature and I had a couple of questions:
1. What are the units for the SensorFusion::SetPrediction()'s dt parameter? Is it in seconds, or ms? I thought of using SensorFusion::GetPredictionDelta() to determine this, but by default it returns a value of 0, so I couldn't guess on the units.
2. I assume that I should be using SensorFusion::GetPredictedOrientation() rather than SensorFusion::GetOrientation() when I want to use the predicted value?
None of the C++ examples make use of SensorFusion prediction so I didn't have anything to reference. I see that the Unity demo does allow you to adjust the prediction amount, so that may be something to add as an option to the C++ demos too, just for an example of usage.
Thanks!
- Dave
4 Replies
- mikeantHonored GuestThe prediction value is in seconds; a value such as 0.04f can help the experience - it's good to keep it a bit lower then overall latency though. You'll indeed need to call GetPredictedOrientation() to get the result. Sorry for lack of information here; we''ll update the comments and will plan to add it to the sample.
Thank you,
Michael - davidwyandggExplorerThanks for the info, Michael. I can now move forward with adding sensor prediction to Torque 3D.
- Dave - sthHonored GuestJust a quick note:
As of v0.2.3 of the SDK, the documentation still doesn't mention any of this (you only find it by studying the demo applications). Given the dramatic impact motion prediction has on perceived latency, it would be great if this could be added to the documentation. - AngelJExplorerI wouldn't have known about this if you hadn't resurrected this thread sth, thanks! You're right, this is not very well documented.
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 6 years ago