1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 12:37:45 +00:00

LibSoftGPU: Configure stats overlay period

Problem:
- The statistics overlay period is hardcoded to 500 ms. This time is
  very short and can result in the values being very "jumpy".

Solution:
- Increasing this value can result in more steady values which is
  useful when trying to evaluate the performance impact of a change. A
  new config value is offered in `Config.h` to let the developer
  change to any value desired.
This commit is contained in:
Lenny Maiorani 2022-01-08 14:30:56 -07:00 committed by Ali Mohammad Pur
parent 3831e5fcff
commit 065525aba0
2 changed files with 2 additions and 1 deletions

View file

@ -1224,7 +1224,7 @@ void Device::draw_statistics_overlay(Gfx::Bitmap& target)
Gfx::Painter painter { target };
if (milliseconds > 500) {
if (milliseconds > MILLISECONDS_PER_STATISTICS_PERIOD) {
int num_rendertarget_pixels = m_render_target->width() * m_render_target->height();