Mesa (master): glsl ast_to_hir: reject interpolation qualifiers for uniform blocks

Jordan Justen jljusten at kemper.freedesktop.org
Thu May 23 18:23:43 UTC 2013


Module: Mesa
Branch: master
Commit: 067cc08d6ab41333cd0fa3ea49b9d0247631a28b
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=067cc08d6ab41333cd0fa3ea49b9d0247631a28b

Author: Jordan Justen <jordan.l.justen at intel.com>
Date:   Sat Mar 23 17:14:37 2013 -0700

glsl ast_to_hir: reject interpolation qualifiers for uniform blocks

Signed-off-by: Jordan Justen <jordan.l.justen at intel.com>
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>

---

 src/glsl/ast_to_hir.cpp |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/src/glsl/ast_to_hir.cpp b/src/glsl/ast_to_hir.cpp
index e578019..b55d25e 100644
--- a/src/glsl/ast_to_hir.cpp
+++ b/src/glsl/ast_to_hir.cpp
@@ -4063,6 +4063,12 @@ ast_process_structure_or_interface_block(exec_list *instructions,
                validate_matrix_layout_for_type(state, &loc, field_type);
          }
 
+         if (qual->flags.q.uniform && qual->has_interpolation()) {
+            _mesa_glsl_error(&loc, state,
+                             "interpolation qualifiers cannot be used "
+                             "with uniform interface blocks");
+         }
+
          if (field_type->is_matrix() ||
              (field_type->is_array() && field_type->fields.array->is_matrix())) {
             fields[i].row_major = block_row_major;




More information about the mesa-commit mailing list