Hey guys,
I'm currently working on implementing a render state caching system for our OpenGL build. I'm using this block of code here:
GLint oldDest = GL_ONE_MINUS_SRC_ALPHA;
glGetIntegerv( GL_BLEND_DST, &oldDest );
to try and get the previous destination blend factor. But when the function returns, oldDest is 0. Now from what I've read, it shouldn't change the value of oldDest if it fails, and I'm not getting any error codes from glGetIntegerv, but 0 is not a valid destination blend factor.
Do you guys have any idea what may be causing this?