Commit Graph

1996 Commits

Author SHA1 Message Date
Max Seidenstücker
0c121ad6a7 conditional expression is constant
MSVC: C4127: conditional expression is constant
2026-02-08 09:38:35 -08:00
Max Seidenstücker
d063cb01e9 variable conditionally uninitialized
currentX and currentY in L2263-L2264 are marked as conditionally uninitialized by MSVC and Clang

Clang: variable may be uninitialized when used here [-Wconditional-uninitialized]
2026-02-08 09:35:07 -08:00
RaceTheMaSe
7c7ffb9115 tests: Fix unreachable code warnings (#14993) 2026-02-07 20:42:59 +03:00
RaceTheMaSe
4f183506f6 Fix warning: strict prototypes (#14992)
clang: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes]
2026-02-07 07:38:59 -08:00
Max Seidenstücker
d870911202 CodeSpell 2026-02-07 18:14:00 +03:00
Max Seidenstücker
8b53b77058 annotate no return
Clang: function could be declared with attribute 'noreturn' [-Wmissing-noreturn]
2026-02-07 18:10:02 +03:00
Max Seidenstücker
0c7d4d5a89 Static at beginning
GCC: 'static' is not at beginning of declaration [-Wold-style-declaration]
2026-02-07 18:05:39 +03:00
Jesse Chounard
cb0c7b01e4 tray: removed double click handling 2026-02-05 11:08:05 -08:00
Jesse Chounard
bc16157c9d testtray: created VS project and added new click callbacks 2026-02-05 11:08:05 -08:00
Anonymous Maarten
28ea4a8e31 surface: verify surface palette in SDL_Save(BMP|PNG) before hitting the FS 2026-02-03 09:31:57 -08:00
Sam Lantinga
de605a3b7e Reverted unintended testsprite changes 2026-02-02 16:00:49 -08:00
Sam Lantinga
cdffbdfeaf Fixed handling GameCube adapters in PC mode on Linux and macOS
On Windows there is a separate HIDAPI device for each slot. On Linux and macOS, there is a single HIDAPI device and the slot is included in the report.
2026-02-02 15:44:44 -08:00
Anonymous Maarten
5072b3d252 sdlprocdump: print name of module throwing exceptions 2026-02-02 00:59:20 +01:00
Anonymous Maarten
61ac7314b0 sdlprocdump: add ARRAY_SIZE macro 2026-02-02 00:06:23 +01:00
Aaron Benjamin
9a91d7236a GPU: OpenXR integration (#14837)
Based on Beyley's initial draft in #11601.

Co-authored-by: Beyley Cardellio <ep1cm1n10n123@gmail.com>
Co-authored-by: Ethan Lee <flibitijibibo@gmail.com>
2026-01-30 17:18:51 -05:00
Sam Lantinga
ee38b7c3df Fixed memory leak in testffmpeg EGL codepath
Fixes https://github.com/libsdl-org/SDL/issues/14908
2026-01-28 08:20:44 -08:00
Frank Praznik
32747ceb84 tests: Don't try to load unsupported image types in testclipboard
Requesting certain MIME types (e.g. EPS formats offered by KDE) can be *very* slow, on the order of multiple seconds, due to requiring significant processing. Only try to load image MIME types that SDL is known to support (BMP and PNG).
2026-01-14 11:00:50 -05:00
Sam Lantinga
5f086e7623 Updated copyright for 2026 2026-01-01 09:40:08 -08:00
Anonymous Maarten
bf113bbe2a cmake: break dependency cycle when doing an in-source build 2025-12-24 22:18:57 +01:00
Anonymous Maarten
9dd3e2305e dlnote: embed trailing semicolon in SDL_ELF_NOTE_DLOPEN macro 2025-12-24 23:45:50 +03:00
Anonymous Maarten
e79cfbe520 testcustomcursor: plug memory leak 2025-12-22 22:43:05 +01:00
Anonymous Maarten
2cd84bd581 testcustomcursor: add --frames argument accepting multiple paths 2025-12-22 22:43:05 +01:00
Frank Praznik
7fe81f789f tests: Add clipboard clearing functionality to testclipboard
Use Alt+C/P to clear the clipboard/primary selection in testclipboard.
2025-12-22 13:29:28 -05:00
Sam Lantinga
64df9cfa47 testmessage: quit if we get a mouse click 2025-12-15 08:56:11 -08:00
Anonymous Maarten
a296c40867 isfinite is not available on all platforms, so add a bitmasking alternative
Compiler Explorer shows both result in the same assembly.
2025-12-08 20:48:47 +01:00
Anonymous Maarten
f896e26f59 tests: find X11 and wayland-client 2025-12-08 20:48:47 +01:00
Ryan C. Gordon
6f774908fe audio: SDL_GetAudioDeviceName() now works with the default device IDs.
Fixes #14615.
2025-12-08 11:25:15 -05:00
Ryan C. Gordon
4194879df1 surface: Surface rotation property should be float, not int.
Adjusted camera internals to work in floats, too.

Reference Issue #14616.
2025-12-07 22:25:08 -05:00
Ryan C. Gordon
2c11d62d17 camera: Report rotation needed to account for device orientation.
Fixes #11476.
2025-12-06 13:51:10 -05:00
Sam Lantinga
27744952d1 testyuv: respect the --renderer parameter with --all
Also fixed a memory leak at shutdown
2025-12-05 08:46:58 -08:00
Anonymous Maarten
0e96cbd8ce tests: build tests with C99 standard by default 2025-12-05 08:30:52 -08:00
Sam Lantinga
5c7d549267 testyuv: added comprehensive testing of YUV texture rendering
This tests all supported colorspaces and YUV formats across all available renderers
2025-12-05 08:30:52 -08:00
Sam Lantinga
e41bdfafe4 testyuv: allow loading BMP files 2025-12-05 08:30:52 -08:00
Sam Lantinga
fc8d725367 testyuv: fixed crash if the test file couldn't be loaded 2025-12-05 08:30:52 -08:00
Sam Lantinga
03c932b9a7 testclipboard: load any image format supported by SDL 2025-12-05 08:30:52 -08:00
Anonymous Maarten
ccdc9231f5 test: allow GNU extensions 2025-12-04 19:22:19 +01:00
Anonymous Maarten
7b74fbb73f test: build testver in with the C90 standard
By building at least one test in C90 mode, we make sure the SDL headers are C90 compatible.
2025-12-04 18:50:19 +01:00
Sam Lantinga
b5dd0ee07b Relax the requirement that test programs be C90 compliant
Fixes https://github.com/libsdl-org/SDL/issues/14588
2025-12-04 07:30:28 -08:00
Simon McVittie
65ef4df6d4 testver: Assert that SDL_GetRevision() starts with SDL-
https://github.com/libsdl-org/SDL/issues/14575

Signed-off-by: Simon McVittie <smcv@collabora.com>
2025-12-03 08:48:48 -08:00
Ryan C. Gordon
505cd6cd22 testautomation_video: Don't do fullscreen toggling tests on Emscripten.
SDL_SetWindowFullscreen now reports failure while a fullscreen transition is
already in progress on Emscripten, upsetting the test when it tries to come
back to windowed mode, but testautomation will never give correct results here
even when we fix the backend to queue pending reversal requests, because
you'll have to return to the Emscripten mainloop before these state changes
will occur.

It's just sort of luck this specific test passed before on this target.
2025-12-02 14:36:27 -05:00
Sam Lantinga
ea1514ab63 testthread: verify that child threads aren't SDL_IsMainThread() 2025-11-30 12:15:48 -08:00
Sam Lantinga
955698c635 testthread: SDL performs thread initialization automatically 2025-11-30 12:15:48 -08:00
Anonymous Maarten
e221905195 Fix check_stdlib_usage.py libc call matching
It now matches libc usage inside statements,
and skips libc-like usage in strings or as struct members.
2025-11-25 01:07:10 +01:00
Sam Lantinga
ebd3aa5289 testgpu_spinning_cube: fixed error handling if texture creation fails 2025-11-24 08:31:38 -08:00
Sam Lantinga
ba919832e4 testgpu_spinning_cube: removed duplicate calls to clear and present 2025-11-24 08:24:43 -08:00
Anonymous Maarten
ce5e46c37d Add SDL_(Get|Set)iSurfaceClipRect automation test
Co-authored-by: Sam Lantinga <slouken@libsdl.org>
(cherry picked from commit a65111bd2d)
2025-11-24 00:02:36 +01:00
Ryan C. Gordon
99d7dad7e6 pen: Dramatic improvements to proximity information.
Now everything will attempt to track pens through proximity changes (instead
of removing the pen entirely). testpen.c has been updated to reflect this.

Some platforms and devices are better at this than others, but this seems like
a significant usability improvement across the board.

Fixes #12992.
2025-11-21 08:13:16 -05:00
eafton
36976ecb43 X11TK: Introduce Thai support and rewrite/cleanup messagebox positioning code (#14474) 2025-11-20 15:26:46 -08:00
Sam Lantinga
1e5cbbc1d0 checkkeys: clarify that SDL_HINT_WINDOWS_RAW_KEYBOARD isn't needed 2025-11-19 08:54:43 -08:00
Anonymous Maarten
8f21fe4994 testmouse: avoid use-after-free
Bug was introduced in 17a891daa8
2025-11-18 08:35:56 +01:00