Merge pull request #1358 from sacereda/optimizeMeshes
Low performance in OptimizeMeshesProcess with huge number of meshespull/1364/head
commit
ae9755286a
|
@ -181,11 +181,8 @@ void OptimizeMeshesProcess::ProcessNode( aiNode* pNode)
|
||||||
verts += mScene->mMeshes[am]->mNumVertices;
|
verts += mScene->mMeshes[am]->mNumVertices;
|
||||||
faces += mScene->mMeshes[am]->mNumFaces;
|
faces += mScene->mMeshes[am]->mNumFaces;
|
||||||
|
|
||||||
|
pNode->mMeshes[a] = pNode->mMeshes[pNode->mNumMeshes - 1];
|
||||||
--pNode->mNumMeshes;
|
--pNode->mNumMeshes;
|
||||||
for( unsigned int n = a; n < pNode->mNumMeshes; ++n ) {
|
|
||||||
pNode->mMeshes[ n ] = pNode->mMeshes[ n + 1 ];
|
|
||||||
}
|
|
||||||
|
|
||||||
--a;
|
--a;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue