From 361a2277733a0afaf61f6c6150f1933d2e5aceb7 Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Thu, 29 Oct 2009 16:12:12 -0600 Subject: fix EXT-1661: Avatars' icons should be cached only once per 24 hours, but not every time the viewer is restarted. to be reviewed by steve. --- indra/newview/llviewertexture.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'indra/newview/llviewertexture.h') diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h index 480e1c1cbc..ef298319d2 100644 --- a/indra/newview/llviewertexture.h +++ b/indra/newview/llviewertexture.h @@ -163,6 +163,7 @@ public: S32 getFullWidth() const { return mFullWidth; } S32 getFullHeight() const { return mFullHeight; } + /*virtual*/ void setKnownDrawSize(S32 width, S32 height); virtual void addFace(LLFace* facep) ; virtual void removeFace(LLFace* facep) ; @@ -357,7 +358,7 @@ public: // Override the computation of discard levels if we know the exact output // size of the image. Used for UI textures to not decode, even if we have // more data. - void setKnownDrawSize(S32 width, S32 height); + /*virtual*/ void setKnownDrawSize(S32 width, S32 height); void setIsMissingAsset(); /*virtual*/ BOOL isMissingAsset() const { return mIsMissingAsset; } @@ -406,6 +407,8 @@ private: BOOL mFullyLoaded; protected: + std::string mLocalFileName; + S32 mOrigWidth; S32 mOrigHeight; @@ -413,8 +416,7 @@ protected: // Used for UI textures to not decode, even if we have more data. S32 mKnownDrawWidth; S32 mKnownDrawHeight; - - std::string mLocalFileName; + BOOL mKnownDrawSizeChanged ; S8 mDesiredDiscardLevel; // The discard level we'd LIKE to have - if we have it and there's space S8 mMinDesiredDiscardLevel; // The minimum discard level we'd like to have @@ -570,7 +572,7 @@ public: static LLTexturePipelineTester* sTesterp ; //returns NULL if tex is not a LLViewerFetchedTexture nor derived from LLViewerFetchedTexture. - static LLViewerFetchedTexture* staticCastToFetchedTexture(LLViewerTexture* tex, BOOL report_error = FALSE) ; + static LLViewerFetchedTexture* staticCastToFetchedTexture(LLTexture* tex, BOOL report_error = FALSE) ; // //"find-texture" just check if the texture exists, if yes, return it, otherwise return null. -- cgit v1.2.3 From 801301c435414df1e22c321a685044b7cd43055e Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Fri, 30 Oct 2009 21:22:47 -0600 Subject: fix DEV-41913: parcel media does not display on particle textures. --- indra/newview/llviewertexture.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'indra/newview/llviewertexture.h') diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h index ef298319d2..ce8c47b878 100644 --- a/indra/newview/llviewertexture.h +++ b/indra/newview/llviewertexture.h @@ -221,6 +221,9 @@ public: BOOL getDontDiscard() const { return mDontDiscard; } //----------------- + void setParcelMedia(BOOL has_media) {mHasParcelMedia = has_media;} + BOOL hasParcelMedia() const { return mHasParcelMedia ;} + /*virtual*/ void updateBindStatsForTester() ; protected: void cleanup() ; @@ -247,6 +250,8 @@ protected: LLPointer mGLTexturep ; S8 mDontDiscard; // Keep full res version of this image (for UI, etc) + BOOL mHasParcelMedia ; + protected: typedef enum { @@ -547,6 +552,7 @@ private: LLViewerMediaImpl* mMediaImplp ; BOOL mIsPlaying ; U32 mUpdateVirtualSizeTime ; + LLPointer< LLViewerTexture > mParcelTexture ; //the texture replaces this media texure when it is a parcel media texture. public: static void updateClass() ; -- cgit v1.2.3 From 99d9712dd7f2a11a1094cba380f92e677710b56b Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Sun, 1 Nov 2009 17:27:25 -0700 Subject: additional fix for DEV-41913: parcel media does not display on particle textures. --- indra/newview/llviewertexture.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'indra/newview/llviewertexture.h') diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h index ce8c47b878..020478beef 100644 --- a/indra/newview/llviewertexture.h +++ b/indra/newview/llviewertexture.h @@ -221,8 +221,9 @@ public: BOOL getDontDiscard() const { return mDontDiscard; } //----------------- - void setParcelMedia(BOOL has_media) {mHasParcelMedia = has_media;} - BOOL hasParcelMedia() const { return mHasParcelMedia ;} + void setParcelMedia(LLViewerMediaTexture* media) {mParcelMedia = media;} + BOOL hasParcelMedia() const { return mParcelMedia != NULL;} + LLViewerMediaTexture* getParcelMedia() const { return mParcelMedia;} /*virtual*/ void updateBindStatsForTester() ; protected: @@ -250,7 +251,8 @@ protected: LLPointer mGLTexturep ; S8 mDontDiscard; // Keep full res version of this image (for UI, etc) - BOOL mHasParcelMedia ; + //do not use LLPointer here. + LLViewerMediaTexture* mParcelMedia ; protected: typedef enum @@ -552,7 +554,6 @@ private: LLViewerMediaImpl* mMediaImplp ; BOOL mIsPlaying ; U32 mUpdateVirtualSizeTime ; - LLPointer< LLViewerTexture > mParcelTexture ; //the texture replaces this media texure when it is a parcel media texture. public: static void updateClass() ; -- cgit v1.2.3