View Full Version : How to abstract matrix

02-19-2003, 03:46 PM
Basically what i wanna do is to get the current matrix on the stack.
Is there any method that returns the matrix?
what does glPopMatrix() return?

02-19-2003, 08:33 PM
Use glGetFloatv(GLenum pname, GLfloat *params) where pname is either GL_MODELVIEW_MATRIX or GL_PROJECTION_MATRIX and params is a pointer to a 4x4 matrix of GLfloat or equivalent size of equivalent type where you want matrix to be stored.