diff options
author | Graham Linden <graham@lindenlab.com> | 2018-09-14 21:52:52 +0100 |
---|---|---|
committer | Graham Linden <graham@lindenlab.com> | 2018-09-14 21:52:52 +0100 |
commit | 1df7760d315430766bba44d4d4c64480b4a6138f (patch) | |
tree | f84ded9bc43e43b2c2fc985ed7a95aa4f0add69c /indra/newview/app_settings/shaders/class1/deferred | |
parent | a167f8857fd242e007a6bcbcee80a54a953f29f3 (diff) |
SL-9632 add uniform and code to supress atmospherics in all shaders that could be used by HUDs
Make sky and cloud shaders use common scaleSoftClip implementation in gammaF.glsl
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/deferred')
3 files changed, 3 insertions, 15 deletions
diff --git a/indra/newview/app_settings/shaders/class1/deferred/cloudsF.glsl b/indra/newview/app_settings/shaders/class1/deferred/cloudsF.glsl index 3f81e3b0af..c1a9a6f454 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/cloudsF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/cloudsF.glsl @@ -51,13 +51,7 @@ VARYING vec2 vary_texcoord2; VARYING vec2 vary_texcoord3; /// Soft clips the light with a gamma correction -vec3 scaleSoftClip(vec3 light) { - //soft clip effect: - light = 1. - clamp(light, vec3(0.), vec3(1.)); - light = 1. - pow(light, gamma.xxx); - - return light; -} +vec3 scaleSoftClip(vec3 light); vec4 cloudNoise(vec2 uv) { diff --git a/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl b/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl index 134e9c3b4c..0e21e5925d 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl @@ -1,5 +1,5 @@ /** - * @file fullbrightF.glsl + * @file deferred/fullbrightF.glsl * * $LicenseInfo:firstyear=2007&license=viewerlgpl$ * Second Life Viewer Source Code diff --git a/indra/newview/app_settings/shaders/class1/deferred/skyF.glsl b/indra/newview/app_settings/shaders/class1/deferred/skyF.glsl index 8e4696cfaa..0613111632 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/skyF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/skyF.glsl @@ -40,13 +40,7 @@ VARYING vec4 vary_HazeColor; uniform vec4 gamma; /// Soft clips the light with a gamma correction -vec3 scaleSoftClip(vec3 light) { - //soft clip effect: - light = 1. - clamp(light, vec3(0.), vec3(1.)); - light = 1. - pow(light, gamma.xxx); - - return light; -} +vec3 scaleSoftClip(vec3 light); void main() { |