diff options
author | Lioncash <mathew1800@gmail.com> | 2020-10-14 08:51:14 +0200 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2020-10-16 01:37:51 +0200 |
commit | 046c0c91a3ed665531f20955e7cfb86fe5b73213 (patch) | |
tree | 94382af9cc339cf5f384f4d0c8938dd593b4e1c5 /src/input_common/gcadapter/gc_adapter.h | |
parent | Merge pull request #4787 from lioncash/conversion (diff) | |
download | yuzu-046c0c91a3ed665531f20955e7cfb86fe5b73213.tar yuzu-046c0c91a3ed665531f20955e7cfb86fe5b73213.tar.gz yuzu-046c0c91a3ed665531f20955e7cfb86fe5b73213.tar.bz2 yuzu-046c0c91a3ed665531f20955e7cfb86fe5b73213.tar.lz yuzu-046c0c91a3ed665531f20955e7cfb86fe5b73213.tar.xz yuzu-046c0c91a3ed665531f20955e7cfb86fe5b73213.tar.zst yuzu-046c0c91a3ed665531f20955e7cfb86fe5b73213.zip |
Diffstat (limited to '')
-rw-r--r-- | src/input_common/gcadapter/gc_adapter.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/input_common/gcadapter/gc_adapter.h b/src/input_common/gcadapter/gc_adapter.h index 75bf9fe74..4f5f3de8e 100644 --- a/src/input_common/gcadapter/gc_adapter.h +++ b/src/input_common/gcadapter/gc_adapter.h @@ -60,7 +60,7 @@ struct GCPadStatus { struct GCState { std::unordered_map<int, bool> buttons; - std::unordered_map<int, u16> axes; + std::unordered_map<u32, u16> axes; }; enum class ControllerTypes { None, Wired, Wireless }; @@ -89,13 +89,11 @@ public: std::array<GCState, 4>& GetPadState(); const std::array<GCState, 4>& GetPadState() const; - int GetOriginValue(int port, int axis) const; + int GetOriginValue(u32 port, u32 axis) const; private: GCPadStatus GetPadStatus(std::size_t port, const std::array<u8, 37>& adapter_payload); - void PadToState(const GCPadStatus& pad, GCState& state); - void Read(); /// Resets status of device connected to port |