diff options
| author | Jordan Woyak <jordan.woyak@gmail.com> | 2020-02-24 16:55:44 -0600 |
|---|---|---|
| committer | Jordan Woyak <jordan.woyak@gmail.com> | 2020-02-25 17:19:48 -0600 |
| commit | f8cca9fe5dc93b051fbb63247edad99533f19bfc (patch) | |
| tree | 7189dc644635cc7d6d31e8791828b3069c8ac5ca /Source/Core/InputCommon/ControllerEmu/StickGate.cpp | |
| parent | 459b47295dd0af91c24d921b4c8f1e17958e8c68 (diff) | |
InputCommon: RoundStickGate's ideal sample count can be 1.
Diffstat (limited to 'Source/Core/InputCommon/ControllerEmu/StickGate.cpp')
| -rw-r--r-- | Source/Core/InputCommon/ControllerEmu/StickGate.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Source/Core/InputCommon/ControllerEmu/StickGate.cpp b/Source/Core/InputCommon/ControllerEmu/StickGate.cpp index 0b16103773..3346b874a2 100644 --- a/Source/Core/InputCommon/ControllerEmu/StickGate.cpp +++ b/Source/Core/InputCommon/ControllerEmu/StickGate.cpp @@ -54,7 +54,7 @@ constexpr int ReshapableInput::CALIBRATION_SAMPLE_COUNT; std::optional<u32> StickGate::GetIdealCalibrationSampleCount() const { - return {}; + return std::nullopt; } OctagonStickGate::OctagonStickGate(ControlState radius) : m_radius(radius) @@ -86,6 +86,12 @@ ControlState RoundStickGate::GetRadiusAtAngle(double) const return m_radius; } +std::optional<u32> RoundStickGate::GetIdealCalibrationSampleCount() const +{ + // The "radius" is the same at every angle so a single sample is enough. + return 1; +} + SquareStickGate::SquareStickGate(ControlState half_width) : m_half_width(half_width) { } |
