glsl ES: Fix magnitude of gl_MaxVertexUniformVectors. 85/7485/1
authorPaul Berry <stereotype441@gmail.com>
Sun, 7 Jul 2013 18:47:22 +0000 (11:47 -0700)
committerPaul Berry <stereotype441@gmail.com>
Sat, 13 Jul 2013 01:18:48 +0000 (18:18 -0700)
Previously, we set it equal to MaxVertexUniformComponents.  It should
be MaxVertexUniformComponents / 4.

NOTE: This is a candidate for the stable branches.

Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
src/glsl/builtin_variables.cpp

index f4ac205..58019c6 100644 (file)
@@ -533,7 +533,7 @@ generate_common_ES_uniforms(exec_list *instructions,
    add_builtin_constant(instructions, symtab, "gl_MaxVertexAttribs",
                        state->Const.MaxVertexAttribs);
    add_builtin_constant(instructions, symtab, "gl_MaxVertexUniformVectors",
-                       state->Const.MaxVertexUniformComponents);
+                       state->Const.MaxVertexUniformComponents / 4);
    add_builtin_constant(instructions, symtab, "gl_MaxVertexTextureImageUnits",
                        state->Const.MaxVertexTextureImageUnits);
    add_builtin_constant(instructions, symtab, "gl_MaxCombinedTextureImageUnits",