1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-04 12:00:25 +00:00

Add support for SDL3 joystick input driver

Made possible by EIREXE, xsellier and the SDL team.

This commit includes statically linked SDL3 for Windows, Linux and macOS.
The vendored copy of SDL3 was setup to only build the required subsystems
for gamepad/joystick support, with some patches to be able to make it as
minimal as possible and reduce the impact on binary size and code size.

Co-authored-by: Álex Román Núñez <eirexe123@gmail.com>
Co-authored-by: Xavier Sellier <xsellier@gmail.com>
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
This commit is contained in:
Nintorch
2025-05-28 14:22:20 +05:00
committed by Rémi Verschelde
parent 987832be46
commit 0b3496fb4f
330 changed files with 154930 additions and 1561 deletions

View File

@@ -31,7 +31,6 @@
#pragma once
#include "crash_handler_linuxbsd.h"
#include "joypad_linux.h"
#include "core/input/input.h"
#include "drivers/alsa/audio_driver_alsa.h"
@@ -48,6 +47,8 @@
#endif
#endif
class JoypadSDL;
class OS_LinuxBSD : public OS_Unix {
virtual void delete_main_loop() override;
@@ -60,8 +61,8 @@ class OS_LinuxBSD : public OS_Unix {
int _stretch_to_fc(int p_stretch) const;
#endif
#ifdef JOYDEV_ENABLED
JoypadLinux *joypad = nullptr;
#ifdef SDL_ENABLED
JoypadSDL *joypad_sdl = nullptr;
#endif
#ifdef ALSA_ENABLED