From e32d1cf7564dd38664781ea7360fa8daa132961c Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Tue, 5 Apr 2011 15:28:18 -0600 Subject: fix for STORM-973: [crashhunters] crash at LLViewerTextureList::removeImageFromList(LLViewerFetchedTexture *) --- indra/newview/llviewertexturelist.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'indra/newview/llviewertexturelist.h') diff --git a/indra/newview/llviewertexturelist.h b/indra/newview/llviewertexturelist.h index d508ce1ac6..27aab0c081 100644 --- a/indra/newview/llviewertexturelist.h +++ b/indra/newview/llviewertexturelist.h @@ -83,6 +83,7 @@ public: void dump(); void destroyGL(BOOL save_state = TRUE); void restoreGL(); + BOOL isInitialized() const {return mInitialized;} LLViewerFetchedTexture *findImage(const LLUUID &image_id); @@ -120,8 +121,8 @@ private: void addImage(LLViewerFetchedTexture *image); void deleteImage(LLViewerFetchedTexture *image); - void addImageToList(LLViewerFetchedTexture *image); - void removeImageFromList(LLViewerFetchedTexture *image); + void addImageToList(LLViewerFetchedTexture *image, U32 thread_id = LLThread::currentID()); + void removeImageFromList(LLViewerFetchedTexture *image, U32 thread_id = LLThread::currentID()); LLViewerFetchedTexture * getImage(const LLUUID &image_id, BOOL usemipmap = TRUE, @@ -187,6 +188,7 @@ private: // simply holds on to LLViewerFetchedTexture references to stop them from being purged too soon std::set > mImagePreloads; + BOOL mInitialized ; BOOL mUpdateStats; S32 mMaxResidentTexMemInMegaBytes; S32 mMaxTotalTextureMemInMegaBytes; @@ -206,6 +208,9 @@ public: private: static S32 sNumImages; static void (*sUUIDCallback)(void**, const LLUUID &); + + //debug use + static U32 sRenderThreadID; }; class LLUIImageList : public LLImageProviderInterface, public LLSingleton -- cgit v1.2.3 From dbc92691a62be9c9cdb764ab6f17510c7c7ba64d Mon Sep 17 00:00:00 2001 From: brad kittenbrink Date: Thu, 5 May 2011 17:13:52 -0700 Subject: Work in progress on CHOP-609 / CHOP-624 build time improvements. Eliminated a bunch of unnecesary header dependencies. --- indra/newview/llviewertexturelist.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'indra/newview/llviewertexturelist.h') diff --git a/indra/newview/llviewertexturelist.h b/indra/newview/llviewertexturelist.h index d508ce1ac6..fa80de7989 100644 --- a/indra/newview/llviewertexturelist.h +++ b/indra/newview/llviewertexturelist.h @@ -212,24 +212,24 @@ class LLUIImageList : public LLImageProviderInterface, public LLSingleton getUIImageByID(const LLUUID& id, S32 priority); + /*virtual*/ LLPointer getUIImage(const std::string& name, S32 priority); void cleanUp(); bool initFromFile(); - LLUIImagePtr preloadUIImage(const std::string& name, const std::string& filename, BOOL use_mips, const LLRect& scale_rect); + LLPointer preloadUIImage(const std::string& name, const std::string& filename, BOOL use_mips, const LLRect& scale_rect); static void onUIImageLoaded( BOOL success, LLViewerFetchedTexture *src_vi, LLImageRaw* src, LLImageRaw* src_aux, S32 discard_level, BOOL final, void* userdata ); private: - LLUIImagePtr loadUIImageByName(const std::string& name, const std::string& filename, + LLPointer loadUIImageByName(const std::string& name, const std::string& filename, BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null, LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_UI); - LLUIImagePtr loadUIImageByID(const LLUUID& id, + LLPointer loadUIImageByID(const LLUUID& id, BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null, LLViewerTexture::EBoostLevel boost_priority = LLViewerTexture::BOOST_UI); - LLUIImagePtr loadUIImage(LLViewerFetchedTexture* imagep, const std::string& name, BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null); + LLPointer loadUIImage(LLViewerFetchedTexture* imagep, const std::string& name, BOOL use_mips = FALSE, const LLRect& scale_rect = LLRect::null); struct LLUIImageLoadData -- cgit v1.2.3