PDA

View Full Version : Rotation matrix



calixte
06-12-2005, 11:38 PM
Hi,

I would like to rotate an object under openGL without using glRotate (because I use another representation than Euler angles). I have a 3 by 3 rotation matrix (that I can set to homogeneous 4 by 4) and I would like to rotate my object.

Should I load the modelview and multiply it by my rotation matrix?

Thanks,

c.

T101
06-13-2005, 12:16 AM
You can use glMultMatrix. Be sure to specify the elements in the correct order.

Though I don't know what you would "load the modelview" for.

calixte
06-13-2005, 12:34 AM
You mean that just to write glMultMatrix would be enough?

c.

powerpad
06-13-2005, 12:52 AM
he meant that you could do

glMatrixMode(Mode);
glMultMatrix(YOUR_ROTATION_MATRIX);

calixte
06-13-2005, 12:56 AM
But which matrix mode should i choose?

uruk
06-13-2005, 02:29 AM
GL_MODELVIEW