From: Ian Romanick Date: Tue, 23 Mar 2010 22:03:46 +0000 (-0700) Subject: Add query to determine whether a type is a sampler X-Git-Tag: 062012170305~10660^2~625^2~610 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cb7d066967b85c52fe15590b56529254516261e7;p=profile%2Fivi%2Fmesa.git Add query to determine whether a type is a sampler --- diff --git a/glsl_types.h b/glsl_types.h index 57f339a..b1cd9a9 100644 --- a/glsl_types.h +++ b/glsl_types.h @@ -168,6 +168,14 @@ struct glsl_type { } /** + * Query whether or not a type is a sampler + */ + bool is_sampler() const + { + return base_type == GLSL_TYPE_SAMPLER; + } + + /** * Query whether or not a type is the void type singleton. */ bool is_void() const