summaryrefslogtreecommitdiff
path: root/indra/llappearance/lltexlayer.cpp
diff options
context:
space:
mode:
authorGraham Linden <graham@lindenlab.com>2019-07-12 13:26:02 -0700
committerGraham Linden <graham@lindenlab.com>2019-07-12 13:26:02 -0700
commit11331604767b2dcf50c7a84f24843ce8e531a409 (patch)
tree4fb2ba1210025e9a26fe1127e4bf582be33001fc /indra/llappearance/lltexlayer.cpp
parent5bd99a6c5cb578849d870e64dae3b78369a00d2c (diff)
SL-11109
Make shadowAlphaMask shader ignore vertex alpha before discards iff we're a fullbright object. Keep llappearance from stuffing dangling pointers into the alpha cache (crash iff you're using nSight debugging and disable readbacks).
Diffstat (limited to 'indra/llappearance/lltexlayer.cpp')
-rw-r--r--indra/llappearance/lltexlayer.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/indra/llappearance/lltexlayer.cpp b/indra/llappearance/lltexlayer.cpp
index ca0d102b74..19a4f3e12d 100644
--- a/indra/llappearance/lltexlayer.cpp
+++ b/indra/llappearance/lltexlayer.cpp
@@ -1586,8 +1586,6 @@ void LLTexLayer::renderMorphMasks(S32 x, S32 y, S32 width, S32 height, const LLC
alpha_data = (U8*)ll_aligned_malloc_32(mem_size);
- mAlphaCache[cache_index] = alpha_data;
-
bool skip_readback = LLRender::sNsightDebugSupport || gGLManager.mIsIntel; // nSight doesn't support use of glReadPixels
if (!skip_readback)
@@ -1598,7 +1596,9 @@ void LLTexLayer::renderMorphMasks(S32 x, S32 y, S32 width, S32 height, const LLC
{
ll_aligned_free_32(alpha_data);
alpha_data = nullptr;
- }
+ }
+
+ mAlphaCache[cache_index] = alpha_data;
}
getTexLayerSet()->getAvatarAppearance()->dirtyMesh();