From f7b4866811c63ae24c366d9452e53d24e504336f Mon Sep 17 00:00:00 2001 From: WBoerenkamps Date: Thu, 12 Dec 2024 19:47:59 +0100 Subject: fps fix + regression test --- src/crepe/manager/LoopTimerManager.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/crepe/manager/LoopTimerManager.cpp') diff --git a/src/crepe/manager/LoopTimerManager.cpp b/src/crepe/manager/LoopTimerManager.cpp index 9819632..9d24c2b 100644 --- a/src/crepe/manager/LoopTimerManager.cpp +++ b/src/crepe/manager/LoopTimerManager.cpp @@ -1,6 +1,5 @@ #include #include - #include "../util/Log.h" #include "LoopTimerManager.h" @@ -31,7 +30,7 @@ void LoopTimerManager::update() { this->delta_time = this->maximum_delta_time; } if (this->delta_time > 0s) { - this->actual_fps = 1.0 / duration_cast(this->delta_time).count(); + this->actual_fps = static_cast(1.0 / this->delta_time.count()); } else { this->actual_fps = 0; } -- cgit v1.2.3