diff options
author | mobserveur <mobserveur@gmail.com> | 2025-08-30 01:59:43 +0200 |
---|---|---|
committer | mobserveur <mobserveur@gmail.com> | 2025-08-30 01:59:43 +0200 |
commit | 7f0c81918575d3f05e4eadc160b600eaa8b383d1 (patch) | |
tree | 4c6bb40e93e38bb8a32964380f97ac2a06490b11 /indra/newview/llstatusbar.cpp | |
parent | 03140ed619c5d49eb3851284ae53bbea73a8b831 (diff) |
Performance Optimisations, Bloom effect, Visuals Panel
This commit contains performance optimisations in the the pipeline,
framebuffer, vertexbuffer, reflection probes, shadows. It also fixes
many opengl errors, modifies the opengl debugging, and adds
a visuals effects panel.
Diffstat (limited to 'indra/newview/llstatusbar.cpp')
-rw-r--r-- | indra/newview/llstatusbar.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/indra/newview/llstatusbar.cpp b/indra/newview/llstatusbar.cpp index bda75c16e7..7d397cddcc 100644 --- a/indra/newview/llstatusbar.cpp +++ b/indra/newview/llstatusbar.cpp @@ -307,9 +307,21 @@ void LLStatusBar::refresh() mFpsUpdateTimer->reset(); S32 fps = (S32) llround(LLTrace::get_frame_recording().getPeriodMedianPerSec(LLStatViewer::FPS, 50)); + if(fps < 1) fps = 1; + + S32 minFps = (S32) llround(LLTrace::get_frame_recording().getPeriodMinPerSec(LLStatViewer::FPS, 50)); + S32 maxFps = (S32) llround(LLTrace::get_frame_recording().getPeriodMaxPerSec(LLStatViewer::FPS, 50)); + + F32 fpsQuality = (F32)minFps / (F32)fps; + std::string fpsStr = std::to_string(fps); - //mTextFps->setText(fpsStr); + mTextFps->setLabel(fpsStr); + + if(fpsQuality < 0.5) mTextFps->setColor(LLColor4(0.6,0.0,0.0)); + else if(fpsQuality < 0.7) mTextFps->setColor(LLColor4(0.7,0.5,0.0)); + else if(fpsQuality < 0.9) mTextFps->setColor(LLColor4(0.5,0.7,0.0)); + else mTextFps->setColor(LLColor4(0.0, 0.7, 0.15)); } // update clock every 10 seconds |