MarcusL
04-16-2001, 07:42 AM
Hi!
I'm trying to get GL to tell me how big a texture is that I've currently uploaded. With compressed textures this is no problem, but with uncompressed textures I am a bit stumped.
I thought that using glGetTexLevelParameter with GL_TEXTURE_COMPONENTS would get me a 3 if it is an RGB texture and a 4 for an RGBA. That's not the case. I get far larger values that does not correspond to anything sane. http://www.opengl.org/discussion_boards/ubb/smile.gif
(getting height and width does work..)
What is the proper way of doing it, in terms of OpenGL 1.1?
(Using GeForce DDR, 7.58 drivers)
I'm trying to get GL to tell me how big a texture is that I've currently uploaded. With compressed textures this is no problem, but with uncompressed textures I am a bit stumped.
I thought that using glGetTexLevelParameter with GL_TEXTURE_COMPONENTS would get me a 3 if it is an RGB texture and a 4 for an RGBA. That's not the case. I get far larger values that does not correspond to anything sane. http://www.opengl.org/discussion_boards/ubb/smile.gif
(getting height and width does work..)
What is the proper way of doing it, in terms of OpenGL 1.1?
(Using GeForce DDR, 7.58 drivers)