diff options
| author | Léo Lam <leo@innovatetechnologi.es> | 2019-05-05 10:24:18 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-05-05 10:24:18 +0200 |
| commit | 5d52b6ff095a4f8285ae757745ab0285bad47b9e (patch) | |
| tree | ac4904dfb02322a55dd7e5a2d7cdedf756f8eaf6 /Source/Core/InputCommon/ControllerEmu/StickGate.cpp | |
| parent | 99a4ca8de7111c8554b50217744e24bc71912cfe (diff) | |
| parent | 9133e8f1befbebd87c6e61f0e454f3ae2754285a (diff) | |
Merge pull request #6273 from leoetlino/c++17
Enable C++17
Diffstat (limited to 'Source/Core/InputCommon/ControllerEmu/StickGate.cpp')
| -rw-r--r-- | Source/Core/InputCommon/ControllerEmu/StickGate.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/Core/InputCommon/ControllerEmu/StickGate.cpp b/Source/Core/InputCommon/ControllerEmu/StickGate.cpp index 48c21ae5be..70ed383398 100644 --- a/Source/Core/InputCommon/ControllerEmu/StickGate.cpp +++ b/Source/Core/InputCommon/ControllerEmu/StickGate.cpp @@ -4,6 +4,7 @@ #include "InputCommon/ControllerEmu/StickGate.h" +#include <algorithm> #include <cmath> #include "Common/Common.h" @@ -277,8 +278,8 @@ ReshapableInput::ReshapeData ReshapableInput::Reshape(ControlState x, ControlSta // Scale to the gate shape/radius: dist *= gate_max_dist; - return {MathUtil::Clamp(std::cos(angle) * dist, -1.0, 1.0), - MathUtil::Clamp(std::sin(angle) * dist, -1.0, 1.0)}; + return {std::clamp(std::cos(angle) * dist, -1.0, 1.0), + std::clamp(std::sin(angle) * dist, -1.0, 1.0)}; } } // namespace ControllerEmu |
