Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gpu_shader_simple_lighting_smooth_color_frag.glsl « shaders « gpu « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 738b0d84e5160bef4d2b941827e95d694e70bf51 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

uniform vec3 light;

#ifdef USE_FLAT_NORMAL
flat in vec3 normal;
flat in vec4 finalColor;
#else
in vec3 normal;
in vec4 finalColor;
#endif
out vec4 fragColor;

void main()
{
  fragColor = finalColor * max(0.0, dot(normalize(normal), light));
}