My vertex shader:
uniform float xtime;
void main(void) {
vec4 v = vec4(gl_Vertex);
float t;
t = xtime;
gl_Position = gl_ModelViewProjectionMatrix * v;
}
This shader compiles and links without errors.
glGetActiveUniformARB(vs.program, 1)
returns (1, 5126, 'xtime')
ptr = glGetUniformLocationARB(vs.program, 'xtime')
returns 1
glUniform1fARB(ptr, 5.0)
returns None, and I then get a GL_ERROR from glGetError().
Help! What am I doing wrong, or is this a bug?
|