mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2026-04-24 15:33:02 +00:00
|
Some checks are pending
Canary CI / Release for linux-arm64 (push) Waiting to run
Canary CI / Release for linux-x64 (push) Waiting to run
Canary CI / Release for win-x64 (push) Waiting to run
Canary CI / Release MacOS universal (push) Waiting to run
Canary CI / Post CI Steps (push) Blocked by required conditions
Four SDL3 gamepad fixes, all affecting real users with Switch controllers. **Crash on reconnect / broken motion** — `GetFeaturesFlag()` was calling `SDL_DestroyProperties()` on properties owned by SDL internally, causing a use-after-free. This breaks gyro after the first read and crashes on reconnect. Fix: just don't destroy them. **Thread safety in `GetGamepads()`** — was locking the wrong objects and holding locks across `yield` boundaries, which is undefined behavior with `System.Threading.Lock`. Fix: snapshot IDs under `_lock`, iterate outside it. **Rumble NPE on disconnect** — `UpdateRumble()` called `_gamepad.Rumble()` without a null check; throws if the controller disconnects mid-update. Fix: `_gamepad?.Rumble(...)`. **Linux: HIDAPI conflicts with `hid_nintendo`** — when the `hid_nintendo` kernel module is loaded, it provides evdev nodes for both the gamepad and IMU that SDL3's evdev backend correctly combines. HIDAPI conflicts with it, breaking gyro and wireless hotplug. Fix: detect `/sys/module/hid_nintendo` at startup and disable HIDAPI for Switch controllers automatically. Overridable via `SDL_JOYSTICK_HIDAPI_SWITCH=1`. Tested with an 8BitDo Ultimate Bluetooth Controller on Linux. Co-authored-by: schuay <36006+schuay@users.noreply.github.com> Reviewed-on: https://git.ryujinx.app/projects/Ryubing/pulls/19 |
||
|---|---|---|
| .. | ||
| Ryujinx.Input.SDL3.csproj | ||
| SDL3Gamepad.cs | ||
| SDL3GamepadDriver.cs | ||
| SDL3JoyCon.cs | ||
| SDL3JoyConPair.cs | ||
| SDL3Keyboard.cs | ||
| SDL3Mouse.cs | ||
| SDL3MouseDriver.cs | ||
| SDLKeyboardDriver.cs | ||