mixed-reality-extension-sdk icon indicating copy to clipboard operation
mixed-reality-extension-sdk copied to clipboard

Quaternion.FromEulerAngles(-90, 0, 0) does not create the correct rotation

Open shanewhitfield opened this issue 4 years ago • 2 comments

When applying the rotation Quaternion.FromEulerAngles(-90, 0, 0), the resulting rotation is not correct.

shanewhitfield avatar Aug 13 '20 23:08 shanewhitfield

The arguments to this method are in radians, not degrees. Multiply your literals by MRE.DegreesToRadians.

stevenvergenz avatar Aug 13 '20 23:08 stevenvergenz

I think that since multiple people have been tripped up by this problem, we may want to rename the function to something more obvious - maybe offer both FromEulerAnglesInRadians and FromEulerAnglesInDegrees or something like that. Radians are mathematically more correct, but I think more people intuitively understand degrees.

sorenhan avatar Aug 14 '20 20:08 sorenhan