2

I am trying to rotate mesh with three.js. I have set euler order "ZXY". Now if I rotate X 90 degree and apply Y or Z rotation it shows the same result. While i am thinking the result on rotation Y and Z should be different.

This situation is termed as gimbal lock. You can produce this problem easily on three.js online editor

http://threejs.org/editor/

put 1.570 in the Z rotation and then change rotations values in Y and X. You can see both will produce the same output, that should not happen in the application.

1
  • 1
    Euler angles are not unique. Different Euler triples can result in the same orientation. The library is working correctly. Commented Apr 7, 2014 at 17:34

1 Answer 1

2

What you are dealing with is known as the gimbal lock. It happens when you use euler angles. Since euler angle representations are ambiguous, many euler triples may result in the same rotation. Important is the order in wich the 3 angles x,y and z are applied. for example: rotating 90 deg. around x equals rotating 180 deg around y and then -90 deg around x. to avoid this, use quaternions for rotations.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.