diff options
author | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2012-05-03 17:25:40 -0400 |
---|---|---|
committer | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2012-05-03 17:25:40 -0400 |
commit | 32c024c41d8edb2bbf5441178d83f3365182ed61 (patch) | |
tree | 8c0ad45af0e645584807f98eef6942f83c4f0698 /indra/newview/llviewertexturelist.cpp | |
parent | 30140f66be90b78006b29b7f3740ddc473a0ac96 (diff) | |
parent | c143a4f87ee465c797a0fcf06e267bd32b9e52c7 (diff) |
merge
Diffstat (limited to 'indra/newview/llviewertexturelist.cpp')
-rw-r--r-- | indra/newview/llviewertexturelist.cpp | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/indra/newview/llviewertexturelist.cpp b/indra/newview/llviewertexturelist.cpp index 2008a884db..e3b633dc0e 100644 --- a/indra/newview/llviewertexturelist.cpp +++ b/indra/newview/llviewertexturelist.cpp @@ -701,6 +701,11 @@ void LLViewerTextureList::updateImagesDecodePriorities() LLPointer<LLViewerFetchedTexture> imagep = iter->second; ++iter; // safe to incrament now + if(imagep->isInDebug()) + { + continue; //is in debug, ignore. + } + // // Flush formatted images using a lazy flush // @@ -773,6 +778,27 @@ void LLViewerTextureList::updateImagesDecodePriorities() } } +void LLViewerTextureList::setDebugFetching(LLViewerFetchedTexture* tex, S32 debug_level) +{ + if(!tex->setDebugFetching(debug_level)) + { + return; + } + + const F32 DEBUG_PRIORITY = 100000.f; + F32 old_priority_test = llmax(tex->getDecodePriority(), 0.0f); + F32 decode_priority_test = DEBUG_PRIORITY; + + // Ignore < 20% difference + if ((decode_priority_test < old_priority_test * .8f) || + (decode_priority_test > old_priority_test * 1.25f)) + { + removeImageFromList(tex); + tex->setDecodePriority(decode_priority_test); + addImageToList(tex); + } +} + /* static U8 get_image_type(LLViewerFetchedTexture* imagep, LLHost target_host) { |