Sam Lantinga
e643d28d9c
Set the hint value before calling hint callbacks
...
This allows the hint callbacks to perform more complicated logic involving multiple hints without worrying about which hint has been changed.
2023-06-28 08:53:48 -07:00
Sylvain
ad12bb4fd1
Remove hints that weren't used anymore !
2023-06-28 06:22:20 -07:00
Anonymous Maarten
7751bfdbf3
cmake: create wiki dir before running wikiheaders.pl --copy-to-wiki
2023-06-28 14:41:31 +02:00
Sam Lantinga
0f4679102c
Fixed pedantic warning: comma at end of enumerator list
...
Fixes https://github.com/libsdl-org/SDL/issues/7878
2023-06-27 21:52:33 -07:00
Sam Lantinga
cc5e9ffe70
Don't crash if SDL_MapRGB() and SDL_MapRGBA() are passed a NULL format
2023-06-27 16:08:19 -07:00
Sylvain
600c615529
Fixed bug #7821 - docs/README-migration.md function name typos
2023-06-27 20:10:47 +02:00
Anonymous Maarten
afdd448834
cmake: don't install sdlmanpages.cmake
2023-06-27 19:02:44 +02:00
Sam Lantinga
9ee1200e6f
Fixed Nintendo Switch Pro controllers that don't have readable user calibration
2023-06-27 07:48:42 -07:00
Sam Lantinga
c065a9b128
Fix some issues caught by check_stdlib_usage.py
2023-06-27 06:19:06 -07:00
Anonymous Maarten
e8d2ccbc1c
ci: reduce amount of files to copy back from freebsd vm
...
This should reduce the chance on an error during copy back
2023-06-27 13:59:15 +02:00
Anonymous Maarten
1061a978c3
cmake: fix header GLOB used for generating man pages
2023-06-27 13:49:50 +02:00
Sylvain
70ccf34587
Script to detect use of stdlib function
2023-06-27 04:47:08 -07:00
Anonymous Maarten
937f5d0059
cmake: allow man page installation by SDL satellite libraries
...
This is done by installing the wikiheaders.pl script, and add a wrapping cmake function.
2023-06-27 03:00:19 +02:00
Frank Praznik
9ab2025127
wayland: Don't initialize OpenGL when the window flags didn't specify it
...
Applications that don't specify a rendering flag are likely handling Vulkan/GL themselves, so SDL loading OpenGL by default in this case is unnecessary overhead, and if a render backend requires it, the window will be recreated with the appropriate flags when the renderer is initialized.
2023-06-26 13:57:48 -04:00
Narr the Reg
425062c123
hidapi: switch: Handle MCU input reports
2023-06-26 10:01:49 -07:00
Ozkan Sezer
02398a8f11
Allow building against old Linux kernels.
2023-06-26 18:01:50 +03:00
Sam Lantinga
fd062657dd
Fixed build
2023-06-26 07:43:44 -07:00
meyraud705
6cc21af900
Don't keep sensor file open while sensors are disabled
2023-06-26 07:32:40 -07:00
meyraud705
9cfac88054
Improve sensor detection for Linux gamepad
2023-06-26 07:32:40 -07:00
meyraud705
000277060c
Add support for sensor to joystick on Linux (evdev)
2023-06-26 07:32:40 -07:00
Sylvain
95727b5c7d
use of SDL functions
2023-06-25 15:50:23 -07:00
Sam Lantinga
87e916dd21
SDL_FindFreePlayerIndex() will always return the next available player index
...
Fixes https://github.com/libsdl-org/SDL/issues/7868
2023-06-24 15:38:38 -07:00
Sam Lantinga
267fdd7daa
Removed Bluetooth connection detection now that we get it from hidapi
2023-06-23 15:50:07 -07:00
Sam Lantinga
44bae1e8a9
Corrected the Victrix FS Pro as a PS4 controller instead of a PS3 controller
2023-06-23 14:27:21 -07:00
Sam Lantinga
6b12fbc6b7
Re-add the simpler SDL_DBus_AppendDictWithKeyValue() function
2023-06-23 07:28:05 -07:00
Sylvain
6f344f29b8
After using SDL_qsort, mark sort_entries() as SDLCALL
2023-06-23 12:52:05 +02:00
Sylvain
1827a0bf62
Remove some use of C runtime functions in testevdev
2023-06-23 11:08:08 +02:00
Sylvain
6cde3835f0
Remove some use of C runtime functions (strlen, qsort)
2023-06-23 10:51:15 +02:00
Sam Lantinga
a807b14957
Greatly improved Xbox One controller initialization sequence
2023-06-22 17:15:35 -07:00
Sylvain
8b86e3073d
Revert "Android: also protect Hat/Joy/PadDown,Up so there are not sent without window"
...
This reverts commit 8f83ccd750
.
2023-06-22 23:30:41 +02:00
Sylvain
8f83ccd750
Android: also protect Hat/Joy/PadDown,Up so there are not sent without window
2023-06-22 16:25:22 +02:00
SDL Wiki Bot
a3e0cd5208
Sync SDL3 wiki -> header
2023-06-22 13:45:16 +00:00
Sylvain
627165a2b2
Fix comments
2023-06-22 15:44:48 +02:00
Sylvain
4339113072
SDL_DBus_AppendDictWithKeyValue: allows several key/value for other PRs
2023-06-22 10:50:35 +02:00
Sam Lantinga
8aee6908bb
Make sure we send update complete events for delayed guide buttons
2023-06-21 18:42:25 -07:00
Sam Lantinga
4c9fb3e169
Added the events SDL_EVENT_JOYSTICK_UPDATE_COMPLETE and SDL_EVENT_GAMEPAD_UPDATE_COMPLETE
...
This allows the application to tell when a joystick polling cycle is complete and can process state changes as a single atomic update. It is disabled by default, at least for now.
2023-06-21 13:59:53 -07:00
Sam Lantinga
808d83dd67
Allow specifying APP_PLATFORM and APP_ABI on the command line
2023-06-21 13:49:09 -07:00
Sam Lantinga
214d5daa3c
Removed 100 ms hitch when querying third party Nintendo Switch controllers that don't respond to request for info
...
Also take advantage of the fact that we know whether the device is connected over Bluetooth now.
2023-06-21 12:14:50 -07:00
Sam Lantinga
3694dabe7c
Use default sensor calibration if we can't read it from the Nintendo Switch controller
...
Fixes https://github.com/libsdl-org/SDL/issues/7830
2023-06-21 10:28:45 -07:00
Sam Lantinga
6306ee9f42
List the available haptic devices in testhaptic
2023-06-20 09:33:59 -07:00
Sam Lantinga
8cf5dc9963
Build on Android targeting the arm64-v8a architecture by default
...
This speeds up iteration time and covers most customer devices
2023-06-20 09:18:19 -07:00
Sam Lantinga
5f3213eb0e
Added support for gamepad sensor fusion with the Razer Kishi
2023-06-20 08:41:15 -07:00
Simon McVittie
91198baed4
ibus: Handle error when getting the D-Bus machine ID
...
It is possible for retrieving the machine ID to fail, either because
dbus was installed incorrectly (machine ID absent or corrupt), or in
32-bit builds, because stat() on the machine ID fails with EOVERFLOW
if it has an out-of-range timestamp or inode number.
dbus has historically treated this as a faulty installation, raising
a warning which by default causes the process to crash. Unfortunately,
dbus_get_local_machine_id() never had a way to report errors, so it has
no alternative for that (bad) error handling.
In dbus >= 1.12.0, we can use dbus_try_get_local_machine_id() to get
the same information, but with the ability to cope gracefully with
errors. ibus won't work in this situation, but that's better than
crashing.
Mitigates: https://github.com/ValveSoftware/steam-for-linux/issues/9605
Signed-off-by: Simon McVittie <smcv@collabora.com>
2023-06-20 06:46:33 -07:00
Sam Lantinga
3ddbeab88f
Moved Android sensor event handling to a separate thread
...
This makes it so you can interact with sensors on multiple threads, as long as only one thread initializes and cleans up the sensor subsystem.
This also has the benefit that sensor data is available as soon as possible.
2023-06-20 01:17:44 -07:00
Sam Lantinga
329e1b8b6a
Update the sensors before the joysticks so the gamepad code gets fresh sensor readings
2023-06-19 19:42:01 -07:00
Sam Lantinga
1a9c04e9f1
Don't try to update the gamepad fusion sensors manually, instead rely on the normal update flow
2023-06-19 19:41:20 -07:00
Sam Lantinga
20ea35138f
Use a separate sensor watching function for gamepad events to avoid reliance on system sensor events and prevent a potential deadlock
2023-06-19 16:17:34 -07:00
Sam Lantinga
70e43c150e
Added support for blitting SDL_PIXELFORMAT_INDEX1LSB
...
Fixes https://github.com/libsdl-org/SDL/issues/7844
(cherry picked from commit a3d4fd71c3163b2b827f9e87930dec72c93b2fb2)
2023-06-19 08:38:07 -07:00
Sam Lantinga
c6ee9780df
Fixed DualSense controllers not being picked up by the HIDAPI driver
...
The hidraw device may take additional time to get the correct permissions for us to open it. In my tests on Steam Deck hardware, this ranges between 5-8ms.
2023-06-18 12:19:54 -07:00
Sam Lantinga
4e81b4e8de
Added SDL_HINT_VIDEO_X11_SCALING_FACTOR to allow overriding the content scale on X11 (thanks Andres!)
2023-06-18 12:19:43 -07:00