1 /* Section 4.3.8.1 (Input Layout Qualifiers) of the GLSL 1.50 spec says:
3 * "Fragment shaders can have an input layout only for redeclaring the
4 * built-in variable gl_FragCoord (see section 7.2 Fragment Shader
5 * Special Variables). The layout qualifier identifiers for
10 * pixel_center_integer"
13 * "If gl_FragCoord is redeclared in any fragment shader in a program,
14 * it must be redeclared in all the fragment shaders in that program
15 * that have a static use gl_FragCoord. All redeclarations of
16 * gl_FragCoord in all fragment shaders in a single program must have
17 * the same set of qualifiers."
20 * Tests the case when all the fragment shaders which use gl_FragCoord,
21 * redeclare it with matching layout qualifiers.
27 [vertex shader passthrough]
31 layout(origin_upper_left, pixel_center_integer) in vec4 gl_FragCoord;
36 gl_FragColor = vec4(gl_FragCoord.xy, 0.0, 1.0);
50 layout(origin_upper_left, pixel_center_integer) in vec4 gl_FragCoord;
53 gl_FragColor.a = gl_FragCoord.z;