Additional layout-related error checking.
git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21108 e7fa87d3-cd2b-0410-9028-fcbf551c1848
This commit is contained in:
@@ -1,29 +1,15 @@
|
||||
#version 300 es
|
||||
|
||||
in vec4 pos;
|
||||
in vec4 color;
|
||||
layout (location = 2) in vec4 color; // ERROR
|
||||
|
||||
layout(location = 7) out vec4 c;
|
||||
layout(location = 1) out vec4 c;
|
||||
layout(location = 3) out vec4 p;
|
||||
|
||||
//layout(std140) uniform Transform { // layout of this block is std140
|
||||
// mat4 M1; // row_major
|
||||
// layout(column_major) mat4 M2; // column major
|
||||
// mat3 N1; // row_major
|
||||
//};
|
||||
//
|
||||
//uniform T2 { // layout of this block is shared
|
||||
//...
|
||||
//};
|
||||
//
|
||||
//layout(column_major) uniform T3 { // shared and column_major
|
||||
// mat4 M3; // column_major
|
||||
// layout(row_major) mat4 m4; // row major
|
||||
// mat3 N2; // column_major
|
||||
//};
|
||||
layout(location = 4) out vec4 q[2];
|
||||
|
||||
void main()
|
||||
{
|
||||
c = color;
|
||||
p = pos;
|
||||
q[1] = pos;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
#version 300 es
|
||||
|
||||
struct s { vec4 v; };
|
||||
|
||||
layout(location = 7) in vec3 c;
|
||||
layout(LocatioN = 3) in vec4 p;
|
||||
layout(LocatioN = 9) in vec4 q[4]; // ERROR, no array
|
||||
layout(LocatioN = 10) in s r[4]; // ERROR, no struct
|
||||
out vec4 pos;
|
||||
out vec3 color;
|
||||
|
||||
@@ -32,6 +36,8 @@ out badout { // ERROR
|
||||
float f;
|
||||
};
|
||||
|
||||
layout (location = 10) out vec4 badout; // ERROR
|
||||
|
||||
void main()
|
||||
{
|
||||
pos = p * (tblock.M1 + tblock.M2 + M4 + M3 + t2m);
|
||||
|
||||
Reference in New Issue
Block a user