Working with my other shader programs taught me a lot about validation and error checking, but that isn't helping here. The program log for both of the following vertex and fragment shaders is empty and OpenGL is reporting GL_NO_ERROR. The program, however, still returns GL_FALSE when attempting to validate. I've tested the validation code and it works fine (for instance, a syntax error is clearly reported and other simple shaders are NOT returning GL_FALSE).
In short, my question is: What illegal thing am I doing to make the program fail to validate?
Thanks for any help on the matter. This has me completely baffled.
voronoi.vert
#version 420
uniform mat4 mat_ModelViewProjection;
uniform float scale;
layout(location = 0) in vec3 in_Position;
layout(location = 1) in float in_Elevation;
layout(location = 2) in int in_Biom;
flat out float ex_Elevation;
flat out int ex_Biom;
void main(void)
{
gl_Position = mat_ModelViewProjection*vec4(in_Position*scale, 1.0);
ex_Elevation = in_Elevation;
ex_Biom = in_Biom;
}voronoi.frag
#version 420
in float ex_Elevation;
in int ex_Biom;
out vec4 frag_Color;
void main()
{
vec3 color = vec3(1.0f);
switch(ex_Biom){
case 0:
color = vec3(0.0f,0.0f,1.0f);
break;
default:
color = vec3(0.0f,1.0f,0.0f);
break;
}
color = color*ex_Elevation/10.0f + 0.1;
frag_Color = vec4(color,1.0f);
}







