From 202f16cdf81fe590a7b40334016a7374e0bbdad7 Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Mon, 19 Apr 2010 16:35:38 -0600 Subject: trival: remove some redundant code from llviewertexture.cpp. --- indra/newview/llviewertexture.cpp | 4 ---- 1 file changed, 4 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp index a5adb11c53..c883087cf2 100644 --- a/indra/newview/llviewertexture.cpp +++ b/indra/newview/llviewertexture.cpp @@ -1564,10 +1564,6 @@ F32 LLViewerFetchedTexture::calcDecodePriority() // larger mips are corrupted priority = -3.0f; } - else if (cur_discard <= mDesiredDiscardLevel) - { - priority = -4.0f; - } else { // priority range = 100,000 - 500,000 -- cgit v1.2.3 From 21dc4949feb0b0436471c409ddca809208a12852 Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Thu, 22 Apr 2010 11:32:07 -0600 Subject: fix for EXT-6928: Viewer crashes immediately after enabling HTTP Textures on a http-texture-server-1 simulator and EXT-7009: textures fetched through http are never cached. --- indra/newview/lltexturefetch.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'indra/newview') diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp index 2ea6e5936d..aea94fd720 100644 --- a/indra/newview/lltexturefetch.cpp +++ b/indra/newview/lltexturefetch.cpp @@ -850,6 +850,7 @@ bool LLTextureFetchWorker::doWork(S32 param) mState = WAIT_HTTP_REQ; mFetcher->addToHTTPQueue(mID); + mSentRequest = QUEUED; // Will call callbackHttpGet when curl request completes std::vector headers; headers.push_back("Accept: image/x-j2c"); @@ -936,6 +937,11 @@ bool LLTextureFetchWorker::doWork(S32 param) { mFileSize = mBufferSize; } + else //the file size is unknown + { + mFileSize = mBufferSize + 1 ; //flag the file is not fully loaded. + } + U8* buffer = new U8[mBufferSize]; if (cur_size > 0) { -- cgit v1.2.3 From 0b03cde790d54b5ebc41ee5dafa999eedde91a90 Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Thu, 22 Apr 2010 13:21:40 -0600 Subject: revert -r d7a43c972af0: fix for EXT-6928: Viewer crashes immediately after enabling HTTP Textures on a http-texture-server-1 simulator and EXT-7009: textures fetched through http are never cached. This will be checked into viewer-trunk. --- indra/newview/lltexturefetch.cpp | 6 ------ 1 file changed, 6 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp index aea94fd720..2ea6e5936d 100644 --- a/indra/newview/lltexturefetch.cpp +++ b/indra/newview/lltexturefetch.cpp @@ -850,7 +850,6 @@ bool LLTextureFetchWorker::doWork(S32 param) mState = WAIT_HTTP_REQ; mFetcher->addToHTTPQueue(mID); - mSentRequest = QUEUED; // Will call callbackHttpGet when curl request completes std::vector headers; headers.push_back("Accept: image/x-j2c"); @@ -937,11 +936,6 @@ bool LLTextureFetchWorker::doWork(S32 param) { mFileSize = mBufferSize; } - else //the file size is unknown - { - mFileSize = mBufferSize + 1 ; //flag the file is not fully loaded. - } - U8* buffer = new U8[mBufferSize]; if (cur_size > 0) { -- cgit v1.2.3