View Single Post
Old Jul 26th, 2006, 12:03 PM   #12
andro
Professional Programmer
 
Join Date: Oct 2005
Location: California
Posts: 294
Rep Power: 3 andro is on a distinguished road
Send a message via AIM to andro
I may not have understood correctly, but..

Rotating about the X axis:

[1, 0, 0]
[0, cos x, -sin x]
[0, sin x, cos x]

Rotating about the Y axis:

[cos x, 0, sin x]
[0, 1, 0]
[-sin x, 0, cos x]

Rotating about Z:

[cos x, -sin x, 0]
[sin x, cos x, 0]
[0, 0, 1]

Although that may or may not do what you want, I haven't touched that stuff in a while now



EDIT: You know I think this applies to transforming actual objects in a 3D coordinate space... not physically rotating a 3x3 matrix in place like you are describing... never mind all of this.
andro is offline   Reply With Quote