Commit Graph

12114 Commits

Author SHA1 Message Date
Anonymous Maarten
eedf76f8ed ci: don't do 'brew install pkg-config' anymore
Assume it is installed by default
2024-11-22 21:47:35 +01:00
Wouter Wijsman
dccd23e6fb PSP: Add locale support
(cherry picked from commit f39c5cf989)
2024-11-22 08:38:31 -08:00
Anonymous Maarten
7217771458 cmake: Compatibility with CMake < 3.10 will be removed in a future CMake version 2024-11-17 21:56:09 +01:00
Ozkan Sezer
3ee780ce9c build system: disable 3dNow! support by default
Closes: https://github.com/libsdl-org/SDL/issues/11472.
(cherry picked from commit 51570d9257)
2024-11-17 17:55:32 +03:00
jimtahu
bee8874629 Always Use Next Display Index
WIN_AddDisplay asserted that the returned index is the expected next
one in the list. This can be an unexpected number when displays are
add and removed in a batch (eg, Remote Desktop disconnect and reconnect).
Instead always just make use of the next index, even if it is not the
expected next index value. This fixes issue #9105
2024-11-15 14:03:42 -08:00
rsn8887
11ffdd3abc SDL_vitatouch.c: re-enable front touch on Vita
(cherry picked from commit 6dcf75710c)
2024-11-15 10:15:10 -08:00
Zack Middleton
6f859d90f1 Fix SDL_PRIs64 to use standard PRId64
PRIs64 doesn't exist in C standards.

(cherry picked from commit 8a2cac7aaa)
(cherry picked from commit 761ea32b74)
2024-11-15 10:15:10 -08:00
Ryan C. Gordon
96f4421e5f audio: Favor OpenSL ES over AAudio.
There are low-latency fixes in SDL3 that really need to be backported to SDL2
before AAudio will be nicer across a range of devices, so OpenSL ES is safer
in SDL2 at the moment. At least, we suspect as such.

Fixes #11457.

(cherry picked from commit 17b9ed7d82)
2024-11-13 18:25:47 -05:00
Sam Lantinga
ad602924a4 Support multiple joystick buttons bound to the same gamepad button
(cherry picked from commit ed943318e2)
(cherry picked from commit 74ff82f4a2)
2024-11-05 11:52:07 -08:00
Anonymous Maarten
9eca707549 cmake: releases have a REVISION.txt instead of VERSION.txt 2024-11-04 19:20:23 +01:00
Anonymous Maarten
4fc47a774f port build-script from SDL3
[ci skip]
2024-11-02 02:19:50 +01:00
Sam Lantinga
c98c4fbff6 Updated to version 2.30.9 for release release-2.30.9 2024-11-01 14:24:51 -07:00
Sam Lantinga
4d4f004968 Fixed the PS5 controller face buttons on Amazon Fire TV, Android 11
(cherry picked from commit 09495059df)
(cherry picked from commit 3b7a45853c)
2024-10-30 05:24:08 -07:00
Sam Lantinga
5d7a023430 Revert "aaudio: Set low-latency audio mode."
This reverts commit 1e016fd5ea.

In order to use low latency mode, you need to set low latency callbacks. This has always been recommended and is apparently required on Android 15. SDL3 has these implemented correctly but SDL2 does not, so we should revert this for now.

Fixes https://github.com/libsdl-org/SDL/issues/11376

(cherry picked from commit d2b9ecd281)
2024-10-29 22:36:54 -07:00
dv-senna
3e272e73d6 SDL_vulkan.h: undefine VK_DEFINE_HANDLER and VK_DEFINE_NON_DISPATCHABLE_HANDLE
Allows including vulkan.hpp in user code in C++ before SDL_vulkan.h w/o errors.
Fixes:  https://github.com/libsdl-org/SDL/issues/11328 .

(cherry picked from commit 149ecffd6f)
(cherry picked from commit 478dff3585)
2024-10-29 22:36:24 -07:00
Ryan C. Gordon
cc2352f842 wasapi: Deal with device buffer sizes changing.
Otherwise, it would fill the previous size's worth of data into the current
size's buffer.

Fixes #11122.

(cherry picked from commit 5b0e838a74)
2024-10-29 22:36:19 -07:00
Ryan C. Gordon
f170ced2a7 cocoa: Patched to compile.
(cherry picked from commit e5348c611d)
2024-10-25 10:23:36 -04:00
Ryan C. Gordon
dcdb763de8 cocoa: Make sure GL context destruction happens on the main thread.
Fixes #10900.

(cherry picked from commit 5cb87ff99f)
2024-10-25 10:17:47 -04:00
Ryan C. Gordon
5c9f37080e emscripten: scale mousewheel X coordinates correctly, not just Y coordinates.
Fixes #10454.

(cherry picked from commit 00f15dd215)
2024-10-23 23:41:10 -04:00
Ivan Epifanov
257d75429d VITA: fix SDL_ShowMessageBox by using different memory type
(cherry picked from commit 52714d5063)
2024-10-22 12:22:20 -07:00
Frank Praznik
c1adfb4c94 wayland: Always create a viewport for the window if available
Viewports decouple the buffer from the window size and avoids the window geometry hacks used to prevent problems if a buffer with an old size in the pipeline ends up being committed.

Fixes an invalid geometry warning and incorrect overview size for fullscreen windows on GNOME, and avoids flicker when entering/exiting fullscreen or moving the window between scaled and non-scaled displays.

(cherry picked from commit 849c905d8c)
2024-10-21 15:22:24 -04:00
Ivan Epifanov
217bc17a21 VITA: fix yuv texture update
(cherry picked from commit 86fd4ed83c)
2024-10-17 07:54:41 -07:00
Sam Lantinga
7107e02315 Only use Steam Virtual Gamepads if we're running under Steam
Fixes https://github.com/libsdl-org/SDL/issues/11214
Fixes https://github.com/libsdl-org/SDL/issues/11215

(cherry picked from commit 8a30def5f2)
(cherry picked from commit b6fa4dc794)
2024-10-16 17:53:01 -07:00
Sam Lantinga
062a777240 Added support for the Steam Virtual Gamepad on macOS Sequoia
(cherry picked from commit d7b1ba1bfc)
(cherry picked from commit cfb3db01dc)
2024-10-16 17:53:01 -07:00
Pierre Wendling
1842745c9c VisualC: Set the correct component to false.
When SDL2_main would not be found, it would incorrectly flag the shared SDL2 library as not found.

(cherry picked from commit 378234437f)
2024-10-13 09:03:22 -07:00
Cameron Cawley
bbcc9421d6 3DS: Support simple message boxes
(cherry picked from commit 23d456e146)
2024-10-13 09:03:22 -07:00
Cameron Cawley
b58a1c7f33 3DS: Only bundle resources with tests that need them
(cherry picked from commit d7bb56f163)
2024-10-13 09:03:22 -07:00
Cameron Cawley
79a8f7b3a0 Reduce the size of the SDL_blit_0 alpha code
(cherry picked from commit 90f792f83c)
2024-10-13 09:03:22 -07:00
Cameron Cawley
302ab09178 testdrawchessboard: Allow using the standard render API
(cherry picked from commit e2f27362cb)
2024-10-13 09:03:22 -07:00
Guldoman
e1e38e2250 x11: Set correct clipboard target type in SelectionRequest handling
(cherry picked from commit 5fe010270a)
2024-10-13 09:02:49 -07:00
Sam Lantinga
2638809c50 Fixed typo in SDL_audio.h
(cherry picked from commit da4608ed03)
2024-10-10 08:50:19 -07:00
Sam Clegg
36853f923e [emscripten] Fixes for data addresses above 2gb
This includes both wasm64 and wasm32 when addressing more than 2gb of
memory.

Fixes: #9052
(cherry picked from commit 3deb07ea39)
2024-10-08 15:17:44 -07:00
Sam Lantinga
63aff8e3d0 Added support for wired XBox controllers on macOS 15.0 Sequoia
Fixes https://github.com/libsdl-org/SDL/issues/11002

(cherry picked from commit 7da728a642)
(cherry picked from commit da19244f7f)
2024-10-07 16:41:47 -07:00
Sam Lantinga
7eebc2ad4d Fixed detecting the Steam Virtual Gamepad on macOS
(cherry picked from commit bb33eb409e)
2024-10-07 16:22:03 -07:00
Frank Praznik
0f695adb03 Reapply "wayland: Don't initialize OpenGL when the window flags didn't specify it"
This reverts commit 120b8d4189.

The issue this was patching over in Vanilla-Conquer was the lack of an exposure event when showing a window, which has since been remedied.

Attaching EGL window objects can also cause protocol violations now that the explicit sync protocol is in use, if SDL creates one and then the client tries to attach one itself, so they really shouldn't be created unless the client specifically requested it.

(cherry picked from commit 643437f5b0)
2024-10-02 13:52:59 -04:00
Anonymous Maarten
79ec168f3c Add docs to mingw release and don't modify libtool files in mingw's Makefile
(cherry picked from commit 2b2907db18)
release-2.30.8
2024-10-01 23:05:24 +02:00
Anonymous Maarten
40a3a80d45 release.yml needs setup-ninja 2024-10-01 21:38:05 +02:00
Anonymous Maarten
025fc35c87 Port SDL3 release scripts to SDL2
[skip ci]

(cherry picked from commit 8291b1be36)
2024-10-01 21:22:06 +02:00
Sam Lantinga
e9f5f3ac1f Updated to version 2.30.8 for release 2024-10-01 09:25:57 -07:00
Sam Lantinga
235c87dc92 Don't use BlitARGBto555PixelAlpha() for SDL_PIXELFORMAT_ARGB1555
This didn't properly take into account destination alpha.

Fixes https://github.com/libsdl-org/SDL/issues/8401

(cherry picked from commit 1aea43846e)
(cherry picked from commit c9f3cbe02f)
2024-09-25 21:58:42 -07:00
Cameron Gutman
b6535836aa Throttle tickle reports to PS4/PS5 controllers
UpdateDevice() can be called at an arbitrary rate, so we need to
pace ourselves to avoid filling up the rumble queue with these.

(cherry picked from commit 6ec8b1a173)
(cherry picked from commit 656b599828)
2024-09-25 07:23:09 -07:00
Cameron Gutman
5e90dd3507 kmsdrm: Fix one more place that doesn't try to drop master
(cherry picked from commit 7eb85b07e0)
2024-09-23 19:11:42 -05:00
Cameron Gutman
d9139ff3de kmsdrm: Keep fd around if we can drop master
Modern kernels (v5.8+) allow non-root usage of drmDropMaster(), so
we can hold on to our fd after dropping master on it. This fixes
populating drm_fd in the KMSDRM SysWMinfo when using Vulkan.

Also add a missing error check for open() while we're here.

(cherry picked from commit dab4f856c1)
2024-09-23 08:12:58 -07:00
T3hD0gg
5669b97fd7 Add Thrustmaster TMX VID & PID to wheel device list.
(cherry picked from commit 594edb6bd2)
(cherry picked from commit ec9a9fee58)
2024-09-18 22:22:22 -07:00
Cameron Gutman
6f0fae7432 wayland: Fix memory leaks
(cherry picked from commit e239295491)
2024-09-18 20:46:20 -04:00
Anders Jenbo
1c4dd015ac Spell "unknown" correctly
(cherry picked from commit ee377793fe)
(cherry picked from commit d9b4b7d0e0)
2024-09-13 12:30:16 -07:00
Ryan C. Gordon
e9efcfb428 pulseaudio: Hotplug thread fixes.
This used a tiny stack, which apparently upsets Blender for various
technical reasons. Instead, just use the default stack size, which should
give it plenty of space to work.

If the thread failed to create, we would then wait on a semaphore that would
never trigger, so don't do that anymore!

Fixes #10806.

(cherry-picked from commit b7dc30ca24)

(cherry picked from commit 58f2586b44)
2024-09-12 15:15:08 -07:00
Frank Praznik
d32189918b wayland: Send exposure events when showing or resizing the window
Clients may rely on this event to signal when they should redraw themselves, so send it when appropriate.

(cherry picked from commit 8fa99993af)
2024-09-10 10:22:45 -04:00
Simon McVittie
38d3b1b6d6 x11vulkan: Use the correct SONAME of libX11-xcb.so.1 on Linux, etc.
On most Unix platforms supported by SDL, the canonical name used to load
a library at runtime includes its ABI major version, and the name
without a version is not guaranteed to exist on non-developer systems.
libX11-xcb.so.1 is correct on Linux, and probably on other Unix
platforms like FreeBSD.

A notable exception is OpenBSD, which apparently does not use
ABI-suffixed names, so continue to use libX11-xcb.so there.

Signed-off-by: Simon McVittie <smcv@collabora.com>
(cherry picked from commit 7713a7eec7)
(cherry picked from commit 54757c29dd)
2024-09-09 12:54:20 -07:00
vanfanel
1df907b1ba Add SDL_VIDEO_DOUBLE_BUFFER support to the Wayland backend.
(cherry picked from commit 9e6b8d56e3)
2024-09-08 07:30:22 -07:00