progs/util: ignore pre-defined uniforms in SetUniformValues()

This commit is contained in:
Brian Paul
2009-08-13 12:53:20 -06:00
parent ae99e4c67e
commit 741869d73a

View File

@@ -153,7 +153,14 @@ SetUniformValues(GLuint program, struct uniform_info uniforms[])
glUniform4fv(uniforms[i].location, 1, uniforms[i].value); glUniform4fv(uniforms[i].location, 1, uniforms[i].value);
break; break;
default: default:
abort(); if (strncmp(uniforms[i].name, "gl_", 3) == 0) {
/* built-in uniform: ignore */
}
else {
fprintf(stderr,
"Unexpected uniform data type in SetUniformValues\n");
abort();
}
} }
} }
} }