4561 Commits

Author SHA1 Message Date
SDL Wiki Bot
50852f7f1b Sync SDL3 wiki -> header
[ci skip]
2026-07-08 23:11:32 +00:00
Sam Lantinga
782d6bc116 Note that Windows doesn't see mouse button releases when RIDEV_NOLEGACY is active. 2026-07-08 16:08:38 -07:00
SDL Wiki Bot
eb88a154fa Sync SDL3 wiki -> header
[ci skip]
2026-07-06 20:30:33 +00:00
Sam Lantinga
d8d5b7c6c5 Added a slider to manually adjust HDR headroom on visionOS
Ideally the OS would provide a way to query the current headroom, but for now users can manually adjust it.
2026-07-06 13:25:12 -07:00
brentfpage
46dcc0c554 for 'pinch end' events on mobile devices, send dummy value -1 for (focus|span)_(x|y) 2026-07-06 05:52:47 -07:00
Ozkan Sezer
a6d7872d2f SDL_notification.h: fix for C89 mode. 2026-07-04 00:47:56 +03:00
Ozkan Sezer
aad60dec77 SDL_intrin.h: fix error from old gcc. 2026-07-04 00:47:55 +03:00
SDL Wiki Bot
ceb4a7f1cb Sync SDL3 wiki -> header
[ci skip]
2026-07-01 22:03:03 +00:00
Ryan C. Gordon
eb04627741 stdinc: SDL_SetMemoryFunctions now handles NULL function pointers better.
Now it does _not_ call SDL_SetError(), since that would allocate memory with
the system in a weird state, and setting all four functions to NULL will
restore the original memory functions, as a shortcut vs having to query
SDL_GetOriginalMemoryFunctions() first.

Fixes #15914.
2026-07-01 18:00:09 -04:00
SDL Wiki Bot
4fe0d8c1cd Sync SDL3 wiki -> header
[ci skip]
2026-06-30 16:33:03 +00:00
Frank Praznik
d8971fa00a wayland: Add support for the session management protocol
Add session management protocol support for saving/restoring toplevel window state across runs.
2026-06-30 12:30:08 -04:00
SDL Wiki Bot
9da5a636ad Sync SDL3 wiki -> header
[ci skip]
2026-06-29 17:51:17 +00:00
Andrei Sabalenka
7ee8160922 gpu: make NULL object releases no-ops
These functions already return immediately for NULL objects in normal builds, but it was done through CHECK_PARAM. When building with SDL_DISABLE_INVALID_PARAMS, these checks were compiled out, and NULL resources could reach backend release functions and cause segfault.

Always return on NULL so API behaves consistently regardless of SDL_DISABLE_INVALID_PARAMS.
2026-06-29 10:47:52 -07:00
Ozkan Sezer
4bebbec9d4 update khronos headers from mainstream. 2026-06-26 21:32:02 +03:00
Holden Ramsey
7a6eed4ec8 Android: decouple video/audio subsystems from JNI initialization
Allow Android embedders to use SDL without the full video/audio Java
layer by gating subsystem-specific code behind SDL_VIDEO_DISABLED and
SDL_AUDIO_DISABLED preprocessor flags.

This enables applications that only need joystick/gamepad support
(e.g. Qt-based apps like QGroundControl) to build SDL without shipping
stub Java classes for unused subsystems.

Changes:
- Split SDLActivity JNI method table into core (lifecycle, hints,
  permissions) and video (surface, input, clipboard, orientation)
- Gate SDLAudioManager and SDLInputConnection JNI registration
- Make checkJNIReady() subsystem-aware: no longer requires
  mAudioManagerClass when SDL_AUDIO_DISABLED
- Group method ID resolution by subsystem in nativeSetupJNI()
- Guard all video/audio function implementations and declarations
- Keep display orientation accessors always available (needed by camera)
- Add subsystem-selective SDL.setupJNI(int)/initialize(int) to SDL.java
  with backwards-compatible zero-arg overloads
- Guard SDL_VIDEO_DRIVER_ANDROID and related defines in
  SDL_build_config_android.h
2026-06-26 10:59:54 -07:00
Frank Praznik
8554d1c23c time: Convert the PS2 time implementation to a dummy implementation
SDL has no dummy fallback for the RTC functions, and the PS2 implementation is just an empty dummy implementation, so rename it and build it if no system-specific time functionality is found.
2026-06-25 11:32:48 -04:00
SDL Wiki Bot
0fa422231d Sync SDL3 wiki -> header
[ci skip]
2026-06-24 19:48:34 +00:00
Sam Lantinga
089b862732 Added SDL_HINT_WINDOWS_RAW_MOUSE_NOLEGACY 2026-06-24 12:45:36 -07:00
Ryan C. Gordon
179e66f1fe docs: Improved SDL_CommonEvent documentation. 2026-06-24 13:15:53 -04:00
SDL Wiki Bot
135a9457f3 Sync SDL3 wiki -> header
[ci skip]
2026-06-23 18:34:01 +00:00
Frank Praznik
5471f4c3de notification: Fix old function names in documentation 2026-06-23 14:31:01 -04:00
Ryan C. Gordon
0b692f64b0 docs: warn not to destroy an SDL_AudioStream during its callback.
Fixes #15871.
2026-06-23 13:49:46 -04:00
SDL Wiki Bot
e300b87e35 Sync SDL3 wiki -> header
[ci skip]
2026-06-23 07:25:14 +00:00
SDL Wiki Bot
1a21db244c Sync SDL3 wiki -> header
[ci skip]
2026-06-23 02:18:50 +00:00
Ryan C. Gordon
4f778d56fd .wikiheaders-options: Fix Notification category. 2026-06-22 22:17:12 -04:00
Ryan C. Gordon
c1918f0817 docs: SDL_Locale is a struct, not a function. 2026-06-22 22:13:21 -04:00
Sam Lantinga
07ecc125cf Added SDL_PIXELFORMAT_P408 and SDL_PIXELFORMAT_P416 2026-06-22 17:01:54 -05:00
SDL Wiki Bot
0bb539314d Sync SDL3 wiki -> header
[ci skip]
2026-06-22 03:32:20 +00:00
Brent Page
65091012b4 Add more information for pinch gestures on mobile (#15092) 2026-06-21 20:30:50 -07:00
SDL Wiki Bot
941dda1ccd Sync SDL3 wiki -> header
[ci skip]
2026-06-21 18:52:43 +00:00
Semphriss
e52dbf4442 Add basic Ubuntu Touch functions #12543
This adds support for:
* System theme
* Sandbox detection
* Device form factor detection

Many things aren't properly supported yet, but changes and upgrades will happen on the Ubuntu Touch side, so SDL should automatically support more Ubuntu Touch features as time goes.
2026-06-21 11:51:15 -07:00
SDL Wiki Bot
da8ee4d5cc Sync SDL3 wiki -> header
[ci skip]
2026-06-21 15:34:46 +00:00
Semphriss
d474769878 Detect device form factor (#12584) 2026-06-21 08:33:13 -07:00
Ryan C. Gordon
3a1cfbc147 main: If SDL_MAIN_CALLBACK_RATE="waitevent", have at least one iteration run.
This way apps can at least draw an initial image to their windows before going
into a deep, blocking wait for user interaction.

Fixes #15027.
2026-06-19 14:14:13 -04:00
Christmas-Missionary
2536a22012 Enforce the minimum version of macOS to be 10.12
- clock_gettime_nsec_np is not defined until 10.12
2026-06-18 00:45:49 -04:00
SDL Wiki Bot
ae429cf5ee Sync SDL3 wiki -> header
[ci skip]
2026-06-17 23:50:18 +00:00
Sam Lantinga
c9b6581210 Added SDL_HINT_ENABLE_STEAM_SCREEN_KEYBOARD 2026-06-17 16:48:54 -07:00
Roman Fomin
b0a9aa3db0 Fix the "redundant redeclaration" warning for __debugbreak when using MinGW (#14264) 2026-06-16 18:58:23 -04:00
Ryan C. Gordon
8138f91e5c docs: Clarify the purpose of SDL_PROP_PROCESS_CREATE_BACKGROUND_BOOLEAN.
Reference Issue #14435.
2026-06-16 13:04:01 -04:00
SDL Wiki Bot
f860d9d592 Sync SDL3 wiki -> header
[ci skip]
2026-06-16 02:19:11 +00:00
Sam Lantinga
9c30a7cc82 Revert "Add an invalid #define for SDL_ThreadID() to SDL_oldnames.h (#15801)"
This reverts commit b04d026458.

This caused problems building sdl2-compat:
https://github.com/libsdl-org/sdl2-compat/actions/runs/27378527337/job/81120423041
2026-06-12 14:59:22 -07:00
Daniel Gibson
b04d026458 Add an invalid #define for SDL_ThreadID() to SDL_oldnames.h (#15801)
in SDL2 SDL_ThreadID() was a function that's now
SDL_GetCurrentThreadID(), but in SDL3 SDL_ThreadID is a type, so
in C++ `x = SDL_ThreadID()` is valid code (default constructor which
in case of integers means 0), so that's a massive footgun.

See the big comment in SDL_oldnames.h for more details.

Added `#undef SDL_ThreadID` in SDL_dynapi.c because it has one of the
(quite rare) cases  where "SDL_ThreadID" followed by a "(" is actually
correct and necessary (function pointer returning SDL_ThreadID).
2026-06-12 10:24:56 -07:00
SDL Wiki Bot
7c60bcd83c Sync SDL3 wiki -> header
[ci skip]
2026-06-11 18:34:25 +00:00
Anonymous Maarten
f70ea37517 Hide SDL_wcstoll and SDL_wcstoull for compilers not supporting long long (#15808)
Co-authored-by: Sam Lantinga <slouken@libsdl.org>
2026-06-11 20:33:06 +02:00
Sam Lantinga
36f621842b Use the Microsoft provided GameInputCreate() function (#15797)
It does better version checking and has better compatibility.

This also fixes a crash in GameInputRedist.dll when attempting to load v3 when v2 is installed on the system. In this case, a thread is created in GameInputCreate() which is not cleaned up when the object is released, and can crash later with a NULL pointer dereference.
2026-06-10 12:57:43 -07:00
SDL Wiki Bot
3e588d5bcc Sync SDL3 wiki -> header
[ci skip]
2026-06-10 17:29:25 +00:00
Frank Praznik
068e405912 Add notification framework with test and dummy driver 2026-06-10 13:25:38 -04:00
SDL Wiki Bot
c91c5c7d85 Sync SDL3 wiki -> header
[ci skip]
2026-06-08 16:02:29 +00:00
Frank Praznik
96919c37c9 stdlib: Add SDL_wcstoul(), SDL_wcstoll(), and SDL_wcstoull()
Includes the appropriate stdlib checks and automated tests.
2026-06-08 11:58:47 -04:00
Sam Lantinga
55908f14f8 Added SDL_aligned_alloc_zero() 2026-06-05 13:55:32 -07:00