diff options
author | Richard Linden <none@none> | 2013-07-08 00:55:17 -0700 |
---|---|---|
committer | Richard Linden <none@none> | 2013-07-08 00:55:17 -0700 |
commit | d122318bef2ff0eced7641dc24f411f792bd2935 (patch) | |
tree | 7c5bfc2c60058d6f87ad9c18c08f844424f3efc9 /indra/newview/lltexturefetch.cpp | |
parent | bc7d2b76961c0397dcd108e625db4304855f4539 (diff) |
SH-4299 WIP: Interesting: High fps shown temporarily off scale in statistics console
added percentage/ratio units
added auto-range and auto tick calculation to stat bar to automate display stats
Diffstat (limited to 'indra/newview/lltexturefetch.cpp')
-rwxr-xr-x | indra/newview/lltexturefetch.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp index 0390649a1c..6716391f41 100755 --- a/indra/newview/lltexturefetch.cpp +++ b/indra/newview/lltexturefetch.cpp @@ -64,9 +64,9 @@ #include "bufferarray.h" #include "bufferstream.h" -bool LLTextureFetchDebugger::sDebuggerEnabled = false ; -LLTrace::SampleStatHandle<> LLTextureFetch::sCacheHitRate("texture_cache_hits"); -LLTrace::SampleStatHandle<> LLTextureFetch::sCacheReadLatency("texture_cache_read_latency"); +bool LLTextureFetchDebugger::sDebuggerEnabled = false; +LLTrace::EventStatHandle<LLUnit<F32, LLUnits::Percent> > LLTextureFetch::sCacheHitRate("texture_cache_hits"); +LLTrace::EventStatHandle<LLUnit<F64, LLUnits::Milliseconds> > LLTextureFetch::sCacheReadLatency("texture_cache_read_latency"); ////////////////////////////////////////////////////////////////////////////// @@ -1251,7 +1251,7 @@ bool LLTextureFetchWorker::doWork(S32 param) LL_DEBUGS("Texture") << mID << ": Cached. Bytes: " << mFormattedImage->getDataSize() << " Size: " << llformat("%dx%d",mFormattedImage->getWidth(),mFormattedImage->getHeight()) << " Desired Discard: " << mDesiredDiscard << " Desired Size: " << mDesiredSize << LL_ENDL; - sample(LLTextureFetch::sCacheHitRate, 100.f); + record(LLTextureFetch::sCacheHitRate, LLUnits::Ratio::fromValue(1)); } else { @@ -1269,7 +1269,7 @@ bool LLTextureFetchWorker::doWork(S32 param) } // fall through - sample(LLTextureFetch::sCacheHitRate, 0.f); + record(LLTextureFetch::sCacheHitRate, LLUnits::Ratio::fromValue(0)); } } @@ -2762,10 +2762,10 @@ bool LLTextureFetch::getRequestFinished(const LLUUID& id, S32& discard_level, discard_level = worker->mDecodedDiscard; raw = worker->mRawImage; aux = worker->mAuxImage; - F32 cache_read_time = worker->mCacheReadTime; + LLUnit<F32, LLUnits::Seconds> cache_read_time = worker->mCacheReadTime; if (cache_read_time != 0.f) { - sample(sCacheReadLatency, cache_read_time * 1000.f); + record(sCacheReadLatency, cache_read_time); } res = true; LL_DEBUGS("Texture") << id << ": Request Finished. State: " << worker->mState << " Discard: " << discard_level << LL_ENDL; |