summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorGeenz <geenz@geenzo.com>2019-04-10 02:49:25 -0700
committerGeenz <geenz@geenzo.com>2019-04-10 02:49:25 -0700
commitd7d8a15092c91f6fa55547515b243b61a78868ff (patch)
treecd73d4b35b3464d44137d634fcc8064d36a9f813 /indra
parent08812cbe060e62cb8b61e91bc2f878a74a0015e5 (diff)
Fullbright + elimination of all references to calcFragAtmospherics.
--HG-- branch : OPEN-340
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl4
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl5
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/materialF.glsl4
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl4
-rw-r--r--indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl3
5 files changed, 11 insertions, 9 deletions
diff --git a/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl b/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl
index 4fe0d1351d..ca82dd9432 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl
@@ -77,7 +77,7 @@ vec2 encode_normal (vec3 n);
vec3 scaleSoftClipFrag(vec3 l);
vec3 atmosFragLighting(vec3 light, vec3 additive, vec3 atten);
-void calcFragAtmospherics(vec3 inPositionEye, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 atten, out vec3 additive);
+void calcAtmosphericVars(vec3 inPositionEye, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 atten, out vec3 additive);
#ifdef HAS_SHADOW
float sampleDirectionalShadow(vec3 pos, vec3 norm, vec2 pos_screen);
@@ -184,7 +184,7 @@ void main()
vec3 additive;
vec3 atten;
- calcFragAtmospherics(pos.xyz, 1.0, sunlit, amblit, additive, atten);
+ calcAtmosphericVars(pos.xyz, 1.0, sunlit, amblit, additive, atten);
vec2 abnormal = encode_normal(norm.xyz);
diff --git a/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl b/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl
index d5ef010017..f98fc0d518 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl
@@ -45,6 +45,9 @@ VARYING vec2 vary_texcoord0;
vec4 applyWaterFogView(vec3 pos, vec4 color);
#endif
+vec3 fullbrightAtmosTransport(vec3 light);
+vec3 fullbrightScaleSoftClip(vec3 light);
+
#ifdef HAS_ALPHA_MASK
uniform float minimum_alpha;
#endif
@@ -74,6 +77,8 @@ void main()
color.rgb = fogged.rgb;
color.a = fogged.a;
#else
+ color.rgb = fullbrightAtmosTransport(color.rgb);
+ color.rgb = fullbrightScaleSoftClip(color.rgb);
color.a = final_alpha;
#endif
diff --git a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl
index 6d7162b5a2..9b07c11361 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl
@@ -41,7 +41,7 @@ vec4 applyWaterFogView(vec3 pos, vec4 color);
vec3 atmosFragLighting(vec3 l, vec3 additive, vec3 atten);
vec3 scaleSoftClipFrag(vec3 l);
-void calcFragAtmospherics(vec3 inPositionEye, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 additive, out vec3 atten);
+void calcAtmosphericVars(vec3 inPositionEye, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 additive, out vec3 atten);
vec3 srgb_to_linear(vec3 cs);
vec3 linear_to_srgb(vec3 cs);
@@ -290,7 +290,7 @@ void main()
vec3 additive;
vec3 atten;
- calcFragAtmospherics(pos.xyz, 1.0, sunlit, amblit, additive, atten);
+ calcAtmosphericVars(pos.xyz, 1.0, sunlit, amblit, additive, atten);
vec3 refnormpersp = normalize(reflect(pos.xyz, norm.xyz));
diff --git a/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl b/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl
index c599c14b43..b166f45bce 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl
@@ -71,8 +71,6 @@ vec3 getNorm(vec2 pos_screen);
vec3 atmosFragLighting(vec3 l, vec3 additive, vec3 atten);
vec3 fullbrightAtmosTransportFrag(vec3 l, vec3 additive, vec3 atten);
-void calcFragAtmospherics(vec3 inPositionEye, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 additive, out vec3 atten);
-
void calcAtmosphericVars(vec3 inPositionEye, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 additive, out vec3 atten);
vec3 scaleSoftClipFrag(vec3 l);
@@ -168,7 +166,7 @@ vec3 post_diffuse = col.rgb;
col = mix(col.rgb, refcol, envIntensity);
}
- if (norm.w < 0.5)
+ //if (norm.w < 0.5)
{
col = atmosFragLighting(col, additive, atten);
col = scaleSoftClipFrag(col);
diff --git a/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl b/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl
index 2a772e6741..e1e299edee 100644
--- a/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl
+++ b/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl
@@ -67,7 +67,6 @@ uniform vec2 screen_res;
vec3 getNorm(vec2 pos_screen);
-void calcFragAtmospherics(vec3 inPositionEye, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 additive, out vec3 atten);
vec3 atmosFragLighting(vec3 l, vec3 additive, vec3 atten);
vec3 fullbrightScaleSoftClipFrag(vec3 l, vec3 add, vec3 atten);
vec3 scaleSoftClipFrag(vec3 l);
@@ -184,7 +183,7 @@ vec3 post_diffuse = col.rgb;
col = mix(col.rgb, refcol, envIntensity);
}
- if (norm.w < 0.5)
+ //if (norm.w < 0.5)
{
//col = mix(atmosFragLighting(col, additive, atten), fullbrightAtmosTransportFrag(col, additive, atten), diffuse.a);
//col = mix(scaleSoftClipFrag(col), fullbrightScaleSoftClipFrag(col, additive, atten), diffuse.a);