summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl
diff options
context:
space:
mode:
authorGeenz <geenz@geenzo.com>2013-04-18 21:31:10 -0400
committerGeenz <geenz@geenzo.com>2013-04-18 21:31:10 -0400
commitb6a6479c372e311b45e27eafd368e2045ca21790 (patch)
tree9c01ed4b9af3a2cd4a784f6cbf2c25bacb8c4dfd /indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl
parent14b807e55efcfb8a9b52909fd554c9ba1cea0f36 (diff)
Mitigation for light attenuation looking different with gamma correction. Assume that light attenuation wants to be linearized before we apply gamma correction.
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl')
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl1
1 files changed, 1 insertions, 0 deletions
diff --git a/indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl b/indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl
index a339f6506e..56c10e25cc 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/spotLightF.glsl
@@ -175,6 +175,7 @@ void main()
float fa = falloff+1.0;
float dist_atten = min(1.0-(dist2-1.0*(1.0-fa))/fa, 1.0);
+ dist_atten = pow(dist_atten, 2.2) * 2.2;
if (dist_atten <= 0.0)
{
discard;