Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #version 330 core
- in vec2 UV;
- in vec3 normal;
- out vec3 color;
- uniform sampler2D textureSampler;
- void main() {
- color = texture(textureSampler, UV).rgb * (0.3 + 0.7 * max(dot(normal, vec3(1, 1, 1)), 0.0));
- // Doom 3 lighting
- // color = texture(textureSampler, UV).rgb * max(dot(normal, vec3(1, 1, 1)), 0.0);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement