diff options
author | Dave Parks <davep@lindenlab.com> | 2013-06-03 17:10:37 -0500 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2013-06-03 17:10:37 -0500 |
commit | f3036451564a00da5af4935ca59d22103ba46066 (patch) | |
tree | 866cba425b55cd519dc6648195959284f9537f0e /indra/newview/app_settings/shaders | |
parent | bc57b8050c2cb7decd9ac1b3e9f640c5f25bd53c (diff) |
NORSPEC-195 Fix for incorrect alpha blending with deferred rendering enabled.
Diffstat (limited to 'indra/newview/app_settings/shaders')
7 files changed, 15 insertions, 0 deletions
diff --git a/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl b/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl index 50b43f6a8d..77a53a71aa 100755 --- a/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/alphaF.glsl @@ -252,6 +252,8 @@ void main() color.rgb += diff.rgb * vary_pointlight_col * col.rgb; + color.rgb = pow(color.rgb, vec3(1.0/2.2)); + frag_color = color; } diff --git a/indra/newview/app_settings/shaders/class1/deferred/alphaNonIndexedF.glsl b/indra/newview/app_settings/shaders/class1/deferred/alphaNonIndexedF.glsl index cccc7275ab..2ce44d599f 100755 --- a/indra/newview/app_settings/shaders/class1/deferred/alphaNonIndexedF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/alphaNonIndexedF.glsl @@ -140,6 +140,8 @@ void main() color.rgb += diff.rgb * vary_pointlight_col * light_col; + color.rgb = pow(color.rgb, vec3(1.0/2.2)); + frag_color = color; //frag_color = vec4(1,0,1,1); //frag_color = vec4(1,0,1,1)*shadow; diff --git a/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl b/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl index 5c164f7759..dc1dead656 100755 --- a/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/fullbrightF.glsl @@ -56,6 +56,8 @@ void main() color.rgb = fullbrightScaleSoftClip(color.rgb); + color.rgb = pow(color.rgb, vec3(1.0/2.2)); + frag_color = color; } diff --git a/indra/newview/app_settings/shaders/class1/deferred/fullbrightShinyF.glsl b/indra/newview/app_settings/shaders/class1/deferred/fullbrightShinyF.glsl index f3d04a22f2..b0db9876d3 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/fullbrightShinyF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/fullbrightShinyF.glsl @@ -65,6 +65,8 @@ void main() color.a = 1.0; + color.rgb = pow(color.rgb, vec3(1.0/2.2)); + frag_color = color; } diff --git a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl index df8e7a6c0b..bb8d26c9dc 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl @@ -665,6 +665,9 @@ void main() LIGHT_LOOP(6) LIGHT_LOOP(7) + + col.rgb = pow(col.rgb, vec3(1.0/2.2)); + frag_color.rgb = col.rgb; glare = min(glare, 1.0); frag_color.a = max(diffcol.a*vertex_color.a, glare); diff --git a/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightF.glsl b/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightF.glsl index 361f316065..c8771a3f1e 100755 --- a/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightF.glsl +++ b/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightF.glsl @@ -47,6 +47,8 @@ void fullbright_lighting() color.rgb = fullbrightScaleSoftClip(color.rgb); + color.rgb = pow(color.rgb, vec3(1.0/texture_gamma)); + frag_color = color; } diff --git a/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightNonIndexedAlphaMaskF.glsl b/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightNonIndexedAlphaMaskF.glsl index d64584c015..f72f20b03d 100755 --- a/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightNonIndexedAlphaMaskF.glsl +++ b/indra/newview/app_settings/shaders/class1/lighting/lightFullbrightNonIndexedAlphaMaskF.glsl @@ -56,6 +56,8 @@ void fullbright_lighting() color.rgb = fullbrightScaleSoftClip(color.rgb); + color.rgb = pow(color.rgb, vec3(1.0/texture_gamma)); + frag_color = color; } |