diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2010-04-07 16:47:44 -0700 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2010-04-07 16:49:25 -0700 |
commit | 8645a955fc5fc6a8969ceade7a67390798ed6f74 (patch) | |
tree | 3d0429fdae93ce5c2279e3da6db96a08958fcbd8 | |
parent | 8c46ed24906ee10dd2f2cfaf4cf9803eca1ba523 (diff) |
Add gl_ClipDistance in fragment shader
-rw-r--r-- | ir_variable.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/ir_variable.cpp b/ir_variable.cpp index d81e056850..29f3fc5a63 100644 --- a/ir_variable.cpp +++ b/ir_variable.cpp @@ -228,10 +228,13 @@ generate_130_fs_variables(exec_list *instructions, { generate_120_fs_variables(instructions, symtab); - /* FINISHME: Add support fo gl_ClipDistance. The size of this array is - * FINISHME: implementation dependent based on the value of - * FINISHME: GL_MAX_CLIP_DISTANCES. + /* FINISHME: The size of this array is implementation dependent based on + * FINISHME: the value of GL_MAX_CLIP_DISTANCES. */ + const glsl_type *const clip_distance_array_type = + glsl_type::get_array_instance(glsl_type::float_type, 8); + add_variable("gl_ClipDistance", ir_var_in, clip_distance_array_type, + instructions, symtab); } static void |