From c69de61bf3873e5de4bb035ee965881a99789142 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Sat, 23 Mar 2024 05:58:29 +0100 Subject: src/object: use forward declaration for dt --- src/object.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/object.cpp') diff --git a/src/object.cpp b/src/object.cpp index 7f0b9afb..4339e055 100644 --- a/src/object.cpp +++ b/src/object.cpp @@ -290,7 +290,7 @@ bool object::move_to(Magnum::Vector2i delta) } template requires std::is_unsigned_v -uint32_t object::alloc_frame_time(Ns dt, T& accum, uint32_t hz, float speed) +uint32_t object::alloc_frame_time(const Ns& dt, T& accum, uint32_t hz, float speed) { constexpr auto ns_in_sec = Ns((int)1e9); constexpr auto accum_max = uint64_t{limits::max}; @@ -320,8 +320,8 @@ uint32_t object::alloc_frame_time(Ns dt, T& accum, uint32_t hz, float speed) return nframes; } -template uint32_t object::alloc_frame_time(Ns dt, uint16_t& accum, uint32_t hz, float speed); -template uint32_t object::alloc_frame_time(Ns dt, uint32_t& accum, uint32_t hz, float speed); +template uint32_t object::alloc_frame_time(const Ns& dt, uint16_t& accum, uint32_t hz, float speed); +template uint32_t object::alloc_frame_time(const Ns& dt, uint32_t& accum, uint32_t hz, float speed); void object::set_bbox_(Vector2b offset_, Vector2b bb_offset_, Vector2ub bb_size_, pass_mode pass_) { -- cgit v1.2.3