blob: 63c279528ad05ef2a0ef20c53362686c8bc000ce (
plain)
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
//TEST:SIMPLE(filecheck=SPIRV_POINT):-target spirv -stage hull -entry hullMain_point
//TEST:SIMPLE(filecheck=SPIRV_TRICW):-target spirv -stage hull -entry hullMain_triangle_cw
//TEST:SIMPLE(filecheck=SPIRV_TRICCW):-target spirv -stage hull -entry hullMain_triangle_ccw
// SPIRV_POINT: OpExecutionMode %hullMain_point PointMode
// SPIRV_TRICW: OpExecutionMode %hullMain_triangle_cw VertexOrderCw
// SPIRV_TRICCW: OpExecutionMode %hullMain_triangle_ccw VertexOrderCcw
struct Out {
float x;
};
struct PatchConst {
float EdgeTessFactor[4] : SV_TessFactor;
float InsideTessFactor[2] : SV_InsideTessFactor;
};
PatchConst patchConst() {
PatchConst o;
o.EdgeTessFactor[0] = 1;
o.EdgeTessFactor[1] = 1;
o.EdgeTessFactor[2] = 1;
o.EdgeTessFactor[3] = 1;
o.InsideTessFactor[0] = 1;
o.InsideTessFactor[1] = 1;
return o;
}
[domain("quad")]
[partitioning("integer")]
[outputtopology("point")]
[outputcontrolpoints(4)]
[patchconstantfunc("patchConst")]
Out hullMain_point() {
Out o;
o.x = 0;
return o;
}
[domain("quad")]
[partitioning("integer")]
[outputtopology("triangle_cw")]
[outputcontrolpoints(4)]
[patchconstantfunc("patchConst")]
Out hullMain_triangle_cw() {
Out o;
o.x = 0;
return o;
}
[domain("quad")]
[partitioning("integer")]
[outputtopology("triangle_ccw")]
[outputcontrolpoints(4)]
[patchconstantfunc("patchConst")]
Out hullMain_triangle_ccw() {
Out o;
o.x = 0;
return o;
}
|