From 6197390760eba8ca1123d03637cbb9af0414c5f7 Mon Sep 17 00:00:00 2001 From: a1xd <68629610+a1xd@users.noreply.github.com> Date: Thu, 8 Apr 2021 12:45:43 -0400 Subject: fix conversions in arbitrary constructor --- common/accel-lookup.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'common') diff --git a/common/accel-lookup.hpp b/common/accel-lookup.hpp index 24b61e5..ff89fa7 100644 --- a/common/accel-lookup.hpp +++ b/common/accel-lookup.hpp @@ -262,9 +262,9 @@ namespace rawaccel { last_arbitrary_index = length - 2; last_point_speed = points[last_arbitrary_index].x; - double start = (int)floor(log(first_point_speed)); - double end = (int)floor(log(last_point_speed)); - double num = (int)floor(LUT_CAPACITY / (end - start)); + int start = static_cast(log(first_point_speed)); + int end = static_cast(log(last_point_speed)); + int num = static_cast(LUT_CAPACITY / (end - start)); range = fp_rep_range{ start, end, num }; last_log_lookup_index = num * (end - start) - 1; -- cgit v1.2.3