![]() |
Gondwana Game Engine Development (master) - 2.6.1
Gondwana is a cross-platform 2.5D game and rendering engine written in C#/.NET 8. It provides fine-grained control over rendering, timing, and scene composition, with built-in support for parallax, z-ordering, pixel overhang, collision detection, and particle effects. Gondwana targets desktop and web platforms using SkiaSharp for graphics and pluggable audio backends for desktop and browser targets.
|
Provides a gamepad adapter implementation using SDL2 for cross-platform gamepad input support. More...
Public Member Functions | |
| SdlGamepadAdapter (int deviceIndex) | |
| Initializes a new instance of the SdlGamepadAdapter class for the specified device. | |
| void | Poll () |
| Polls the gamepad for the current state of all buttons, analog sticks, and triggers. | |
| void | Dispose () |
| Releases all resources used by the SdlGamepadAdapter and closes the SDL gamepad controller. | |
Properties | |
| string | GamepadId [get] |
| Gets the unique identifier for this gamepad. | |
| IReadOnlyCollection< string > | PressedButtons [get] |
| Gets the collection of currently pressed button names. | |
| GamepadStickState? | LeftStick [get] |
| Gets the current state of the left analog stick. | |
| GamepadStickState? | RightStick [get] |
| Gets the current state of the right analog stick. | |
| float | LeftTrigger [get] |
| Gets the current pressure value of the left trigger (0.0 to 1.0). | |
| float | RightTrigger [get] |
| Gets the current pressure value of the right trigger (0.0 to 1.0). | |
Provides a gamepad adapter implementation using SDL2 for cross-platform gamepad input support.
Definition at line 8 of file SdlGamepadAdapter.cs.
| Gondwana.Input.Gamepad.SDL2.SdlGamepadAdapter.SdlGamepadAdapter | ( | int | deviceIndex | ) |
Initializes a new instance of the SdlGamepadAdapter class for the specified device.
| deviceIndex | The SDL device index of the gamepad to open. |
| InvalidOperationException | Thrown when the SDL gamepad controller cannot be opened at the specified index. |
Definition at line 48 of file SdlGamepadAdapter.cs.
| void Gondwana.Input.Gamepad.SDL2.SdlGamepadAdapter.Dispose | ( | ) |
Releases all resources used by the SdlGamepadAdapter and closes the SDL gamepad controller.
Definition at line 110 of file SdlGamepadAdapter.cs.
| void Gondwana.Input.Gamepad.SDL2.SdlGamepadAdapter.Poll | ( | ) |
Polls the gamepad for the current state of all buttons, analog sticks, and triggers.
Definition at line 60 of file SdlGamepadAdapter.cs.
|
get |
Gets the unique identifier for this gamepad.
Implements Gondwana.Input.Gamepad.IGamepadAdapter.
Definition at line 16 of file SdlGamepadAdapter.cs.
|
get |
Gets the current state of the left analog stick.
Implements Gondwana.Input.Gamepad.IGamepadAdapter.
Definition at line 26 of file SdlGamepadAdapter.cs.
|
get |
Gets the current pressure value of the left trigger (0.0 to 1.0).
Implements Gondwana.Input.Gamepad.IGamepadAdapter.
Definition at line 36 of file SdlGamepadAdapter.cs.
|
get |
Gets the collection of currently pressed button names.
Implements Gondwana.Input.Gamepad.IGamepadAdapter.
Definition at line 21 of file SdlGamepadAdapter.cs.
|
get |
Gets the current state of the right analog stick.
Implements Gondwana.Input.Gamepad.IGamepadAdapter.
Definition at line 31 of file SdlGamepadAdapter.cs.
|
get |
Gets the current pressure value of the right trigger (0.0 to 1.0).
Implements Gondwana.Input.Gamepad.IGamepadAdapter.
Definition at line 41 of file SdlGamepadAdapter.cs.