+ 4

How to Simulate Proper Gimbal Lock on All Axes [If you know any professional sites that can help, please link them.]

If you know any professional sites that can help, please link them. Thanks! ☺ Hi, In the following code, I draw cubes based on their x, y, z, width, height, length, rotation x, rotation y, and rotation z. But I have a problem properly representing the rotations. I can only pull off one at a time but not the others. So no matter how randomly I rotate the cube: -The 1st cube (leftmost) rotates correctly along its y-axis (yellow line) but not x and z; -The 2nd cube (center) rotates correctly along its x-axis (red line) but not y and z; -The 3rd cube (rightmost) rotates correctly along its z-axis (blue line) but not x and y. It has something to do with the order of how I code the angles to rotate. -The 1st cube rotate its y first, then x and z; -The 2nd cube rotates its x first, then y and z; -The 3rd cube rotates its z first, then x and y. How do I use the take the rx ry and rz and rotate the cube properly on ALL axes? Somehow I can only make 1 work at a time. https://code.sololearn.com/WPtlZO0T2z5c/?ref=app

28th Jun 2018, 8:33 PM
Andre Daniel
Andre Daniel - avatar
2 ответов
+ 1
Arthur the question relates to all languages.
9th Jul 2018, 5:24 PM
Andre Daniel
Andre Daniel - avatar
0
Dont use tags that doesn't have nothing about them in your question plz
9th Jul 2018, 4:51 PM
I Am Arthur
I Am Arthur - avatar