I am rotating a cube by clicking in either the first, second, third or fourth quadrant. Each one rotates about a different axis, and the last pauses the rotation. My problem is, I want to put text in the corners of the window in all quadrants displaying what clicking in that quadrant will do, but the text is rotating with the cube and I cant figure out how to make it stay put. Thanks in advance
Snakepit
You should be able to use glPushMatrix and glPopMatrix for this. Something like:
glPushMatrix();
glRotate( angle, 1, 0, 0 );
glTranslate( x, y, z );
Draw_Cube();
glPopMatrix();
glPushMatrix();
DrawWriting();
glPopMatrix();
glPopMatrix() loads an identity matrix onto the stack, and then all you transformations after than start from there. When you use glPopMatrix() it replaces the original matrix back onto the stack.
-Drew