From: Ian Romanick Date: Thu, 10 Jun 2010 00:17:47 +0000 (-0700) Subject: Add glsl_type::is_record query X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=93073551f9fff0df5ad1f65e0f483e6699474b91;p=mesa.git Add glsl_type::is_record query --- diff --git a/glsl_types.h b/glsl_types.h index 22df13b07f0..823897df4ae 100644 --- a/glsl_types.h +++ b/glsl_types.h @@ -292,6 +292,14 @@ struct glsl_type { return base_type == GLSL_TYPE_ARRAY; } + /** + * Query whether or not a type is a record + */ + bool is_record() const + { + return base_type == GLSL_TYPE_STRUCT; + } + /** * Query whether or not a type is the void type singleton. */