repo.or.cz
/
piglit
/
hramrach.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Add more structure constructor tests.
[piglit/hramrach.git]
/
tests
/
shaders
/
glsl-fs-varying-array.shader_test
blob
3a4afa48c99f3aa4b4f68a8f9639d24a4ea7d78e
1
[require]
2
GL >= 2.0
3
GLSL >= 1.20
4
5
[vertex shader]
6
varying vec4 values[4];
7
void main()
8
{
9
values[0] = vec4(0.2);
10
values[1] = vec4(0.4);
11
values[2] = vec4(0.6);
12
values[3] = vec4(0.7);
13
gl_Position = gl_Vertex;
14
}
15
16
[fragment shader]
17
uniform int index;
18
varying vec4 values[4];
19
void main()
20
{
21
gl_FragColor = values[index];
22
}
23
24
[test]
25
uniform int index 1
26
draw rect -1 -1 2 2
27
probe rgba 1 1 0.4 0.4 0.4 0.4