glGetFloatv(GL_MODELVIEW_MATRIX, m) dont work!

Started by
11 comments, last by FearedPixel 20 years, 6 months ago
glGetFloatv(GL_MODELVIEW_MATRIX, m) doesn''t seem to work with my setup, it always returns the same value (a saw someone else having the same problem on a newsgroup post). I know it can''t be right, because if i call LoadMatrix straight after, on the result that I get from the above statement, i get a completly inconsistant result. I have a Radeon 9500 PRO, although not the latest drivers (and i cant update on this comp) Help would be much appreciated!
Advertisement
code?

____________________________________________________________www.elf-stone.com | Automated GL Extension Loading: GLee 5.00 for Win32 and Linux

if i just do

glGetFloatv(GL_MODELVIEW_MATRIX, m1);
glTranslatef(3.0, 4.0, 5.0);
glGetFloatv(GL_MODELVIEW_MATRIX, m2);

then m1 and m2 would still be the same

even when i glFlush and glFinish before and after the calls

[edited by - FearedPixel on November 9, 2003 5:47:13 PM]
Are you sure the matrix mode is set to model-view when those calls are made?

"Sneftel is correct, if rather vulgar." --Flarelocke
Yes, its just among my normal rendering code
How do you declare m1 and m2?

____________________________________________________________www.elf-stone.com | Automated GL Extension Loading: GLee 5.00 for Win32 and Linux

Maybe it''s wglMakeCurrent(), or other initialization ?
Maybe it''s because your matrix stack is full? (forgot to pop?)

Do you get any visible result/change when rendering?
All the rendering etc works fine, the transformations are doing their job.

I am using C# + CsGL, so i declare m1 and m2 like float[] m1 = new float[16];

My matrix stack isn''t full (i would get error).
hmm.. seems like you''ve checked most things, have you tried glGetError?
Yep, no errors.

This topic is closed to new replies.

Advertisement