Commit Graph

20100 Commits

Author SHA1 Message Date
Sam Lantinga
02fc571cfd Fixed build 2025-09-06 10:12:01 -07:00
Sam Lantinga
5605f85d84 Check the return value of SDL_SW_CopyYUVToRGB() 2025-09-06 10:07:09 -07:00
Sam Lantinga
d21da8644b Revert "Make sure fast path RGB <-> YUV conversions are using the same color primaries"
This reverts commit ee87132385.

The supported conversions assume correct primaries for YUV converted to SRGB
2025-09-06 10:03:41 -07:00
Sam Lantinga
61e41c61dc Select the shader based on the inputs, not colorspace
Fixes https://github.com/libsdl-org/SDL/issues/13880
2025-09-06 08:58:17 -07:00
Ozkan Sezer
baf965c1ca Revert "video/openvr: define OPENVR_API_NODLL"
This reverts commit 976ba1e750.
2025-09-06 04:15:55 +03:00
Ozkan Sezer
976ba1e750 video/openvr: define OPENVR_API_NODLL
.. so that S_API doesn't expand to __declspec(dllimport)
2025-09-06 03:05:50 +03:00
Sam Lantinga
c573326f11 Fixed double-free in the OpenVR video backend 2025-09-05 14:47:20 -07:00
Ryan C. Gordon
a6dc61ab32 joystick: Emscripten can often fake a hat from the d-pad buttons.
Fixes #13817.
2025-09-05 14:46:59 -04:00
Ryan C. Gordon
937bf4d789 alsa: Restart PCM devices after recovery from an overrun/underrun.
snd_pcm_recover() puts the device back in SND_PCM_STATE_PREPARED state; you
have to explicitly restart the device afterwards with snd_pcm_start().

Fixes #13761.
2025-09-05 13:50:06 -04:00
SDL Wiki Bot
197bfab0b5 Sync SDL3 wiki -> header
[ci skip]
2025-09-05 16:44:33 +00:00
Ryan C. Gordon
b8197a2291 io: rework how we set SDL_IOStream status.
This now relies on the implementation to set these flags on short reads/writes
instead of the higher level checking if SDL_SetError() was called.

Additionally (and crucially), this now sets ERROR or EOF on all short reads,
across all backends, not just when we get a zero-byte return value.

Fixes #13720.
2025-09-05 12:43:13 -04:00
Aleksey Melekh
129c97f610 xbox: fix build 2025-09-05 09:19:54 -07:00
Sam Lantinga
3572be3998 Improved detection of FlyDigi controllers 2025-09-04 18:21:17 -07:00
Simon McVittie
99da009308 wikiheaders: Escape backslash in man pages
Otherwise, groff will interpret it as a macro, causing the man page
for SDL_GetPrefPath() to be mis-rendered. Escape unescaped backslashes
as `\(rs` ("reverse solidus") before escaping other characters with
macros that, themselves, contain backslashes.

Resolves: https://github.com/libsdl-org/SDL/issues/13039
Signed-off-by: Simon McVittie <smcv@collabora.com>
2025-09-04 19:59:15 -04:00
SDL Wiki Bot
5505cb2bb9 Sync SDL3 wiki -> header
[ci skip]
2025-09-04 23:54:17 +00:00
Ryan C. Gordon
3597877277 SDL_main.h: Cleanups in SDL_RegisterApp documentation.
There is an escaped pipe character, because this ends up in a Markdown table
on the wiki, and the wiki software (incorrectly, I think) sees the pipe inside
a code-block and thinks it's the end of the table cell if not escaped.

But this escape char looks wrong everywhere else.

Keeping the parameter table terse is always a good idea, so I moved the
detail out to the Remarks section, which doesn't have a problem with this
character appearing in the text.
2025-09-04 19:50:04 -04:00
Sam Lantinga
a9b5a1e785 Simplified the transparent software renderer test 2025-09-04 10:31:22 -07:00
Sam Lantinga
f48c20f481 Added testsoftwaretransparent to the CMake build system 2025-09-04 09:25:05 -07:00
Sam Lantinga
9e3d5969e6 Fixed testsoftwaretransparent on platforms using a renderer for window surfaces 2025-09-04 09:24:22 -07:00
Qiang
f2d2cd8152 fix: Blending rendering anomaly when using the software renderer with SDL_WINDOW_TRANSPARENT on Windows. (#13866) 2025-09-04 07:41:45 -07:00
Sam Lantinga
ea1a769322 Fixed the perspective matrix calculation (thanks @KonkolyTamas!)
Fixes https://github.com/libsdl-org/SDL/issues/13867
2025-09-04 06:04:01 -07:00
Sam Lantinga
637a9b34ab Added a comment explaining the initialization delay 2025-09-03 15:47:21 -07:00
Cameron Cawley
41452ef4bf Remove unused OpenGL references in the examples CMakeLists 2025-09-03 15:43:59 -07:00
Cameron Cawley
54745c5cf4 Only bundle the required resources with examples on the 3DS 2025-09-03 15:43:59 -07:00
Cameron Cawley
20c00babbc Create an application bundle for examples on Mac OS X 2025-09-03 15:43:59 -07:00
Sam Lantinga
b6a55c2856 Wait a bit for initialization to complete before requesting calibration data
Fixes https://github.com/libsdl-org/SDL/issues/13856
2025-09-03 15:36:58 -07:00
Cameron Cawley
42f571ea4b Remove unused PSP source files 2025-09-03 15:19:24 -07:00
Sam Lantinga
9abeeebad5 Fixed warning: no previous prototype for function 2025-09-03 11:23:55 -07:00
Simon McVittie
4441d8b0ad x11: Don't include XDestroyImage in the table of exported functions
When linking directly to libX11 as a hard dependency, we assign the
addresses of functions like XDestroyImage to function pointers like
X11_XDestroyImage. However, by default Xutils.h doesn't declare
XDestroyImage as a function: it only provides a macro which looks into
the XImage struct and calls a function pointer directly, similar to
a virtual method.

SDL_x11framebuffer.c was already relying on being able to call the macro
without explicitly linking to libX11, so do the same here.

Fixes: d14cbd7b "Introduce X11 toolkit and make message dialogs use it"
Signed-off-by: Simon McVittie <smcv@collabora.com>
2025-09-03 09:22:38 -07:00
eafton
51052245d1 X11TK: Fix locale bug for non-dialog windows 2025-09-03 07:00:59 -07:00
Sylvain
b084999d40 testautomation_events: initialize variable to prevent undefined read 2025-09-03 10:15:01 +02:00
Sam Lantinga
437d78499c Don't set SDL_SURFACE_LOCK_NEEDED until a surface is RLE encoded
Reference https://github.com/libsdl-org/sdl2-compat/issues/476
2025-09-02 21:31:51 -07:00
Sam Lantinga
fbbc29159a Leave letterbox borders set to the frame clear color
Fixes https://github.com/libsdl-org/sdl2-compat/issues/483
2025-09-02 20:14:34 -07:00
Ozkan Sezer
cc9937201e x11: fix a typo after PR/13855 and kill lots of trailing whitespace 2025-09-03 04:37:56 +03:00
Sam Lantinga
ef19c72015 Set the texture scale and address mode when creating a texture
Fixes https://github.com/libsdl-org/sdl2-compat/issues/506
2025-09-02 18:05:31 -07:00
eafton
d14cbd7b50 Introduce X11 toolkit and make message dialogs use it (#13855) 2025-09-02 13:22:48 -07:00
Ryan C. Gordon
af74b1fe84 wikiheaders: Generate a current list of supported environment variables.
Fixes #13827.
2025-09-02 15:49:52 -04:00
Ozkan Sezer
83bb0f9105 cmake: simd detection clean-up for Apple multi-arch configs. 2025-09-02 22:34:10 +03:00
Anonymous Maarten
c0fb71f2a9 cmake: fix SDL_UNINSTALL post-configuration report 2025-09-02 21:29:50 +02:00
Anonymous Maarten
e15e2808f2 cmake: use 'TargetConditionals.h' on Apple for SIMD tests 2025-09-02 21:29:50 +02:00
Anonymous Maarten
1e7d3b51de cmake: use APPLE in dep_option
expands to <nothing> on e.g. Windows, which will be interpreted as true by cmake_dependent_option.
2025-09-02 21:29:50 +02:00
Sam Lantinga
84af0bb53a Updated the 8BitDo Ultimate 2 Wireless Controller dongle update rate
The latest dongle firmware appears to update at 1000Hz
2025-09-02 09:53:09 -07:00
Sam Lantinga
a562e40d2c Revert "Disable rumble for the Ultimate 2 Wireless Controller in dongle mode"
This reverts commit 065fdca953.

8BitDo has fixed the rumble issue with dongle firmware update V1.05
2025-09-02 09:53:09 -07:00
Sam Lantinga
b47572c9bb Fixed build warning with Visual Studio 2025-09-02 09:53:09 -07:00
Ethan Lee
689049f8ec gpu: VK_KHR_get_physical_device_properties2 can be optional 2025-09-02 09:53:01 -07:00
Sylvain
7920e48386 Fixed bug #13849 - Intent always explicit 2025-09-02 09:37:41 -07:00
DominusExult
a223481ed3 xcFramework: Removing the simulators' debug symbols to reduce file size. 2025-09-02 08:57:18 -07:00
Maia
5938dce5de Add missing include 2025-09-02 12:52:53 +02:00
Sylvain
814f0b7d41 Android: more simplification since min API supported is 21 2025-09-02 12:34:38 +02:00
Sam Lantinga
1f007ad5cd Added support for the player LED on Nintendo Switch 2 controllers 2025-09-01 21:11:16 -07:00