aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/glsl/glsl_types.h
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/glsl/glsl_types.h')
-rw-r--r--mesalib/src/glsl/glsl_types.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/mesalib/src/glsl/glsl_types.h b/mesalib/src/glsl/glsl_types.h
index 8172309a7..647867a23 100644
--- a/mesalib/src/glsl/glsl_types.h
+++ b/mesalib/src/glsl/glsl_types.h
@@ -253,6 +253,18 @@ struct glsl_type {
unsigned component_slots() const;
/**
+ * Calculate the number of attribute slots required to hold this type
+ *
+ * This implements the language rules of GLSL 1.50 for counting the number
+ * of slots used by a vertex attribute. It also determines the number of
+ * varying slots the type will use up in the absence of varying packing
+ * (and thus, it can be used to measure the number of varying slots used by
+ * the varyings that are generated by lower_packed_varyings).
+ */
+ unsigned count_attribute_slots() const;
+
+
+ /**
* Alignment in bytes of the start of this type in a std140 uniform
* block.
*/