glsl: add glsl_type::is_atomic_uint() helper

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net>
This commit is contained in:
Samuel Pitoiset 2017-04-21 10:13:49 +02:00
parent 52df318d61
commit 993a05f0eb
1 changed files with 8 additions and 0 deletions

View File

@ -668,6 +668,14 @@ struct glsl_type {
return size;
}
/**
* Query whether or not a type is an atomic_uint.
*/
bool is_atomic_uint() const
{
return base_type == GLSL_TYPE_ATOMIC_UINT;
}
/**
* Return the amount of atomic counter storage required for a type.
*/