Retrieving to matrix

Hi there…
I’m trying to develop a skeletal animation system, and have run into some trouble. I would like to retrieve the current matrix, and use it to perform som on-the-fly operations with it, i.e. multiply my vertices by the matrix myself.
Is there any way to do this? I’m looking for a kind of inverse/reverse of glLoadMatrix()…

Or, if anyone has a better way of doing this, I’d be happy to know.

In essence, what I want to do is:
Keep my vertices stored as local coordinates.
Translate them in sets of vertices, and save the results as transformed coordinates.

If I have a vertex mesh, I would like to transform different parts of the mesh by different matrices.

TIA - Fenris of Garm Productions

You’ll want to use the glGetDoublev function. In order to get the model view matrix, pass GL_MODELVIEW_MATRIX and the pointer to your buffer large enough for 16 doubles. For the probjection matrix, pass GL_PROJECTION_MATRIX and the pointer to your buffer.

Thanks a lot. Really. :slight_smile: You made my… year, so far.