summaryrefslogtreecommitdiff
path: root/indra/newview/llviewertexture.h
diff options
context:
space:
mode:
authorXiaohong Bao <bao@lindenlab.com>2009-12-29 15:02:22 -0700
committerXiaohong Bao <bao@lindenlab.com>2009-12-29 15:02:22 -0700
commitb07564b15cf90c757beb86b3ef41224a55d48da4 (patch)
treea48920379881a73d8917bf95e1112b2054e0c9ee /indra/newview/llviewertexture.h
parent6ed6bed5acd5352b5c3ca02f86a62397f5257a5f (diff)
fix for DEV-44134: trying to move away from a huge amount of objects with media causes viewer to hang for 15-20 seconds.
Diffstat (limited to 'indra/newview/llviewertexture.h')
-rw-r--r--indra/newview/llviewertexture.h18
1 files changed, 11 insertions, 7 deletions
diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h
index d6fbd5d570..6aaaa4021b 100644
--- a/indra/newview/llviewertexture.h
+++ b/indra/newview/llviewertexture.h
@@ -134,7 +134,7 @@ public:
static S32 getIndexFromCategory(S32 category) ;
static S32 getCategoryFromIndex(S32 index) ;
- typedef std::list<LLFace*> ll_face_list_t ;
+ typedef std::vector<LLFace*> ll_face_list_t ;
protected:
virtual ~LLViewerTexture();
@@ -175,7 +175,8 @@ public:
virtual void addFace(LLFace* facep) ;
virtual void removeFace(LLFace* facep) ;
- const ll_face_list_t* getFaceList() const {return &mFaceList ;}
+ S32 getNumFaces() const;
+ const ll_face_list_t* getFaceList() const {return &mFaceList;}
void generateGLTexture() ;
void destroyGLTexture() ;
@@ -239,13 +240,14 @@ public:
/*virtual*/ void updateBindStatsForTester() ;
protected:
void cleanup() ;
- void init(bool firstinit) ;
+ void init(bool firstinit) ;
+ void reorganizeFaceList() ;
private:
//note: do not make this function public.
/*virtual*/ LLImageGL* getGLTexture() const ;
virtual void switchToCachedImage();
-
+
protected:
LLUUID mID;
S32 mBoostLevel; // enum describing priority level
@@ -257,14 +259,16 @@ protected:
mutable S8 mNeedsGLTexture;
mutable BOOL mNeedsResetMaxVirtualSize ;
mutable F32 mAdditionalDecodePriority; // priority add to mDecodePriority.
- LLFrameTimer mLastReferencedTimer;
-
- ll_face_list_t mFaceList ; //reverse pointer pointing to the faces using this image as texture
+ LLFrameTimer mLastReferencedTimer;
//GL texture
LLPointer<LLImageGL> mGLTexturep ;
S8 mDontDiscard; // Keep full res version of this image (for UI, etc)
+ ll_face_list_t mFaceList ; //reverse pointer pointing to the faces using this image as texture
+ U32 mNumFaces ;
+ LLFrameTimer mLastFaceListUpdateTimer ;
+
//do not use LLPointer here.
LLViewerMediaTexture* mParcelMedia ;