glsl: Add 'bare' shadow sampler type
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6222>
This commit is contained in:
@@ -122,6 +122,7 @@ DECL_TYPE(usamplerBuffer, GL_UNSIGNED_INT_SAMPLER_BUFFER, GLSL_
|
||||
DECL_TYPE(usampler2DMS, GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE, GLSL_TYPE_SAMPLER, GLSL_SAMPLER_DIM_MS, 0, 0, GLSL_TYPE_UINT)
|
||||
DECL_TYPE(usampler2DMSArray, GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY, GLSL_TYPE_SAMPLER, GLSL_SAMPLER_DIM_MS, 0, 1, GLSL_TYPE_UINT)
|
||||
|
||||
DECL_TYPE(samplerShadow, GL_SAMPLER_1D_SHADOW, GLSL_TYPE_SAMPLER, GLSL_SAMPLER_DIM_1D, 1, 0, GLSL_TYPE_VOID)
|
||||
DECL_TYPE(sampler1DShadow, GL_SAMPLER_1D_SHADOW, GLSL_TYPE_SAMPLER, GLSL_SAMPLER_DIM_1D, 1, 0, GLSL_TYPE_FLOAT)
|
||||
DECL_TYPE(sampler2DShadow, GL_SAMPLER_2D_SHADOW, GLSL_TYPE_SAMPLER, GLSL_SAMPLER_DIM_2D, 1, 0, GLSL_TYPE_FLOAT)
|
||||
DECL_TYPE(samplerCubeShadow, GL_SAMPLER_CUBE_SHADOW, GLSL_TYPE_SAMPLER, GLSL_SAMPLER_DIM_CUBE, 1, 0, GLSL_TYPE_FLOAT)
|
||||
|
@@ -586,6 +586,12 @@ glsl_bare_sampler_type()
|
||||
return glsl_type::sampler_type;
|
||||
}
|
||||
|
||||
const struct glsl_type *
|
||||
glsl_bare_shadow_sampler_type()
|
||||
{
|
||||
return glsl_type::samplerShadow_type;
|
||||
}
|
||||
|
||||
const struct glsl_type *
|
||||
glsl_image_type(enum glsl_sampler_dim dim, bool is_array,
|
||||
enum glsl_base_type base_type)
|
||||
|
@@ -201,6 +201,7 @@ const struct glsl_type *glsl_sampler_type(enum glsl_sampler_dim dim,
|
||||
bool is_shadow, bool is_array,
|
||||
enum glsl_base_type base_type);
|
||||
const struct glsl_type *glsl_bare_sampler_type();
|
||||
const struct glsl_type *glsl_bare_shadow_sampler_type();
|
||||
const struct glsl_type *glsl_image_type(enum glsl_sampler_dim dim,
|
||||
bool is_array,
|
||||
enum glsl_base_type base_type);
|
||||
|
Reference in New Issue
Block a user