gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

DS development > Matrix Access

#46572 - connor9 - Mon Jun 27, 2005 3:57 pm

Is it possible on the DS to read the values back from the current matrix. Something along the lines of the glGet* operations? I've read over the board and I haven't found a similar question.

#52388 - Ethos - Tue Aug 30, 2005 1:24 pm

connor9 wrote:
Is it possible on the DS to read the values back from the current matrix. Something along the lines of the glGet* operations? I've read over the board and I haven't found a similar question.


Yeah, I would like to know if this is possible as well, so I will not have to keep my own matrix for reads.

Any clues?
_________________
Ethos' Homepage (Demos/NDS 3D Tutorial)

#52425 - dXtr - Tue Aug 30, 2005 9:15 pm

it was a long time since I used openGL but iirc there is something called glPopMatrix()

edit:
I looked it up in msdn and what I found was:

the following functions retrieve information related to glLoadMatrix:
glGet with argument GL_MATRIX_MODE
glGet with argument GL_MODELVIEW_MATRIX
glGet with argument GL_PROJECTION_MATRIX
glGet with argument GL_TEXTURE_MATRIX

so I guess you call it with GL_*_MATRIX to get your matrix

#52429 - mike260 - Tue Aug 30, 2005 9:40 pm

dXtr wrote:
it was a long time since I used openGL but iirc there is something called glPopMatrix()

edit:
I looked it up in msdn and what I found was:

the following functions retrieve information related to glLoadMatrix:
glGet with argument GL_MATRIX_MODE
glGet with argument GL_MODELVIEW_MATRIX
glGet with argument GL_PROJECTION_MATRIX
glGet with argument GL_TEXTURE_MATRIX

so I guess you call it with GL_*_MATRIX to get your matrix


ndslib is not OpenGL - there's no way to read back these matrices on the DS.