summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings
diff options
context:
space:
mode:
authorGraham Madarasz <graham@lindenlab.com>2013-04-20 03:36:21 -0700
committerGraham Madarasz <graham@lindenlab.com>2013-04-20 03:36:21 -0700
commitb2344cfd13bc0dc7175cf3895b7111186dc573c9 (patch)
tree2350c8294e38b253aedf30c39c064a0030ec2ff9 /indra/newview/app_settings
parentabb72591d4f480e90ee66951b49d34f90dd7c96c (diff)
Fix rendering artifacts on Mac Mobile GeForce cards
Diffstat (limited to 'indra/newview/app_settings')
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/materialF.glsl7
1 files changed, 7 insertions, 0 deletions
diff --git a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl
index 7752189e1d..09a2d4467a 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl
@@ -622,6 +622,13 @@ void main()
#else
frag_data[0] = final_color;
+
+#ifdef UGLY_MAC_HACK
+ // magic spec exp clamp fixes rendering artifacts on older mac GF drivers
+ //
+ final_specular = min(final_specular, vec4(1.0f, 1.0f, 1.0f, 0.125f));
+#endif
+
frag_data[1] = final_specular; // XYZ = Specular color. W = Specular exponent.
frag_data[2] = final_normal; // XY = Normal. Z = Env. intensity.
#endif