glGetUniformiv crashes on ATI?

Hello,

I have a shader with a bool uniform:


uniform bool u_Bool;

After successfully linking. I query its initial value with:


int value;
glGetUniformiv(program, index, &value);

This doesn’t crash on NVIDIA (although the returned value is incorrect: related post). It is crashing on ATI HD2400 and HD4350 on Windows XP with updated drivers.

As a workaround, I’ve changed glGetUniformiv to glGetUniformfv. Is the integer version of GetUniform not supposed to work with bools? I’ve found nothing in the OpenGL or GLSL spec that would make me think this.

Regards,
Patrick

If even NVIDIA has driver bugs in that part of the API, it’s probably best to abandon this approach and try to do things differently.

lol. Yes, I am likely to replace bools with floats but I still want to make sure I’m not doing anything wrong.

Regards,
Patrick