summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/bgfx/3rdparty/spirv-cross/shaders-msl/frag/switch-unsigned-case.frag
blob: d8aee43a6c44670d299f624dd2e33675ea6fe318 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#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;
	}
}