From 6dcb0817a2cd1a507dbf5e3c42bf13623b5b5cae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joshua=20Vanda=C3=ABle?= Date: Sun, 28 Jun 2026 08:33:40 +0200 Subject: MathUtil: C++20/23 modernisations I've also created DegreesToRadians/RadiansToDegrees utility functions since there was a lot of repeated code --- .../ControllerInterface/DualShockUDPClient/DualShockUDPClient.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Source/Core/InputCommon/ControllerInterface/DualShockUDPClient/DualShockUDPClient.cpp') diff --git a/Source/Core/InputCommon/ControllerInterface/DualShockUDPClient/DualShockUDPClient.cpp b/Source/Core/InputCommon/ControllerInterface/DualShockUDPClient/DualShockUDPClient.cpp index b22ace19f2..50c827d6d3 100644 --- a/Source/Core/InputCommon/ControllerInterface/DualShockUDPClient/DualShockUDPClient.cpp +++ b/Source/Core/InputCommon/ControllerInterface/DualShockUDPClient/DualShockUDPClient.cpp @@ -574,7 +574,7 @@ Device::Device(std::string name, int index, std::string server_address, u16 serv AddInput(new AccelerometerInput("Accel Backward", m_pad_data.accelerometer_z_g, -accel_scale)); // Convert degrees per second to radians per second - constexpr auto gyro_scale = 360.0 / MathUtil::TAU; + constexpr auto gyro_scale = MathUtil::RadiansToDegrees(1.0); AddInput(new GyroInput("Gyro Pitch Up", m_pad_data.gyro_pitch_deg_s, gyro_scale)); AddInput(new GyroInput("Gyro Pitch Down", m_pad_data.gyro_pitch_deg_s, -gyro_scale)); -- cgit v1.2.3