Debian Codegraph @

third_party/spirv-cross/reference/shaders-hlsl/asm/frag/implicit-read-dep-phi.asm.frag

raw
1 Texture2D<float4> uImage : register(t0);
2 SamplerState _uImage_sampler : register(s0);
3
4 static float4 v0;
5 static float4 FragColor;
6
7 struct SPIRV_Cross_Input
8 {
9 float4 v0 : TEXCOORD0;
10 };
11
12 struct SPIRV_Cross_Output
13 {
14 float4 FragColor : SV_Target0;
15 };
16
17 void frag_main()
18 {
19 int i = 0;
20 float phi;
21 float4 _36;
22 phi = 1.0f;
23 _36 = float4(1.0f, 2.0f, 1.0f, 2.0f);
24 for (;;)
25 {
26 FragColor = _36;
27 if (i < 4)
28 {
29 if (v0[i] > 0.0f)
30 {
31 float2 _48 = phi.xx;
32 i++;
33 phi += 2.0f;
34 _36 = uImage.SampleLevel(_uImage_sampler, _48, 0.0f);
35 continue;
36 }
37 else
38 {
39 break;
40 }
41 }
42 else
43 {
44 break;
45 }
46 }
47 }
48
49 SPIRV_Cross_Output main(SPIRV_Cross_Input stage_input)
50 {
51 v0 = stage_input.v0;
52 frag_main();
53 SPIRV_Cross_Output stage_output;
54 stage_output.FragColor = FragColor;
55 return stage_output;
56 }