1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-09-15 18:57:08 +00:00

Improvements to colored shadows (#11516)

This commit is contained in:
x2048 2021-10-01 16:21:53 +02:00 committed by GitHub
parent 21113ad410
commit 982e03f60d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 29 additions and 5 deletions

View file

@ -1,5 +1,8 @@
uniform mat4 LightMVP; // world matrix
varying vec4 tPos;
#ifdef COLORED_SHADOWS
varying vec3 varColor;
#endif
const float bias0 = 0.9;
const float zPersFactor = 0.5;
@ -23,4 +26,8 @@ void main()
gl_Position = vec4(tPos.xyz, 1.0);
gl_TexCoord[0].st = gl_MultiTexCoord0.st;
#ifdef COLORED_SHADOWS
varColor = gl_Color.rgb;
#endif
}