summaryrefslogtreecommitdiff
path: root/indra/newview/llface.cpp
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2009-12-16 09:26:53 -0600
committerDave Parks <davep@lindenlab.com>2009-12-16 09:26:53 -0600
commitc6aaf115ade4b335df9ca479992b08e028ffd910 (patch)
tree3a126f9f3af41fd21ee326669e60922c333f55ad /indra/newview/llface.cpp
parentb6af8aae5b0cccfb6653d84e2020557c2be945ce (diff)
Quick 'n dirty prioritization scheme for mesh loading.
Sprinkling of fast timers in areas that are likely to stall.
Diffstat (limited to 'indra/newview/llface.cpp')
-rw-r--r--indra/newview/llface.cpp29
1 files changed, 25 insertions, 4 deletions
diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp
index 698d8572aa..91e2fef28d 100644
--- a/indra/newview/llface.cpp
+++ b/indra/newview/llface.cpp
@@ -183,22 +183,33 @@ void LLFace::init(LLDrawable* drawablep, LLViewerObject* objp)
mUsingAtlas = FALSE ;
}
+static LLFastTimer::DeclareTimer FTM_DESTROY_FACE("Destroy Face");
+static LLFastTimer::DeclareTimer FTM_DESTROY_TEXTURE("Texture");
+static LLFastTimer::DeclareTimer FTM_DESTROY_DRAWPOOL("Drawpool");
+static LLFastTimer::DeclareTimer FTM_DESTROY_TEXTURE_MATRIX("Texture Matrix");
+static LLFastTimer::DeclareTimer FTM_DESTROY_DRAW_INFO("Draw Info");
+static LLFastTimer::DeclareTimer FTM_DESTROY_ATLAS("Atlas");
+static LLFastTimer::DeclareTimer FTM_FACE_DEREF("Deref");
void LLFace::destroy()
{
+ LLFastTimer t(FTM_DESTROY_FACE);
if(mTexture.notNull())
{
+ LLFastTimer t(FTM_DESTROY_TEXTURE);
mTexture->removeFace(this) ;
}
if (mDrawPoolp)
{
+ LLFastTimer t(FTM_DESTROY_DRAWPOOL);
mDrawPoolp->removeFace(this);
mDrawPoolp = NULL;
}
if (mTextureMatrix)
{
+ LLFastTimer t(FTM_DESTROY_TEXTURE_MATRIX);
delete mTextureMatrix;
mTextureMatrix = NULL;
@@ -213,11 +224,21 @@ void LLFace::destroy()
}
}
- setDrawInfo(NULL);
+ {
+ LLFastTimer t(FTM_DESTROY_DRAW_INFO);
+ setDrawInfo(NULL);
+ }
- removeAtlas();
- mDrawablep = NULL;
- mVObjp = NULL;
+ {
+ LLFastTimer t(FTM_DESTROY_ATLAS);
+ removeAtlas();
+ }
+
+ {
+ LLFastTimer t(FTM_FACE_DEREF);
+ mDrawablep = NULL;
+ mVObjp = NULL;
+ }
}