summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/app_settings')
-rw-r--r--indra/newview/app_settings/shaders/class3/deferred/softenLightF.glsl5
1 files changed, 5 insertions, 0 deletions
diff --git a/indra/newview/app_settings/shaders/class3/deferred/softenLightF.glsl b/indra/newview/app_settings/shaders/class3/deferred/softenLightF.glsl
index c5b27ec52c..3b1003f83b 100644
--- a/indra/newview/app_settings/shaders/class3/deferred/softenLightF.glsl
+++ b/indra/newview/app_settings/shaders/class3/deferred/softenLightF.glsl
@@ -25,6 +25,8 @@
#define PBR_USE_GGX_APPROX 1
#define PBR_USE_GGX_EMS_HACK 1
+#define PBR_USE_IRRADIANCE_HACK 1
+
#define DEBUG_PBR_PACKORM0 0 // Rough=0, Metal=0
#define DEBUG_PBR_PACKORM1 0 // Rough=1, Metal=1
@@ -294,6 +296,9 @@ void main()
vec3 debug_irradiance = irradiance;
#endif
irradiance = max(amblit,irradiance);
+#if PBR_USE_IRRADIANCE_HACK
+ irradiance += amblit*0.5*vec3(dot(n, light_dir));
+#endif
specLight = srgb_to_linear(specLight);
#if HAS_IBL
kSpec = mix( kSpec, iridescenceFresnel, iridescenceFactor);