Skip to content

Commit

Permalink
viewer#3147 Thumbnail picker's image is grey
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
akleshchev committed Nov 26, 2024
1 parent d65fb7c commit b7f6846
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion indra/newview/llviewertexture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down Expand Up @@ -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();
}
}
Expand Down

0 comments on commit b7f6846

Please sign in to comment.