diff options
author | german <german@thesoftwareartisans.com> | 2021-01-24 17:27:04 +0100 |
---|---|---|
committer | german <german@thesoftwareartisans.com> | 2021-01-24 18:28:52 +0100 |
commit | a8245cf2f1f3abb73833baa574b047eaa28d39ca (patch) | |
tree | a078c66b13cfbf9e9d6cde3942b2afac19e80e27 /src/core/hle/service/hid/controllers/npad.cpp | |
parent | Merge pull request #5808 from ReinUsesLisp/glslang-quiet (diff) | |
download | yuzu-a8245cf2f1f3abb73833baa574b047eaa28d39ca.tar yuzu-a8245cf2f1f3abb73833baa574b047eaa28d39ca.tar.gz yuzu-a8245cf2f1f3abb73833baa574b047eaa28d39ca.tar.bz2 yuzu-a8245cf2f1f3abb73833baa574b047eaa28d39ca.tar.lz yuzu-a8245cf2f1f3abb73833baa574b047eaa28d39ca.tar.xz yuzu-a8245cf2f1f3abb73833baa574b047eaa28d39ca.tar.zst yuzu-a8245cf2f1f3abb73833baa574b047eaa28d39ca.zip |
Diffstat (limited to 'src/core/hle/service/hid/controllers/npad.cpp')
-rw-r--r-- | src/core/hle/service/hid/controllers/npad.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/core/hle/service/hid/controllers/npad.cpp b/src/core/hle/service/hid/controllers/npad.cpp index ff783b3cc..265c986e2 100644 --- a/src/core/hle/service/hid/controllers/npad.cpp +++ b/src/core/hle/service/hid/controllers/npad.cpp @@ -946,6 +946,24 @@ void Controller_NPad::SetSixAxisEnabled(bool six_axis_status) { sixaxis_sensors_enabled = six_axis_status; } +void Controller_NPad::SetSixAxisFusionParameters(const DeviceHandle& handle, f32 parameter1, + f32 parameter2) { + sixaxis_fusion_parameter1 = parameter1; + sixaxis_fusion_parameter2 = parameter2; +} + +std::pair<f32, f32> Controller_NPad::GetSixAxisFusionParameters(const DeviceHandle& handle) { + return { + sixaxis_fusion_parameter1, + sixaxis_fusion_parameter2, + }; +} + +void Controller_NPad::ResetSixAxisFusionParameters(const DeviceHandle& handle) { + sixaxis_fusion_parameter1 = 0.0f; + sixaxis_fusion_parameter2 = 0.0f; +} + void Controller_NPad::MergeSingleJoyAsDualJoy(u32 npad_id_1, u32 npad_id_2) { const auto npad_index_1 = NPadIdToIndex(npad_id_1); const auto npad_index_2 = NPadIdToIndex(npad_id_2); |