]> git.tdb.fi Git - libs/gl.git/blob - tests/glsl/passthrough.glsl
4017e490a636249a852ea7e1ed3bccbbefa8a847
[libs/gl.git] / tests / glsl / passthrough.glsl
1 #pragma MSP stage(vertex)
2 layout(location=0) in vec4 position;
3 layout(location=1) in vec4 color;
4 void main()
5 {
6         gl_Position = position;
7         passthrough;
8 }
9
10 #pragma MSP stage(fragment)
11 layout(location=0) out vec4 frag_color;
12 void main()
13 {
14         frag_color = color;
15 }
16
17 /* Expected output: vertex
18 layout(location=0) in vec4 position;
19 layout(location=1) in vec4 color;
20 out vec4 _vs_out_color;
21 void main()
22 {
23         gl_Position = position;
24         _vs_out_color = color;
25 }
26 */
27
28 /* Expected output: fragment
29 layout(location=0) out vec4 frag_color;
30 in vec4 _vs_out_color;
31 void main()
32 {
33         frag_color = _vs_out_color;
34 }
35 */