[Mesa-dev] [PATCH 08/37] glsl: add IR fields for transform feedback layout qualifiers

Timothy Arceri timothy.arceri at collabora.com
Tue Mar 15 12:56:58 UTC 2016


Adds xfb_buffer/stride fields and adds comment to offset field
which is reused for xfb_offset.
---
 src/compiler/glsl/ir.h | 27 ++++++++++++++++++++++++++-
 1 file changed, 26 insertions(+), 1 deletion(-)

diff --git a/src/compiler/glsl/ir.h b/src/compiler/glsl/ir.h
index 930a6de..0c319ea 100644
--- a/src/compiler/glsl/ir.h
+++ b/src/compiler/glsl/ir.h
@@ -732,6 +732,21 @@ public:
       unsigned is_xfb_only:1;
 
       /**
+       * Was a transfor feedback buffer set in the shader?
+       */
+      unsigned explicit_xfb_buffer:1;
+
+      /**
+       * Was a transfor feedback offset set in the shader?
+       */
+      unsigned explicit_xfb_offset:1;
+
+      /**
+       * Was a transfor feedback stride set in the shader?
+       */
+      unsigned explicit_xfb_stride:1;
+
+      /**
        * If non-zero, then this variable may be packed along with other variables
        * into a single varying slot, so this offset should be applied when
        * accessing components.  For example, an offset of 1 means that the x
@@ -866,7 +881,7 @@ public:
       unsigned stream;
 
       /**
-       * Atomic or block member offset.
+       * Atomic, transform feedback or block member offset.
        */
       unsigned offset;
 
@@ -878,6 +893,16 @@ public:
       unsigned max_array_access;
 
       /**
+       * Transform feedback buffer.
+       */
+      unsigned xfb_buffer;
+
+      /**
+       * Transform feedback stride.
+       */
+      unsigned xfb_stride;
+
+      /**
        * Allow (only) ir_variable direct access private members.
        */
       friend class ir_variable;
-- 
2.5.0



More information about the mesa-dev mailing list