diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2010-06-07 19:10:33 -0700 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2010-06-07 19:10:33 -0700 |
commit | cfb3536f10dac343ad635be7f979b292c97eb1a3 (patch) | |
tree | 13273adaa6c63f8533fef0dee7dbb7b4132d93b8 | |
parent | 19eb5896c4f47a8485a7be2d7b63c6f44dff1b42 (diff) |
Bump GL_MAX_TEXTURE_COORDS from 2 to 4
Every platform that supports GLSL sets GL_MAX_TEXTURE_COORDS to at
least 4, so hard-code 4 for now.
This causes the following tests to pass:
glslparsertest/glsl2/norsetto-bumptbn_sh_fp.vert
glslparsertest/glsl2/xreal-lighting-d-omni.vert
glslparsertest/glsl2/xreal-lighting-db-omni.vert
glslparsertest/glsl2/xreal-lighting-dbs-omni.vert
-rw-r--r-- | ir_variable.cpp | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/ir_variable.cpp b/ir_variable.cpp index af8ad2c318..0c0d1278a4 100644 --- a/ir_variable.cpp +++ b/ir_variable.cpp @@ -97,11 +97,12 @@ generate_110_uniforms(exec_list *instructions, } /* FINISHME: The size of this array is implementation dependent based on the - * FINISHME: value of GL_MAX_TEXTURE_COORDS. GL_MAX_TEXTURE_COORDS must be - * FINISHME: at least 2, so hard-code 2 for now. + * FINISHME: value of GL_MAX_TEXTURE_COORDS. Every platform that supports + * FINISHME: GLSL sets GL_MAX_TEXTURE_COORDS to at least 4, so hard-code 4 + * FINISHME: for now. */ const glsl_type *const mat4_array_type = - glsl_type::get_array_instance(glsl_type::mat4_type, 2); + glsl_type::get_array_instance(glsl_type::mat4_type, 4); add_variable("gl_TextureMatrix", ir_var_uniform, mat4_array_type, instructions, symtab); @@ -149,11 +150,12 @@ generate_110_vs_variables(exec_list *instructions, generate_110_uniforms(instructions, symtab); /* FINISHME: The size of this array is implementation dependent based on the - * FINISHME: value of GL_MAX_TEXTURE_COORDS. GL_MAX_TEXTURE_COORDS must be - * FINISHME: at least 2, so hard-code 2 for now. + * FINISHME: value of GL_MAX_TEXTURE_COORDS. Every platform that supports + * FINISHME: GLSL sets GL_MAX_TEXTURE_COORDS to at least 4, so hard-code 4 + * FINISHME: for now. */ const glsl_type *const vec4_array_type = - glsl_type::get_array_instance(glsl_type::vec4_type, 2); + glsl_type::get_array_instance(glsl_type::vec4_type, 4); add_variable("gl_TexCoord", ir_var_out, vec4_array_type, instructions, symtab); @@ -229,11 +231,12 @@ generate_110_fs_variables(exec_list *instructions, generate_110_uniforms(instructions, symtab); /* FINISHME: The size of this array is implementation dependent based on the - * FINISHME: value of GL_MAX_TEXTURE_COORDS. GL_MAX_TEXTURE_COORDS must be - * FINISHME: at least 2, so hard-code 2 for now. + * FINISHME: value of GL_MAX_TEXTURE_COORDS. Every platform that supports + * FINISHME: GLSL sets GL_MAX_TEXTURE_COORDS to at least 4, so hard-code 4 + * FINISHME: for now. */ const glsl_type *const vec4_array_type = - glsl_type::get_array_instance(glsl_type::vec4_type, 2); + glsl_type::get_array_instance(glsl_type::vec4_type, 4); add_variable("gl_TexCoord", ir_var_in, vec4_array_type, instructions, symtab); |