Mesa (master): glsl: enable offset layout qualifier for ARB_enhanced_layouts

Timothy Arceri tarceri at kemper.freedesktop.org
Sat Mar 5 08:39:27 UTC 2016


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

Author: Timothy Arceri <timothy.arceri at collabora.com>
Date:   Tue Dec 29 21:15:52 2015 +1100

glsl: enable offset layout qualifier for ARB_enhanced_layouts

Reviewed-by: Edward O'Callaghan <eocallaghan at alterapraxis.com>

---

 src/compiler/glsl/glsl_parser.yy | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/compiler/glsl/glsl_parser.yy b/src/compiler/glsl/glsl_parser.yy
index 9d6ea29..2fb0da1 100644
--- a/src/compiler/glsl/glsl_parser.yy
+++ b/src/compiler/glsl/glsl_parser.yy
@@ -1498,7 +1498,8 @@ layout_qualifier_id:
          $$.binding = $3;
       }
 
-      if (state->has_atomic_counters() &&
+      if ((state->has_atomic_counters() ||
+           state->has_enhanced_layouts()) &&
           match_layout_qualifier("offset", $1, state) == 0) {
          $$.flags.q.explicit_offset = 1;
          $$.offset = $3;




More information about the mesa-commit mailing list