diff options
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llpolymesh.cpp | 4 | ||||
-rw-r--r-- | indra/newview/llspatialpartition.cpp | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/indra/newview/llpolymesh.cpp b/indra/newview/llpolymesh.cpp index 4b2c569cc3..450f9b2be7 100644 --- a/indra/newview/llpolymesh.cpp +++ b/indra/newview/llpolymesh.cpp @@ -770,7 +770,7 @@ LLPolyMesh::LLPolyMesh(LLPolyMeshSharedData *shared_data, LLPolyMesh *reference_ int nverts = mSharedData->mNumVertices; int nfloats = nverts * (2*4 + 3*3 + 2 + 4); //use 16 byte aligned vertex data to make LLPolyMesh SSE friendly - mVertexData = (F32*) malloc(nfloats*4); + mVertexData = (F32*) ll_aligned_malloc_16(nfloats*4); int offset = 0; mCoords = (LLVector4*)(mVertexData + offset); offset += 4*nverts; mNormals = (LLVector4*)(mVertexData + offset); offset += 4*nverts; @@ -799,7 +799,7 @@ LLPolyMesh::~LLPolyMesh() mJointRenderData[i] = NULL; } - free(mVertexData); + ll_aligned_free_16(mVertexData); } diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 65f7d299bc..34a42ff28b 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -3169,11 +3169,11 @@ void renderPhysicsShape(LLDrawable* drawable, LLVOVolume* volume) LLConvexDecomposition::getInstance()->generateSingleHullMeshFromMesh( &mesh, &res ); //copy res into phys_volume - phys_volume->mHullPoints = (LLVector4a*) malloc(sizeof(LLVector4a)*res.mNumVertices); + phys_volume->mHullPoints = (LLVector4a*) ll_aligned_malloc_16(sizeof(LLVector4a)*res.mNumVertices); phys_volume->mNumHullPoints = res.mNumVertices; S32 idx_size = (res.mNumTriangles*3*2+0xF) & ~0xF; - phys_volume->mHullIndices = (U16*) malloc(idx_size); + phys_volume->mHullIndices = (U16*) ll_aligned_malloc_16(idx_size); phys_volume->mNumHullIndices = res.mNumTriangles*3; const F32* v = res.mVertexBase; |