summaryrefslogtreecommitdiff
path: root/indra/newview/llscenemonitor.cpp
diff options
context:
space:
mode:
authorRichard Linden <none@none>2013-05-13 11:04:10 -0700
committerRichard Linden <none@none>2013-05-13 11:04:10 -0700
commit405aa5b1ba7b786da05136fc9cc1f0a664111ce8 (patch)
tree5e9481c93ed5b0a911e8f16c26faaec703b33c42 /indra/newview/llscenemonitor.cpp
parentedf731c180a61dc49255ebb25342b6256e8d6065 (diff)
SH-3931 WIP Interesting: Add graphs to visualize scene load metrics
added log output for scene monitoring
Diffstat (limited to 'indra/newview/llscenemonitor.cpp')
-rw-r--r--indra/newview/llscenemonitor.cpp14
1 files changed, 4 insertions, 10 deletions
diff --git a/indra/newview/llscenemonitor.cpp b/indra/newview/llscenemonitor.cpp
index 2e819c8efe..9546c786d1 100644
--- a/indra/newview/llscenemonitor.cpp
+++ b/indra/newview/llscenemonitor.cpp
@@ -50,7 +50,7 @@ LLSceneMonitorView* gSceneMonitorView = NULL;
//2, (?) disable all sky and water;
//3, capture frames periodically, by calling "capture()";
//4, compute pixel differences between two latest captured frames, by calling "compare()", results are stored at mDiff;
-//5, compute the number of pixels in mDiff above some tolerance threshold in GPU, by calling "queryDiff() -> calcDiffAggregate()";
+//5, compute the number of pixels in mDiff above some tolerance threshold in GPU, by calling "calcDiffAggregate()";
//6, use gl occlusion query to fetch the result from GPU, by calling "fetchQueryResult()";
//END.
//
@@ -402,17 +402,10 @@ void LLSceneMonitor::compare()
mHasNewDiff = true;
- queryDiff();
-}
-
-void LLSceneMonitor::queryDiff()
-{
- if(mDebugViewerVisible)
+ if (!mDebugViewerVisible)
{
- return;
+ calcDiffAggregate();
}
-
- calcDiffAggregate();
}
//calculate Diff aggregate information in GPU, and enable gl occlusion query to capture it.
@@ -492,6 +485,7 @@ void LLSceneMonitor::fetchQueryResult()
mDiffResult = count * 0.5f / (mDiff->getWidth() * mDiff->getHeight() * mDiffPixelRatio * mDiffPixelRatio); //0.5 -> (front face + back face)
+ LL_DEBUGS("SceneMonitor") << "Frame difference: " << mDiffResult << LL_ENDL;
sample(sFramePixelDiff, mDiffResult);
const F32 diff_threshold = 0.001f;