repo.or.cz
/
piglit.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
ext_gpu_shader4: add compiler tests for everything
[piglit.git]
/
tests
/
spec
/
glsl-1.10
/
compiler
/
samplers
/
return-struct.frag
blob
c891da0e23a85551d6e0597affcdf2cdde13ddd8
1
/* [config]
2
* expect_result: fail
3
* glsl_version: 1.10
4
* [end config]
5
*
6
* From page 19 (page 25 of the PDF) of the GLSL 1.10 spec:
7
*
8
* "[Samplers] can only be declared as function parameters or uniforms
9
* (see Section 4.3.5 "Uniform")."
10
*/
11
struct foo {
12
float x;
13
sampler2D tex;
14
};
15
16
uniform foo u;
17
18
foo f()
19
{
20
return u;
21
}
22
23
void main()
24
{
25
gl_FragColor = vec4(1.0);
26
}