diff options
author | dec05eba <dec05eba@protonmail.com> | 2024-06-23 01:39:07 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2024-06-23 01:39:07 +0200 |
commit | d2e1606f574945f29fe25b221a78c4b55270d338 (patch) | |
tree | 94c1ea210601f4225ab5552cdd6b4d0463eccb9f /src/main.cpp | |
parent | 4c88f8f379db35cbae15f709f14463419731f6e5 (diff) |
Minor reorder
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/main.cpp b/src/main.cpp index 8bfe021..bd4be62 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -2679,6 +2679,11 @@ int main(int argc, char **argv) { } } + const bool damaged = !capture->is_damaged || capture->is_damaged(capture); + if(damaged) { + ++damage_fps_counter; + } + ++fps_counter; double time_now = clock_get_monotonic_seconds(); double frame_timer_elapsed = time_now - frame_timer_start; @@ -2692,11 +2697,6 @@ int main(int argc, char **argv) { damage_fps_counter = 0; } - const bool damaged = !capture->is_damaged || capture->is_damaged(capture); - if(damaged) { - ++damage_fps_counter; - } - double frame_time_overflow = frame_timer_elapsed - target_fps; if (frame_time_overflow >= 0.0 && damaged) { if(capture->clear_damage) |