From 9e0e31132a2ae11675af9762bcabff4dd0010c9f Mon Sep 17 00:00:00 2001 From: lizzie Date: Wed, 30 Jul 2025 20:59:28 +0200 Subject: [icc] fix intel c++ compiler errors (#146) Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/146 Co-authored-by: lizzie Co-committed-by: lizzie --- src/input_common/drivers/sdl_driver.cpp | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'src/input_common/drivers/sdl_driver.cpp') diff --git a/src/input_common/drivers/sdl_driver.cpp b/src/input_common/drivers/sdl_driver.cpp index ef898527ec..51169c6f2b 100644 --- a/src/input_common/drivers/sdl_driver.cpp +++ b/src/input_common/drivers/sdl_driver.cpp @@ -1,3 +1,5 @@ +// SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project +// SPDX-License-Identifier: GPL-3.0-or-later // SPDX-FileCopyrightText: 2018 Citra Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later @@ -110,12 +112,12 @@ public: bool RumblePlay(const Common::Input::VibrationStatus vibration) { constexpr u32 rumble_max_duration_ms = 2000; - constexpr f32 low_start_sensitivity_limit = 140.0; - constexpr f32 low_width_sensitivity_limit = 400.0; - constexpr f32 high_start_sensitivity_limit = 200.0; - constexpr f32 high_width_sensitivity_limit = 700.0; + constexpr f32 low_start_sensitivity_limit = 140.0f; + constexpr f32 low_width_sensitivity_limit = 400.0f; + constexpr f32 high_start_sensitivity_limit = 200.0f; + constexpr f32 high_width_sensitivity_limit = 700.0f; // Try to provide some feeling of the frequency by reducing the amplitude depending on it. - f32 low_frequency_scale = 1.0; + f32 low_frequency_scale = 1.0f; if (vibration.low_frequency > low_start_sensitivity_limit) { low_frequency_scale = std::max(1.0f - (vibration.low_frequency - low_start_sensitivity_limit) / @@ -124,7 +126,7 @@ public: } f32 low_amplitude = vibration.low_amplitude * low_frequency_scale; - f32 high_frequency_scale = 1.0; + f32 high_frequency_scale = 1.0f; if (vibration.high_frequency > high_start_sensitivity_limit) { high_frequency_scale = std::max(1.0f - (vibration.high_frequency - high_start_sensitivity_limit) / -- cgit v1.2.3