}
}
+bool
+glsl_type::contains_64bit() const
+{
+ if (this->is_array()) {
+ return this->fields.array->contains_64bit();
+ } else if (this->is_record() || this->is_interface()) {
+ for (unsigned int i = 0; i < this->length; i++) {
+ if (this->fields.structure[i].type->contains_64bit())
+ return true;
+ }
+ return false;
+ } else {
+ return this->is_64bit();
+ }
+}
+
bool
glsl_type::contains_opaque() const {
switch (base_type) {
*/
bool contains_double() const;
+ /**
+ * Query whether or not type is a 64-bit type, or for struct, interface and
+ * array types, contains a double type.
+ */
+ bool contains_64bit() const;
+
/**
* Query whether or not a type is a float type
*/
return type->is_integer();
}
+bool
+glsl_type_contains_64bit(const struct glsl_type *type)
+{
+ return type->contains_64bit();
+}
+
const glsl_type *
glsl_void_type(void)
{
bool glsl_type_is_numeric(const struct glsl_type *type);
bool glsl_type_is_boolean(const struct glsl_type *type);
bool glsl_type_is_integer(const struct glsl_type *type);
+bool glsl_type_contains_64bit(const struct glsl_type *type);
bool glsl_sampler_type_is_shadow(const struct glsl_type *type);
bool glsl_sampler_type_is_array(const struct glsl_type *type);
bool glsl_contains_atomic(const struct glsl_type *type);