diff options
author | Graham Madarasz (Graham Linden) <graham@lindenlab.com> | 2013-03-13 10:42:40 -0700 |
---|---|---|
committer | Graham Madarasz (Graham Linden) <graham@lindenlab.com> | 2013-03-13 10:42:40 -0700 |
commit | 5d2fea6262d91eb8d3c06d97a160ca9373b96889 (patch) | |
tree | cee0767a4cdf64a1167ece1d5b5645d0266f9069 /indra/llmath/llvolume.cpp | |
parent | ab60c46a917366574fa7292b6e7142ece858bec5 (diff) |
Move fast memcpy to llcommon and use it in llalignedarray pushback on all platforms. Code Review: DaveP
Diffstat (limited to 'indra/llmath/llvolume.cpp')
-rw-r--r-- | indra/llmath/llvolume.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/indra/llmath/llvolume.cpp b/indra/llmath/llvolume.cpp index 4f3e753276..e7a0bc7df7 100644 --- a/indra/llmath/llvolume.cpp +++ b/indra/llmath/llvolume.cpp @@ -4729,10 +4729,13 @@ void LLVolumeFace::optimize(F32 angle_cutoff) } } - llassert(new_face.mNumIndices == mNumIndices); - llassert(new_face.mNumVertices <= mNumVertices); - - swapData(new_face); + // Only swap data if we've actually optimized the mesh + // + if (new_face.mNumVertices < mNumVertices) + { + llassert(new_face.mNumIndices == mNumIndices); + swapData(new_face); + } } class LLVCacheTriangleData; |