Skip to content

Commit 18f9f19

Browse files
committed
Textures mid-decode potentially processing of other textures until complete. Disabled UDP texture fetch fallback when connected to official grid.
1 parent 4198f47 commit 18f9f19

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

indra/newview/lltexturefetch.cpp

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -872,7 +872,7 @@ LLTextureFetchWorker::LLTextureFetchWorker(LLTextureFetch* fetcher,
872872
mCacheReadCount(0U),
873873
mCacheWriteCount(0U)
874874
{
875-
mCanUseNET = mUrl.empty() ;
875+
mCanUseNET = mUrl.empty() && !gHippoGridManager->getConnectedGrid()->isSecondLife();
876876

877877
if (!mCanUseNET)
878878
{
@@ -1236,9 +1236,10 @@ bool LLTextureFetchWorker::doWork(S32 param)
12361236
if (mState == LOAD_FROM_NETWORK)
12371237
{
12381238
static LLCachedControl<bool> use_http(gSavedSettings,"ImagePipelineUseHTTP");
1239+
bool is_sl = gHippoGridManager->getConnectedGrid()->isSecondLife();
12391240

12401241
// if (mHost != LLHost::invalid) use_http = false;
1241-
if (use_http && mCanUseHTTP && mUrl.empty()) // get http url.
1242+
if ((is_sl || use_http) && mCanUseHTTP && mUrl.empty()) // get http url.
12421243
{
12431244
LLViewerRegion* region = NULL;
12441245
if (mHost == LLHost::invalid)
@@ -1280,6 +1281,7 @@ bool LLTextureFetchWorker::doWork(S32 param)
12801281
mWriteToCacheState = CAN_WRITE;
12811282
}
12821283
if (!mUrl.empty() && SGHostBlackList::isBlacklisted(mUrl)){
1284+
LL_DEBUGS("Texture") << mID << "Blacklisted" << LL_ENDL;
12831285
mCanUseHTTP = false;
12841286
}
12851287
if (mCanUseHTTP && !mUrl.empty())
@@ -1292,7 +1294,12 @@ bool LLTextureFetchWorker::doWork(S32 param)
12921294
}
12931295
// don't return, fall through to next state
12941296
}
1295-
else if (mSentRequest == UNSENT && mCanUseNET)
1297+
else if (!mCanUseNET)
1298+
{
1299+
LL_WARNS(LOG_TXT) << mID << "Unable to retrieve texture via HTTP and UDP unavailable (probable 404): " << mUrl << LL_ENDL;
1300+
return true;
1301+
}
1302+
else if (mSentRequest == UNSENT)
12961303
{
12971304
LL_DEBUGS("Texture") << mID << " moving to UDP fetch. mSentRequest=" << mSentRequest << " mCanUseNET = " << mCanUseNET << LL_ENDL;
12981305
setState(SEND_UDP_REQ);
@@ -1821,6 +1828,7 @@ bool LLTextureFetchWorker::doWork(S32 param)
18211828
S32 discard = mHaveAllData ? 0 : mLoadedDiscard;
18221829
U32 image_priority = LLWorkerThread::PRIORITY_NORMAL | mWorkPriority;
18231830
mDecoded = FALSE;
1831+
setPriority(LLWorkerThread::PRIORITY_LOW | mWorkPriority);
18241832
setState(DECODE_IMAGE_UPDATE);
18251833
LL_DEBUGS(LOG_TXT) << mID << ": Decoding. Bytes: " << mFormattedImage->getDataSize() << " Discard: " << discard
18261834
<< " All Data: " << mHaveAllData << LL_ENDL;

0 commit comments

Comments
 (0)