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,10 +153,17 @@ SetUniformValues(GLuint program, struct uniform_info uniforms[])
glUniform4fv(uniforms[i].location, 1, uniforms[i].value);
break;
default:
if (strncmp(uniforms[i].name, "gl_", 3) == 0) {
/* built-in uniform: ignore */
}
else {
fprintf(stderr,
"Unexpected uniform data type in SetUniformValues\n");
abort();
}
}
}
}
/** Get list of uniforms used in the program */