Transform matrix & rotations

Started by
2 comments, last by ludo8x 20 years, 5 months ago
Hello! Suppose that i have a 3*3 matrix called M1 that contain a rotation. Now suppose that i have another 3*3 matrix called M2 that contain another rotation. How can i find out the difference of rotation beetween these two matrix ??? Example: M1 rotate around Z axis by 45 degrees, and M2 rotate around Z axis by 135 degress. I want to extract the rotation around all the axis: X:0 degrees, Y:0 degrees, Z: 135-45 = 95 degrees
Advertisement
One approach would be to convert to quaternions, and find the quaternion difference. You can also read the docs over at www.magic-software.com. There is one PDF file (under source->documentation) regarding rotation issues, and this might help.

Graham Rhodes
Senior Scientist
Applied Research Associates, Inc.
Graham Rhodes Moderator, Math & Physics forum @ gamedev.net
You could also find the inverse of one of the matrices and multiply it by the other matrix, then extract the euler angles from the result.

How appropriate. You fight like a cow.
Tnx !!

This topic is closed to new replies.

Advertisement