From 38845a1e05a5932b9fb23ab249b7d272bd80643f Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Tue, 26 Nov 2024 20:51:41 +0200 Subject: viewer#3147 Thumbnail picker's image is grey when both thumnail and normal image attempt to fetch, one creates a fetcher, another fails, since fetcher is already there, potentially in a transitional state, so it thinks fetch failed. --- indra/newview/llviewertexture.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'indra/newview/llviewertexture.cpp') diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp index 4a15b8624a..d2511aef7b 100644 --- a/indra/newview/llviewertexture.cpp +++ b/indra/newview/llviewertexture.cpp @@ -1965,7 +1965,9 @@ bool LLViewerFetchedTexture::updateFetch() if (!mIsFetching) { - if ((decode_priority > 0) && (mRawDiscardLevel < 0 || mRawDiscardLevel == INVALID_DISCARD_LEVEL)) + if ((decode_priority > 0) + && (mRawDiscardLevel < 0 || mRawDiscardLevel == INVALID_DISCARD_LEVEL) + && mFetchState > 1) // 1 - initial, make sure fetcher did at least something { // We finished but received no data if (getDiscardLevel() < 0) @@ -2003,6 +2005,9 @@ bool LLViewerFetchedTexture::updateFetch() { // We have data, but our fetch failed to return raw data // *TODO: FIgure out why this is happening and fix it + // Potentially can happen when TEX_LIST_SCALE and TEX_LIST_STANDARD + // get requested for the same texture id at the same time + // (two textures, one fetcher) destroyRawImage(); } } -- cgit v1.2.3