1
0
mirror of https://github.com/godotengine/godot.git synced 2026-01-07 19:53:17 +00:00

Remove PSSM Fade

This commit is contained in:
mrjustaguy
2023-10-13 11:00:14 +02:00
parent ee118e7ffd
commit 09a2a7c54e

View File

@@ -1615,7 +1615,6 @@ void main() {
float directional_shadow = 1.0;
if (depth_z < light_split_offsets.y) {
float pssm_fade = 0.0;
#ifdef LIGHT_USE_PSSM_BLEND
float directional_shadow2 = 1.0;
@@ -1623,7 +1622,6 @@ void main() {
bool use_blend = true;
#endif
if (depth_z < light_split_offsets.x) {
float pssm_fade = 0.0;
directional_shadow = shadow1;
#ifdef LIGHT_USE_PSSM_BLEND
@@ -1632,7 +1630,6 @@ void main() {
#endif
} else {
directional_shadow = shadow2;
pssm_fade = smoothstep(light_split_offsets.x, light_split_offsets.y, depth_z);
#ifdef LIGHT_USE_PSSM_BLEND
use_blend = false;
#endif
@@ -1642,7 +1639,6 @@ void main() {
directional_shadow = mix(directional_shadow, directional_shadow2, pssm_blend);
}
#endif
directional_shadow = mix(directional_shadow, 1.0, pssm_fade);
}
#endif //LIGHT_USE_PSSM2
@@ -1658,7 +1654,6 @@ void main() {
float directional_shadow = 1.0;
if (depth_z < light_split_offsets.w) {
float pssm_fade = 0.0;
#ifdef LIGHT_USE_PSSM_BLEND
float directional_shadow2 = 1.0;
@@ -1694,7 +1689,6 @@ void main() {
} else {
directional_shadow = shadow4;
pssm_fade = smoothstep(light_split_offsets.z, light_split_offsets.w, depth_z);
#if defined(LIGHT_USE_PSSM_BLEND)
use_blend = false;
@@ -1706,7 +1700,6 @@ void main() {
directional_shadow = mix(directional_shadow, directional_shadow2, pssm_blend);
}
#endif
directional_shadow = mix(directional_shadow, 1.0, pssm_fade);
}
#endif //LIGHT_USE_PSSM4