#pragma MSP stage(vertex) layout(binding=0) uniform sampler2D heightmap; layout(location=0) uniform mat4 mvp; layout(location=0) in vec2 position; layout(location=1) in vec3 texcoord; void main() { gl_Position = mvp*vec4(position, texture(heightmap, texcoord.xy).r, 1.0); passthrough; } #pragma MSP stage(fragment) layout(binding=1) uniform sampler2DArray heightmap; layout(location=3) uniform vec4 color; layout(location=0) out vec4 frag_color; void main() { frag_color = color*texture(heightmap, texcoord).r; } /* Expected error: :13: Mismatched binding 1 for uniform 'heightmap' :2: Previously declared here with binding 0 :13: Mismatched type 'sampler2DArray' for uniform 'heightmap' :2: Previously declared here with type 'sampler2D' :14: Overlapping location 3 for 'color' :3: Previously used here for 'mvp' */