3d rotation

honkFactory
Unregistered
 
Post: #1
Howdy,
I have a 3d rotation question. First, lets say you have an openGL view that looks straight down a the z axis when untransform - the normal setup. (Not an ortho view, a normal perspective.) Now, lets say the model matrix undergoes a series of rotation only transforms. Using the getfloat() method you can get the transformed model matrix. Now (here is the actual question, fianlly) how do you determine what vectors in the tranformed coordinate system are equal to the x, y or z vectors in the untransformed coordinate system? Do you do multiply say x (1,0,0) by the inverse (or the transpose) of the transform matrix? Can you get openGL to give you the inverse of the model matrix?
A.W.

[edit] I gues there is no reason to expect openGl be able to give the inverse, seeing as it is not a math library.
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #2
No, you have to invert the matrix yourself.

gluUnproject does it...
Quote this message in a reply
Member
Posts: 469
Joined: 2002.10
Post: #3
well if you want to do it the hard way, you could always do the change of bases yourself with a little linear algebra.

---Kelvin--
15.4" MacBook Pro revA
1.83GHz/2GB/250GB
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Quaternion rotation -> OpenGL rotation matrix? DJBlufire 3 3,978 Sep 6, 2003 08:34 PM
Last Post: MattDiamond