diff options
Diffstat (limited to 'indra/llmath')
-rw-r--r-- | indra/llmath/llvolume.cpp | 30 | ||||
-rw-r--r-- | indra/llmath/llvolume.h | 7 |
2 files changed, 29 insertions, 8 deletions
diff --git a/indra/llmath/llvolume.cpp b/indra/llmath/llvolume.cpp index 1a7f7ac1a0..7d01ba059c 100644 --- a/indra/llmath/llvolume.cpp +++ b/indra/llmath/llvolume.cpp @@ -1651,9 +1651,13 @@ void LLPathParams::copyParams(const LLPathParams ¶ms) setSkew(params.getSkew()); } +S32 profile_delete_lock = 1 ; LLProfile::~LLProfile() { - + if(profile_delete_lock) + { + llerrs << "LLProfile should not be deleted here!" << llendl ; + } } @@ -1710,7 +1714,11 @@ LLVolume::~LLVolume() { sNumMeshPoints -= mMesh.size(); delete mPathp; + + profile_delete_lock = 0 ; delete mProfilep; + profile_delete_lock = 1 ; + mPathp = NULL; mProfilep = NULL; mVolumeFaces.clear(); @@ -1755,6 +1763,20 @@ BOOL LLVolume::generate() mLODScaleBias.setVec(0.6f, 0.6f, 0.6f); } + //******************************************************************** + //debug info, to be removed + if((U32)(mPathp->mPath.size() * mProfilep->mProfile.size()) > (1u << 20)) + { + llinfos << "sizeS: " << mPathp->mPath.size() << " sizeT: " << mProfilep->mProfile.size() << llendl ; + llinfos << "path_detail : " << path_detail << " split: " << split << " profile_detail: " << profile_detail << llendl ; + llinfos << mParams << llendl ; + llinfos << "more info to check if mProfilep is deleted or not." << llendl ; + llinfos << mProfilep->mNormals.size() << " : " << mProfilep->mFaces.size() << " : " << mProfilep->mEdgeNormals.size() << " : " << mProfilep->mEdgeCenters.size() << llendl ; + + llerrs << "LLVolume corrupted!" << llendl ; + } + //******************************************************************** + BOOL regenPath = mPathp->generate(mParams.getPathParams(), path_detail, split); BOOL regenProf = mProfilep->generate(mParams.getProfileParams(), mPathp->isOpen(),profile_detail, split); @@ -1763,16 +1785,20 @@ BOOL LLVolume::generate() S32 sizeS = mPathp->mPath.size(); S32 sizeT = mProfilep->mProfile.size(); - //debug info + //******************************************************************** + //debug info, to be removed if((U32)(sizeS * sizeT) > (1u << 20)) { llinfos << "regenPath: " << (S32)regenPath << " regenProf: " << (S32)regenProf << llendl ; llinfos << "sizeS: " << sizeS << " sizeT: " << sizeT << llendl ; llinfos << "path_detail : " << path_detail << " split: " << split << " profile_detail: " << profile_detail << llendl ; llinfos << mParams << llendl ; + llinfos << "more info to check if mProfilep is deleted or not." << llendl ; + llinfos << mProfilep->mNormals.size() << " : " << mProfilep->mFaces.size() << " : " << mProfilep->mEdgeNormals.size() << " : " << mProfilep->mEdgeCenters.size() << llendl ; llerrs << "LLVolume corrupted!" << llendl ; } + //******************************************************************** sNumMeshPoints -= mMesh.size(); mMesh.resize(sizeT * sizeS); diff --git a/indra/llmath/llvolume.h b/indra/llmath/llvolume.h index 38e8f806e2..ab30d78333 100644 --- a/indra/llmath/llvolume.h +++ b/indra/llmath/llvolume.h @@ -672,9 +672,7 @@ public: mConcave(FALSE), mDirty(TRUE), mTotalOut(0), - mTotal(2), - mMinX(0.f), - mMaxX(0.f) + mTotal(2) { } @@ -722,9 +720,6 @@ protected: S32 mTotalOut; S32 mTotal; - - F32 mMaxX; - F32 mMinX; }; //------------------------------------------------------------------- |