summaryrefslogtreecommitdiff
path: root/progs/vpglsl/if.glsl
blob: 174f69c19c911a5cdd89c895e9329bcd03487532 (plain)
1
2
3
4
5
6
7

void main() {
    gl_FrontColor = gl_Color;
    gl_Position = gl_Vertex;
    if (gl_Position.x < 0.5)
	gl_FrontColor = vec4(1.0, 0.0, 0.0, 1.0);
}