Merge branch 'patch-1' of https://github.com/cshesse/stb into work2

This commit is contained in:
Sean Barrett 2020-02-02 10:03:31 -08:00
commit a6726a3d28

View File

@ -614,7 +614,7 @@ void setup_uniforms(GLuint shader, float camera_pos[4], GLuint tex1, GLuint tex2
stbvox_uniform_info sui;
if (stbvox_get_uniform_info(&sui, i)) {
GLint loc = glGetUniformLocation(shader, sui.name);
if (loc != 0) {
if (loc != -1) {
switch (i) {
case STBVOX_UNIFORM_camera_pos: // only needed for fog
glUniform4fv(loc, sui.array_length, camera_pos);