summaryrefslogtreecommitdiff
path: root/src/hid_core/resource_manager.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/hid_core/resource_manager.h')
-rw-r--r--src/hid_core/resource_manager.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/hid_core/resource_manager.h b/src/hid_core/resource_manager.h
index 7a21d8eb8..128e00125 100644
--- a/src/hid_core/resource_manager.h
+++ b/src/hid_core/resource_manager.h
@@ -10,6 +10,12 @@ namespace Core {
10class System; 10class System;
11} 11}
12 12
13namespace Core::HID {
14struct VibrationDeviceHandle;
15struct VibrationValue;
16struct VibrationDeviceInfo;
17} // namespace Core::HID
18
13namespace Core::Timing { 19namespace Core::Timing {
14struct EventType; 20struct EventType;
15} 21}
@@ -37,6 +43,11 @@ class SixAxis;
37class SleepButton; 43class SleepButton;
38class TouchScreen; 44class TouchScreen;
39class UniquePad; 45class UniquePad;
46class NpadVibrationBase;
47class NpadN64VibrationDevice;
48class NpadGcVibrationDevice;
49class NpadVibrationDevice;
50struct HandheldConfig;
40 51
41class ResourceManager { 52class ResourceManager {
42 53
@@ -79,6 +90,18 @@ public:
79 void EnablePadInput(u64 aruid, bool is_enabled); 90 void EnablePadInput(u64 aruid, bool is_enabled);
80 void EnableTouchScreen(u64 aruid, bool is_enabled); 91 void EnableTouchScreen(u64 aruid, bool is_enabled);
81 92
93 NpadVibrationBase* GetVibrationDevice(const Core::HID::VibrationDeviceHandle& handle);
94 NpadN64VibrationDevice* GetN64VibrationDevice(const Core::HID::VibrationDeviceHandle& handle);
95 NpadVibrationDevice* GetNSVibrationDevice(const Core::HID::VibrationDeviceHandle& handle);
96 NpadGcVibrationDevice* GetGcVibrationDevice(const Core::HID::VibrationDeviceHandle& handle);
97 Result SetAruidValidForVibration(u64 aruid, bool is_enabled);
98 void SetForceHandheldStyleVibration(bool is_forced);
99 Result IsVibrationAruidActive(u64 aruid, bool& is_active) const;
100 Result GetVibrationDeviceInfo(Core::HID::VibrationDeviceInfo& device_info,
101 const Core::HID::VibrationDeviceHandle& handle);
102 Result SendVibrationValue(u64 aruid, const Core::HID::VibrationDeviceHandle& handle,
103 const Core::HID::VibrationValue& value);
104
82 void UpdateControllers(std::chrono::nanoseconds ns_late); 105 void UpdateControllers(std::chrono::nanoseconds ns_late);
83 void UpdateNpad(std::chrono::nanoseconds ns_late); 106 void UpdateNpad(std::chrono::nanoseconds ns_late);
84 void UpdateMouseKeyboard(std::chrono::nanoseconds ns_late); 107 void UpdateMouseKeyboard(std::chrono::nanoseconds ns_late);
@@ -113,6 +136,8 @@ private:
113 std::shared_ptr<TouchScreen> touch_screen = nullptr; 136 std::shared_ptr<TouchScreen> touch_screen = nullptr;
114 std::shared_ptr<UniquePad> unique_pad = nullptr; 137 std::shared_ptr<UniquePad> unique_pad = nullptr;
115 138
139 std::shared_ptr<HandheldConfig> handheld_config = nullptr;
140
116 // TODO: Create these resources 141 // TODO: Create these resources
117 // std::shared_ptr<AudioControl> audio_control = nullptr; 142 // std::shared_ptr<AudioControl> audio_control = nullptr;
118 // std::shared_ptr<ButtonConfig> button_config = nullptr; 143 // std::shared_ptr<ButtonConfig> button_config = nullptr;