3 #pragma MSP stage(vertex)
4 layout(location=0) in vec4 position;
7 out vec2 texcoord = position.xy*0.5+0.5;
8 gl_Position = position;
11 #pragma MSP stage(geometry)
13 layout(triangle_strip, max_vertices=3) out;
24 #pragma MSP stage(fragment)
25 layout(location=0) out vec4 frag_color;
28 frag_color = texture(tex, texcoord);
31 /* Expected output: vertex
32 layout(location=0) in vec4 position;
33 layout(location=0) out vec2 texcoord;
36 texcoord = position.xy*0.5+0.5;
37 gl_Position = position;
41 /* Expected output: geometry
43 layout(triangle_strip, max_vertices=3) out;
44 layout(location=0) in vec2 texcoord[];
45 layout(location=0) out vec2 _gs_out_texcoord;
48 gl_Position = gl_in[0].gl_Position;
49 _gs_out_texcoord = texcoord[0];
51 gl_Position = gl_in[1].gl_Position;
52 _gs_out_texcoord = texcoord[1];
54 gl_Position = gl_in[2].gl_Position;
55 _gs_out_texcoord = texcoord[2];
60 /* Expected output: fragment
61 layout(location=0, binding=71) uniform sampler2D tex;
62 layout(location=0) out vec4 frag_color;
63 layout(location=0) in vec2 _gs_out_texcoord;
66 frag_color = texture(tex, _gs_out_texcoord);