]> git.tdb.fi Git - libs/gl.git/blob - tests/glsl/keep_used_function.glsl
Check the flat qualifier from the correct member
[libs/gl.git] / tests / glsl / keep_used_function.glsl
1 #pragma MSP stage(vertex)
2 layout(location=0) in vec4 position;
3 layout(location=1) in vec2 scale;
4 float square(float arg)
5 {
6         return arg*arg;
7 }
8 void main()
9 {
10         float x_sq = square(scale.x);
11         float y_sq = square(scale.y);
12         gl_Position = position*sqrt(x_sq+y_sq);
13 }
14
15 // Target API: Vulkan
16
17 /* Expected output: vertex
18 layout(location=0) in vec4 position;
19 layout(location=1) in vec2 scale;
20 float square(float arg)
21 {
22         return arg*arg;
23 }
24 void main()
25 {
26         gl_Position = position*sqrt(square(scale.x)+square(scale.y));
27 }
28 */