From d189dc4af2f42da7d2f1b6226a8897d162542c13 Mon Sep 17 00:00:00 2001 From: samcake Date: Mon, 21 Mar 2016 13:30:08 -0700 Subject: [PATCH] Problem not fixed yet, need to merge with upstream --- libraries/render-utils/src/MaterialTextures.slh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libraries/render-utils/src/MaterialTextures.slh b/libraries/render-utils/src/MaterialTextures.slh index ef8c30a97f..b25876af63 100644 --- a/libraries/render-utils/src/MaterialTextures.slh +++ b/libraries/render-utils/src/MaterialTextures.slh @@ -114,9 +114,9 @@ vec3 fetchLightmapMap(vec2 uv) { <@func evalMaterialOpacity(fetchedOpacity, materialOpacity, matKey, opacity)@> { - const float OPACITY_MASK_THRESHOLD = 0.5; - <$opacity$> = (((<$matKey$> & (OPACITY_TRANSLUCENCY_MAP_BIT | OPACITY_MASK_MAP_BIT)) != 0) ? - (((<$matKey$> & OPACITY_MASK_MAP_BIT) != 0) ? step(OPACITY_MASK_THRESHOLD, <$fetchedOpacity$>) : <$fetchedOpacity$>) : + const float OPACITY_MASK_THRESHOLD = 0.95; + <$opacity$> = (((<$matKey$> & (OPACITY_TRANSLUCENT_MAP_BIT | OPACITY_MASK_MAP_BIT)) != 0) ? + (((<$matKey$> & OPACITY_MASK_MAP_BIT) != 0) ? step(<$fetchedOpacity$>, OPACITY_MASK_THRESHOLD) : <$fetchedOpacity$>) : 1.0) * <$materialOpacity$>; } <@endfunc@>