summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRunitai Linden <davep@lindenlab.com>2021-12-15 13:44:22 -0600
committerRunitai Linden <davep@lindenlab.com>2021-12-15 13:44:22 -0600
commit199775b7ac214cfc3492c343c3f6046effcde7ed (patch)
treec3b3bc7651399a799fc6df3db5aea94819446b93
parent8bf5597db2f10c4a423af5df333ff0f1c7fd9c99 (diff)
parent915376b37988f93704553aeda103d525420997ea (diff)
Merge branch 'DRTVWR-546' of ssh://bitbucket.org/lindenlab/viewer into DRTVWR-546
-rw-r--r--indra/newview/llmodelpreview.cpp4
-rw-r--r--indra/newview/llvovolume.cpp13
2 files changed, 15 insertions, 2 deletions
diff --git a/indra/newview/llmodelpreview.cpp b/indra/newview/llmodelpreview.cpp
index 1da9e6c651..5d81d2c9b3 100644
--- a/indra/newview/llmodelpreview.cpp
+++ b/indra/newview/llmodelpreview.cpp
@@ -1325,8 +1325,8 @@ F32 LLModelPreview::genMeshOptimizerPerModel(LLModel *base_model, LLModel *targe
LLVector4a::memcpyNonAliased16((F32*)(combined_normals + combined_positions_shift), (F32*)face.mNormals, copy_bytes);
// tex coords
- copy_bytes = (face.mNumVertices * sizeof(LLVector2) + 0xF) & ~0xF;
- LLVector4a::memcpyNonAliased16((F32*)(combined_tex_coords + combined_positions_shift), (F32*)face.mTexCoords, copy_bytes);
+ copy_bytes = face.mNumVertices * sizeof(LLVector2);
+ memcpy((void*)(combined_tex_coords + combined_positions_shift), (void*)face.mTexCoords, copy_bytes);
combined_positions_shift += face.mNumVertices;
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index a4f217bbcb..d20bf3e871 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -5669,6 +5669,19 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group)
facep->mAvatar = avatar;
any_rigged_face = true;
}
+ else
+ {
+ if (facep->isState(LLFace::RIGGED))
+ {
+ //face is not rigged but used to be, remove from rigged face pool
+ LLDrawPoolAvatar* pool = (LLDrawPoolAvatar*) facep->getPool();
+ if (pool)
+ {
+ pool->removeFace(facep);
+ }
+ facep->clearState(LLFace::RIGGED);
+ }
+ }
if (cur_total > max_total || facep->getIndicesCount() <= 0 || facep->getGeomCount() <= 0)
{