Merge pull request #1203 from BeamNG/fix_BL_shadow

Fix shadows on Basic Lighting.
This commit is contained in:
Luis Anton Rebollo 2015-02-15 22:28:25 +01:00
commit 9155448f17
2 changed files with 2 additions and 2 deletions

View file

@ -40,7 +40,7 @@ void main()
gl_Position = modelview * vec4(vPosition.xyz, 1.0);
color = vColor;
texCoord = vTexCoord1.st;
texCoord = vTexCoord0.st;
float fromCasterDist = length(vPosition.xyz - shadowCasterPosition) - shadowLength;
fade = 1.0 - clamp( fromCasterDist / shadowLength , 0.0, 1.0 );

View file

@ -40,7 +40,7 @@ void main()
gl_Position = modelview * vec4(vPosition.xyz, 1.0);
color = vColor;
texCoord = vTexCoord1.st;
texCoord = vTexCoord0.st;
float fromCasterDist = length(vPosition.xyz - shadowCasterPosition) - shadowLength;
fade = 1.0 - clamp( fromCasterDist / shadowLength , 0.0, 1.0 );