Forum Discussion
MattPeddlesden
11 years agoHonored Guest
Rotation Tracking Problem
Hi, I'm having a problem with rotation tracking - but before I get to the current issue, let me describe an issue I had during initial integration as I have a rumble in my tummy that my solution wa...
cybereality
11 years agoGrand Champion
You can call it like this:
You should not be hacking the numbers by multiplying them by two. Also, keep in mind these are radians. If you want degrees you need to do this:
Also, be aware of gimbal lock when using Euler angles (it is better to use quaternions or matrices if possible).
Posef pose = ts.HeadPose.ThePose;
float yaw, pitch, roll;
pose.Rotation.GetEulerAngles<Axis_Y, Axis_X, Axis_Z>(&yaw, &pitch, &roll);
You should not be hacking the numbers by multiplying them by two. Also, keep in mind these are radians. If you want degrees you need to do this:
cout << "yaw: " << RadToDegree(yaw) << endl;
cout << "pitch: " << RadToDegree(pitch) << endl;
cout << "roll: " << RadToDegree(roll) << endl;
Also, be aware of gimbal lock when using Euler angles (it is better to use quaternions or matrices if possible).
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
- 2 years ago
- 1 year ago
- 2 months ago