zed
01-31-2005, 10:16 PM
how to find out whats the current active glsl shader
glGetIntegerv( GL_CURRENT_PROGRAM, &shaderID ); // this seems to be more logical but gives an error
shaderID = GetHandleARB( GL_PROGRAM_OBJECT_ARB ); // this works
though Handles have been dropped from shaders when they became part of gl2.0 (strange idea to call them handles in the first place should of just been ints)
so im not 100% sure if this is the correct way even though it seems to work, the documentation is a bit messy, _OBJECT_ being dropped etc
ta
glGetIntegerv( GL_CURRENT_PROGRAM, &shaderID ); // this seems to be more logical but gives an error
shaderID = GetHandleARB( GL_PROGRAM_OBJECT_ARB ); // this works
though Handles have been dropped from shaders when they became part of gl2.0 (strange idea to call them handles in the first place should of just been ints)
so im not 100% sure if this is the correct way even though it seems to work, the documentation is a bit messy, _OBJECT_ being dropped etc
ta