PDA

View Full Version : glGet call for the Active Texture Unit?



PickleWorld
05-25-2007, 09:02 AM
How can I tell (ie retrieve) which texture unit is currently active?

I know I can set it via glActiveTexture() but I want to know if I can rtrieve the active unit before I call glActiveTexture() (to sey it to something else) so I can set it back after?

(or do I just have to use an expensive PushAttrib()?)

jra101
05-25-2007, 09:32 AM
GLint value;
glGetIntegerv(GL_ACTIVE_TEXTURE_ARB, &value)

tanzanite
05-28-2007, 06:57 AM
Not that you should ever use glget* calls.