bgfx/3rdparty/spirv-cross/shaders-hlsl/frag/switch-unsigned-case.frag
Бранимир Караџић ac29dccc6a Added spirv-cross.
2019-01-09 19:23:47 -08:00

27 lines
358 B
GLSL

#version 310 es
precision mediump float;
#define ENUM_0 0u
#define ENUM_1 1u
layout(set = 0, binding = 0) uniform Buff
{
uint TestVal;
};
layout(location = 0) out vec4 fsout_Color;
void main()
{
fsout_Color = vec4(1.0);
switch (TestVal)
{
case ENUM_0:
fsout_Color = vec4(0.1);
break;
case ENUM_1:
fsout_Color = vec4(0.2);
break;
}
}