7 uint instance_id : SV_InstanceId;
8 uint vertex_id : SV_VertexId;
13 float4 position : SV_Position;
17 void main(vs_in i, out vs_out o)
21 {0.0, 0.0}, { 0.0, 2.0}, {-2.0, 0.0},
22 {0.0, 0.0}, { 2.0, 0.0}, { 0.0, 2.0},
23 {0.0, 0.0}, { 0.0, -2.0}, { 2.0, 0.0},
24 {0.0, 0.0}, {-2.0, 0.0}, { 0.0, -2.0},
26 uint pos = i.vertex_id % 3;
27 o.position = float4(vertices[pos + i.instance_id * 3], 0.0, 1.0);
28 float color = 0.25 + i.instance_id * 0.25;
29 o.color = float4(0.0, color, 0.0, color);
35 float4 position : SV_Position;
39 float4 main(vs_out i) : SV_Target
45 todo(glsl | msl) draw triangle list 3 4
46 probe rtv 0 (160, 120) rgba (0.0, 0.25, 0.0, 0.25)
47 probe rtv 0 (480, 120) rgba (0.0, 0.5, 0.0, 0.5)
48 probe rtv 0 (480, 360) rgba (0.0, 0.75, 0.0, 0.75)
49 probe rtv 0 (160, 360) rgba (0.0, 1.0, 0.0, 1.0)