aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llviewerimage.cpp
diff options
context:
space:
mode:
authorJacek Antonelli2008-08-15 23:45:19 -0500
committerJacek Antonelli2008-08-15 23:45:19 -0500
commitb235c59d60472f818a9142c0886b95a0ff4191d7 (patch)
treed323c55587584b19cc43a03f58a178823f12d3cd /linden/indra/newview/llviewerimage.cpp
parentSecond Life viewer sources 1.18.5.3 (diff)
downloadmeta-impy-b235c59d60472f818a9142c0886b95a0ff4191d7.zip
meta-impy-b235c59d60472f818a9142c0886b95a0ff4191d7.tar.gz
meta-impy-b235c59d60472f818a9142c0886b95a0ff4191d7.tar.bz2
meta-impy-b235c59d60472f818a9142c0886b95a0ff4191d7.tar.xz
Second Life viewer sources 1.18.6.0-RC
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/llviewerimage.cpp27
1 files changed, 13 insertions, 14 deletions
diff --git a/linden/indra/newview/llviewerimage.cpp b/linden/indra/newview/llviewerimage.cpp
index 240ffa5..d67bec1 100644
--- a/linden/indra/newview/llviewerimage.cpp
+++ b/linden/indra/newview/llviewerimage.cpp
@@ -57,8 +57,7 @@
57#include "llviewerimagelist.h" 57#include "llviewerimagelist.h"
58#include "llviewercontrol.h" 58#include "llviewercontrol.h"
59#include "pipeline.h" 59#include "pipeline.h"
60#include "viewer.h" 60#include "llappviewer.h"
61
62/////////////////////////////////////////////////////////////////////////////// 61///////////////////////////////////////////////////////////////////////////////
63 62
64// statics 63// statics
@@ -294,7 +293,7 @@ LLViewerImage::~LLViewerImage()
294{ 293{
295 if (mHasFetcher) 294 if (mHasFetcher)
296 { 295 {
297 gTextureFetch->deleteRequest(getID(), true); 296 LLAppViewer::getTextureFetch()->deleteRequest(getID(), true);
298 } 297 }
299 // Explicitly call LLViewerImage::cleanup since we're in a destructor and cleanup is virtual 298 // Explicitly call LLViewerImage::cleanup since we're in a destructor and cleanup is virtual
300 LLViewerImage::cleanup(); 299 LLViewerImage::cleanup();
@@ -557,9 +556,9 @@ void LLViewerImage::processTextureStats()
557F32 LLViewerImage::calcDecodePriority() 556F32 LLViewerImage::calcDecodePriority()
558{ 557{
559#ifndef LL_RELEASE_FOR_DOWNLOAD 558#ifndef LL_RELEASE_FOR_DOWNLOAD
560 if (mID == gTextureFetch->mDebugID) 559 if (mID == LLAppViewer::getTextureFetch()->mDebugID)
561 { 560 {
562 gTextureFetch->mDebugCount++; // for setting breakpoints 561 LLAppViewer::getTextureFetch()->mDebugCount++; // for setting breakpoints
563 } 562 }
564#endif 563#endif
565 564
@@ -695,9 +694,9 @@ bool LLViewerImage::updateFetch()
695 mRequestDeltaTime = 999999.f; 694 mRequestDeltaTime = 999999.f;
696 695
697#ifndef LL_RELEASE_FOR_DOWNLOAD 696#ifndef LL_RELEASE_FOR_DOWNLOAD
698 if (mID == gTextureFetch->mDebugID) 697 if (mID == LLAppViewer::getTextureFetch()->mDebugID)
699 { 698 {
700 gTextureFetch->mDebugCount++; // for setting breakpoints 699 LLAppViewer::getTextureFetch()->mDebugCount++; // for setting breakpoints
701 } 700 }
702#endif 701#endif
703 702
@@ -735,14 +734,14 @@ bool LLViewerImage::updateFetch()
735 { 734 {
736 // Sets mRawDiscardLevel, mRawImage, mAuxRawImage 735 // Sets mRawDiscardLevel, mRawImage, mAuxRawImage
737 S32 fetch_discard = current_discard; 736 S32 fetch_discard = current_discard;
738 bool finished = gTextureFetch->getRequestFinished(getID(), fetch_discard, mRawImage, mAuxRawImage); 737 bool finished = LLAppViewer::getTextureFetch()->getRequestFinished(getID(), fetch_discard, mRawImage, mAuxRawImage);
739 if (finished) 738 if (finished)
740 { 739 {
741 mIsFetching = FALSE; 740 mIsFetching = FALSE;
742 } 741 }
743 else 742 else
744 { 743 {
745 mFetchState = gTextureFetch->getFetchState(mID, mDownloadProgress, mRequestedDownloadPriority, 744 mFetchState = LLAppViewer::getTextureFetch()->getFetchState(mID, mDownloadProgress, mRequestedDownloadPriority,
746 mFetchPriority, mFetchDeltaTime, mRequestDeltaTime); 745 mFetchPriority, mFetchDeltaTime, mRequestDeltaTime);
747 } 746 }
748 747
@@ -803,7 +802,7 @@ bool LLViewerImage::updateFetch()
803 } 802 }
804 else if (mDecodePriority >= 0.f) 803 else if (mDecodePriority >= 0.f)
805 { 804 {
806 gTextureFetch->updateRequestPriority(mID, mDecodePriority); 805 LLAppViewer::getTextureFetch()->updateRequestPriority(mID, mDecodePriority);
807 } 806 }
808 } 807 }
809 808
@@ -859,14 +858,14 @@ bool LLViewerImage::updateFetch()
859 desired_discard = llmax(desired_discard, current_discard-2); 858 desired_discard = llmax(desired_discard, current_discard-2);
860 } 859 }
861 } 860 }
862 if (gTextureFetch->createRequest(getID(),getTargetHost(), decode_priority, 861 if (LLAppViewer::getTextureFetch()->createRequest(getID(),getTargetHost(), decode_priority,
863 w, h, c, desired_discard, 862 w, h, c, desired_discard,
864 needsAux())) 863 needsAux()))
865 { 864 {
866 mHasFetcher = TRUE; 865 mHasFetcher = TRUE;
867 mIsFetching = TRUE; 866 mIsFetching = TRUE;
868 mRequestedDiscardLevel = desired_discard; 867 mRequestedDiscardLevel = desired_discard;
869 mFetchState = gTextureFetch->getFetchState(mID, mDownloadProgress, mRequestedDownloadPriority, 868 mFetchState = LLAppViewer::getTextureFetch()->getFetchState(mID, mDownloadProgress, mRequestedDownloadPriority,
870 mFetchPriority, mFetchDeltaTime, mRequestDeltaTime); 869 mFetchPriority, mFetchDeltaTime, mRequestDeltaTime);
871 } 870 }
872 // if createRequest() failed, we're finishing up a request for this UUID, 871 // if createRequest() failed, we're finishing up a request for this UUID,
@@ -879,7 +878,7 @@ bool LLViewerImage::updateFetch()
879 if (mLastPacketTimer.getElapsedTimeF32() > FETCH_IDLE_TIME) 878 if (mLastPacketTimer.getElapsedTimeF32() > FETCH_IDLE_TIME)
880 { 879 {
881// llinfos << "Deleting request: " << getID() << " Discard: " << current_discard << " <= min:" << mMinDiscardLevel << " or priority == 0: " << decode_priority << llendl; 880// llinfos << "Deleting request: " << getID() << " Discard: " << current_discard << " <= min:" << mMinDiscardLevel << " or priority == 0: " << decode_priority << llendl;
882 gTextureFetch->deleteRequest(getID(), true); 881 LLAppViewer::getTextureFetch()->deleteRequest(getID(), true);
883 mHasFetcher = FALSE; 882 mHasFetcher = FALSE;
884 } 883 }
885 } 884 }
@@ -893,7 +892,7 @@ void LLViewerImage::setIsMissingAsset()
893{ 892{
894 if (mHasFetcher) 893 if (mHasFetcher)
895 { 894 {
896 gTextureFetch->deleteRequest(getID(), true); 895 LLAppViewer::getTextureFetch()->deleteRequest(getID(), true);
897 mHasFetcher = FALSE; 896 mHasFetcher = FALSE;
898 mIsFetching = FALSE; 897 mIsFetching = FALSE;
899 mFetchState = 0; 898 mFetchState = 0;