summaryrefslogtreecommitdiff
path: root/drivers/gles3/storage
diff options
context:
space:
mode:
authorHugo Locurcio <hugo.locurcio@hugo.pro>2022-06-10 12:47:06 +0200
committerHugo Locurcio <hugo.locurcio@hugo.pro>2022-08-07 11:06:32 +0200
commitbaaa7503c7e0c83c94edf651ac31f03e0ceddac0 (patch)
tree9a7373cb1f942c4308454e01eacea67b56f0336d /drivers/gles3/storage
parentf85a81696569108c8b4e5cd2f747f3e9c2699b1f (diff)
Add a shadow opacity property to Light3D
This can be used to make shadows translucent for a specific light. The light distance fade system also uses this to smoothly fade the shadow when the light fade transition distance is greater than 0.
Diffstat (limited to 'drivers/gles3/storage')
-rw-r--r--drivers/gles3/storage/light_storage.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gles3/storage/light_storage.cpp b/drivers/gles3/storage/light_storage.cpp
index 22578c9e91..2e4bfdc15b 100644
--- a/drivers/gles3/storage/light_storage.cpp
+++ b/drivers/gles3/storage/light_storage.cpp
@@ -70,6 +70,7 @@ void LightStorage::_light_initialize(RID p_light, RS::LightType p_type) {
light.param[RS::LIGHT_PARAM_SHADOW_SPLIT_3_OFFSET] = 0.6;
light.param[RS::LIGHT_PARAM_SHADOW_FADE_START] = 0.8;
light.param[RS::LIGHT_PARAM_SHADOW_NORMAL_BIAS] = 1.0;
+ light.param[RS::LIGHT_PARAM_SHADOW_OPACITY] = 1.0;
light.param[RS::LIGHT_PARAM_SHADOW_BIAS] = 0.02;
light.param[RS::LIGHT_PARAM_SHADOW_BLUR] = 0;
light.param[RS::LIGHT_PARAM_SHADOW_PANCAKE_SIZE] = 20.0;