mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-15 08:34:40 +00:00
Fix shadows on Basic Lighting.
This commit is contained in:
parent
128cca1479
commit
3ad04d050c
2 changed files with 2 additions and 2 deletions
|
|
@ -40,7 +40,7 @@ void main()
|
||||||
gl_Position = modelview * vec4(vPosition.xyz, 1.0);
|
gl_Position = modelview * vec4(vPosition.xyz, 1.0);
|
||||||
|
|
||||||
color = vColor;
|
color = vColor;
|
||||||
texCoord = vTexCoord1.st;
|
texCoord = vTexCoord0.st;
|
||||||
|
|
||||||
float fromCasterDist = length(vPosition.xyz - shadowCasterPosition) - shadowLength;
|
float fromCasterDist = length(vPosition.xyz - shadowCasterPosition) - shadowLength;
|
||||||
fade = 1.0 - clamp( fromCasterDist / shadowLength , 0.0, 1.0 );
|
fade = 1.0 - clamp( fromCasterDist / shadowLength , 0.0, 1.0 );
|
||||||
|
|
|
||||||
|
|
@ -40,7 +40,7 @@ void main()
|
||||||
gl_Position = modelview * vec4(vPosition.xyz, 1.0);
|
gl_Position = modelview * vec4(vPosition.xyz, 1.0);
|
||||||
|
|
||||||
color = vColor;
|
color = vColor;
|
||||||
texCoord = vTexCoord1.st;
|
texCoord = vTexCoord0.st;
|
||||||
|
|
||||||
float fromCasterDist = length(vPosition.xyz - shadowCasterPosition) - shadowLength;
|
float fromCasterDist = length(vPosition.xyz - shadowCasterPosition) - shadowLength;
|
||||||
fade = 1.0 - clamp( fromCasterDist / shadowLength , 0.0, 1.0 );
|
fade = 1.0 - clamp( fromCasterDist / shadowLength , 0.0, 1.0 );
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue