diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2023-03-23 01:18:07 +0200 |
---|---|---|
committer | akleshchev <117672381+akleshchev@users.noreply.github.com> | 2023-03-23 06:15:09 +0200 |
commit | d423263d54fc72cf857f3e147ac3860ca16c652f (patch) | |
tree | eecbc4369a16d93387551c319f226457960ab1f1 /indra/newview/llviewerobject.cpp | |
parent | 02091a04969a423c2b28f7532a09fb3956619d67 (diff) |
SL-19169 Local material updates aren't applied with non-default transforms
Diffstat (limited to 'indra/newview/llviewerobject.cpp')
-rw-r--r-- | indra/newview/llviewerobject.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp index cb1694821d..a3a825c199 100644 --- a/indra/newview/llviewerobject.cpp +++ b/indra/newview/llviewerobject.cpp @@ -5368,8 +5368,10 @@ S32 LLViewerObject::setTEGLTFMaterialOverride(U8 te, LLGLTFMaterial* override_ma LLFetchedGLTFMaterial* src_mat = (LLFetchedGLTFMaterial*) tep->getGLTFMaterial(); + // if override mat exists, we must also have a source mat if (!src_mat) - { // we can get into this state if an override has arrived before the viewer has + { + // we can get into this state if an override has arrived before the viewer has // received or handled an update, return TEM_CHANGE_NONE to signal to LLGLTFMaterialList that it // should queue the update for later return retval; @@ -5383,10 +5385,7 @@ S32 LLViewerObject::setTEGLTFMaterialOverride(U8 te, LLGLTFMaterial* override_ma tep->setGLTFMaterialOverride(override_mat); - // if override mat exists, we must also have a source mat - llassert(override_mat ? bool(src_mat) : true); - - if (override_mat && src_mat) + if (override_mat) { LLFetchedGLTFMaterial* render_mat = new LLFetchedGLTFMaterial(*src_mat); render_mat->applyOverride(*override_mat); |