libultraship
Reimplementations of libultra (N64 SDK) functions for modern hardware
Loading...
Searching...
No Matches
GlobalSDLDeviceSettings.h
Go to the documentation of this file.
1#pragma once
2
3#include <cstdint>
4#include <memory>
5
6namespace Ship {
7class ConsoleVariable;
8
17 public:
19 GlobalSDLDeviceSettings(std::shared_ptr<ConsoleVariable> consoleVariable);
21
27
32 void SetStickAxisThresholdPercentage(int32_t stickAxisThresholdPercentage);
33
39
44 void SetTriggerAxisThresholdPercentage(int32_t triggerAxisThresholdPercentage);
45
48
51
52 private:
53 int32_t mStickAxisThresholdPercentage;
54 int32_t mTriggerAxisThresholdPercentage;
55 std::shared_ptr<ConsoleVariable> mConsoleVariable;
56};
57} // namespace Ship
Global threshold settings for SDL gamepad analog axes.
Definition GlobalSDLDeviceSettings.h:16
void SetTriggerAxisThresholdPercentage(int32_t triggerAxisThresholdPercentage)
Sets the trigger axis dead-zone threshold percentage.
void SaveToConfig()
Persists the current threshold values to the Config subsystem.
int32_t GetTriggerAxisThresholdPercentage()
Returns the trigger axis dead-zone threshold as a percentage (0–100).
void SetStickAxisThresholdPercentage(int32_t stickAxisThresholdPercentage)
Sets the stick axis dead-zone threshold percentage.
int32_t GetStickAxisThresholdPercentage()
Returns the stick axis dead-zone threshold as a percentage (0–100).
void EraseFromConfig()
Removes the persisted threshold values from the Config subsystem.
GlobalSDLDeviceSettings(std::shared_ptr< ConsoleVariable > consoleVariable)
Constructs the settings and loads persisted values from configuration.
Core namespace for the libultraship engine framework.
Definition gfx_direct3d_common.h:14