+ /**
+ * Gets an explicitly laid out type with the std430 layout.
+ */
+ const glsl_type *get_explicit_std430_type(bool row_major) const;
+
+ /**
+ * Gets an explicitly laid out interface type.
+ */
+ const glsl_type *get_explicit_interface_type(bool supports_std430) const;
+
+ /** Returns an explicitly laid out type given a type and size/align func
+ *
+ * The size/align func is only called for scalar and vector types and the
+ * returned type is otherwise laid out in the natural way as follows:
+ *
+ * - Arrays and matrices have a stride of ALIGN(elem_size, elem_align).
+ *
+ * - Structure types have their elements in-order and as tightly packed as
+ * possible following the alignment required by the size/align func.
+ *
+ * - All composite types (structures, matrices, and arrays) have an
+ * alignment equal to the highest alighment of any member of the composite.
+ *
+ * The types returned by this function are likely not suitable for most UBO
+ * or SSBO layout because they do not add the extra array and substructure
+ * alignment that is required by std140 and std430.
+ */
+ const glsl_type *get_explicit_type_for_size_align(glsl_type_size_align_func type_info,
+ unsigned *size, unsigned *align) const;
+
+ /**
+ * Alignment in bytes of the start of this type in OpenCL memory.
+ */
+ unsigned cl_alignment() const;
+
+ /**
+ * Size in bytes of this type in OpenCL memory
+ */
+ unsigned cl_size() const;
+
+ /**
+ * Size in bytes of this type based on its explicit data.
+ *
+ * When using SPIR-V shaders (ARB_gl_spirv), memory layouts are expressed
+ * through explicit offset, stride and matrix layout, so the size
+ * can/should be computed used those values.
+ *
+ * Note that the value returned by this method is only correct if such
+ * values are set, so only with SPIR-V shaders. Should not be used with
+ * GLSL shaders.
+ */
+ unsigned explicit_size(bool align_to_stride=false) const;
+