summaryrefslogtreecommitdiff
path: root/terrain_fragment.glsl
blob: 774bfd3b5a2ba287dcac79b9450b7c8e11661147 (plain)
1
2
3
4
5
6
7
8
9
10
11
varying vec3 normal, light_pos;

uniform sampler2D tex;

void main() {
	vec3 n = normalize(normal);
	float diffuse = max(dot(n, light_pos), 0.0);
	gl_FragColor = texture2D(tex, gl_TexCoord[0].st) * diffuse;
}

/* vim: set syn=glsl: */