25 SDLGyroMapping(uint8_t portIndex,
float sensitivity,
float neutralPitch,
float neutralYaw,
float neutralRoll,
26 std::shared_ptr<ControlDeck> controlDeck =
nullptr,
27 std::shared_ptr<ConsoleVariable> consoleVariable =
nullptr);
Maps a physical gyroscope to virtual gyro input values.
Definition ControllerGyroMapping.h:18
Maps an SDL gamepad's gyroscope sensor to a virtual gyro input.
Definition SDLGyroMapping.h:15
std::string GetGyroMappingId() override
Returns the unique string identifier for this mapping.
void SaveToConfig() override
Persists this mapping to the application configuration.
void Recalibrate() override
Samples the current sensor output and recalculates neutral offsets.
SDLGyroMapping(uint8_t portIndex, float sensitivity, float neutralPitch, float neutralYaw, float neutralRoll, std::shared_ptr< ControlDeck > controlDeck=nullptr, std::shared_ptr< ConsoleVariable > consoleVariable=nullptr)
Constructs an SDL gyro mapping with calibration offsets.
std::shared_ptr< ControlDeck > mControlDeck
Definition SDLGyroMapping.h:53
void UpdatePad(float &x, float &y) override
Reads the gyro sensor and writes the resulting X/Y values.
std::string GetPhysicalDeviceName() override
Returns the human-readable name of the SDL gamepad device.
void EraseFromConfig() override
Removes this mapping from the application configuration.
std::shared_ptr< ConsoleVariable > mConsoleVariable
Definition SDLGyroMapping.h:52
Core namespace for the libultraship engine framework.
Definition gfx_direct3d_common.h:14