summaryrefslogtreecommitdiff
path: root/gfx/gl/shaders/basicShader.fs
blob: 7d79575ccaafc031d29b0a3ef4a28d99d1451f92 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#version 130

in vec2 texCoord0;
in vec3 normal0;

uniform sampler2D sampler;
uniform vec3 lightDirection;

void main()
{
	gl_FragColor = texture(sampler, texCoord0);
	gl_FragColor.xyz *= clamp(dot(-lightDirection, normal0), 0.0, 1.0);
}