diff options
author | Graham Linden <graham@lindenlab.com> | 2019-04-25 10:59:00 -0700 |
---|---|---|
committer | Graham Linden <graham@lindenlab.com> | 2019-04-25 10:59:00 -0700 |
commit | 4ed05fc84fce0fbee76c583e91feed5aff2dbbfc (patch) | |
tree | 31bfec7a2b09919d9df3a050d2f2ed369d31f0ad /indra/newview/app_settings/shaders/class1/deferred | |
parent | ca16874379bf76dd844d57b2ee59da531d642a8e (diff) |
Fix dark ALM and strangeness at Mid lighting (class 3 but with a darkness about it).
Make a distinct class3/lighting/lightV which boosts to WL levels (* 2.0)
and make lighting without WL atmo enabled use class 2 or below.
Make forward shaders (alpha and materialF with alpha-blend mode on) more consistent with deferred lighting.
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/deferred')
3 files changed, 5 insertions, 5 deletions
diff --git a/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl b/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl index e8400ba66d..8709053ac6 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl @@ -201,7 +201,6 @@ void main() float final_da = da; final_da = clamp(final_da, 0.0f, 1.0f); - final_da = pow(final_da, 1.0/1.3); vec4 color = vec4(0,0,0,0); diff --git a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl index f1dbf4af46..5926236fd7 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl @@ -302,7 +302,6 @@ void main() float final_da = da; final_da = clamp(final_da, 0.0, 1.0); - final_da = pow(final_da, 1.0 / 1.3); float ambient = da; ambient *= 0.5; @@ -372,6 +371,8 @@ vec3 post_spec = col.rgb; glare += cur_glare; } +vec3 post_env = col.rgb; + col = atmosFragLighting(col, additive, atten); col = scaleSoftClipFrag(col); @@ -379,7 +380,7 @@ vec3 post_spec = col.rgb; vec3 light = vec3(0,0,0); - vec3 prelight_linearish_maybe = srgb_to_linear(col.rgb); +vec3 post_atmo = col.rgb; #define LIGHT_LOOP(i) light.rgb += calcPointLightOrSpotLight(light_diffuse[i].rgb, npos, diffuse.rgb, final_specular, pos.xyz, norm.xyz, light_position[i], light_direction[i].xyz, light_attenuation[i].x, light_attenuation[i].y, light_attenuation[i].z, glare, light_attenuation[i].w * 0.5); @@ -393,7 +394,7 @@ vec3 post_spec = col.rgb; vec3 light_linear = light.rgb; - col.rgb += light.rgb; + col.rgb += light_linear; vec3 postlight_linear = col.rgb; diff --git a/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl b/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl index 68deedd0d0..83006c8916 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl @@ -108,7 +108,7 @@ void main() vec3 atten; calcAtmosphericVars(pos.xyz, 1.0, sunlit, amblit, additive, atten); - sunlit *= 0.5; + float ambient = da; ambient *= 0.5; ambient *= ambient; |