blob: d167d5d79eb5eeb70ce2f5165b2c0a528e0684d4 [file] [log] [blame]
John Kessenichc0275792013-08-09 17:14:49 +00001#version 400 core
2
John Kessenich623833f2013-12-11 18:57:40 +00003layout(vertices = 4) out;
4int outa[gl_out.length()];
5
6layout(quads) in; // ERROR
7layout(ccw) out; // ERROR
8layout(fractional_even_spacing) in; // ERROR
9
John Kessenich116c30b2013-12-12 01:25:37 +000010patch in vec4 patchIn; // ERROR
11patch out vec4 patchOut;
John Kessenich623833f2013-12-11 18:57:40 +000012
John Kessenichc0275792013-08-09 17:14:49 +000013void main()
14{
15 barrier();
John Kessenich623833f2013-12-11 18:57:40 +000016
17 int a = gl_MaxTessControlInputComponents +
18 gl_MaxTessControlOutputComponents +
19 gl_MaxTessControlTextureImageUnits +
20 gl_MaxTessControlUniformComponents +
21 gl_MaxTessControlTotalOutputComponents;
22
23 vec4 p = gl_in[1].gl_Position;
24 float ps = gl_in[1].gl_PointSize;
25 float cd = gl_in[1].gl_ClipDistance[2];
26
27 int pvi = gl_PatchVerticesIn;
28 int pid = gl_PrimitiveID;
29 int iid = gl_InvocationID;
30
31 gl_out[1].gl_Position = p;
32 gl_out[1].gl_PointSize = ps;
33 gl_out[1].gl_ClipDistance[1] = cd;
34
35 gl_TessLevelOuter[3] = 3.2;
36 gl_TessLevelInner[1] = 1.3;
John Kessenichc0275792013-08-09 17:14:49 +000037}
John Kessenichf3e2a892013-12-13 18:38:43 +000038
39layout(vertices = 4) in; // ERROR
40layout(vertices = 5) out; // ERROR
41
42void foo()
43{
44 gl_out[4].gl_PointSize; // ERROR
John Kessenich08d18242013-12-20 18:36:27 +000045}
46
47in vec2 ina; // ERROR, not array
48in vec2 inb[];
49in vec2 inc[18]; // ERROR, wrong size
50in vec2 ind[gl_MaxPatchVertices];
John Kessenichc7776ec2014-01-26 01:37:13 +000051
52#extension GL_ARB_separate_shader_objects : enable
John Kessenich08d18242013-12-20 18:36:27 +000053
54layout(location = 3) in vec4 ivla[];
55layout(location = 4) in vec4 ivlb[];
56layout(location = 4) in vec4 ivlc[]; // ERROR
57
58layout(location = 3) out vec4 ovla[];
59layout(location = 4) out vec4 ovlb[];
60layout(location = 4) out vec4 ovlc[]; // ERROR