Commit Graph

187 Commits

Author SHA1 Message Date
Anonymous Maarten
53aaf8c26b cmake: custom generate-XXX targets must depend on outputs 2025-01-04 00:19:45 +01:00
Sam Lantinga
f18e023317 Added testclipboard 2024-12-31 19:27:11 -08:00
Anonymous Maarten
543f244965 tests: include SDL_build_config.h when HAVE_BUILD_CONFIG is defined 2024-12-29 20:08:06 +01:00
Anonymous Maarten
f1232de3d2 cmake: add_dependencies must have at least 2 arguments 2024-12-28 02:43:12 +01:00
Anonymous Maarten
2664d36faf cmake: avoid parallel generation of headers through intermediate target
See
https://cmake.org/cmake/help/latest/command/add_custom_command.html#example-generating-files-for-multiple-targets
2024-12-28 02:39:12 +01:00
Sam Lantinga
75a24116b5 testcontroller: show gamepad connection state 2024-12-27 13:58:49 -08:00
Semphriss
01b9b0edb7 Add system tray support (#10873) 2024-12-24 10:36:39 -08:00
Ryan C. Gordon
e79ce2a200 asyncio: Added async i/o APIs. 2024-12-03 17:32:20 -05:00
Wouter Wijsman
780578cd36 PSP: Allow building tests in parallel 2024-11-01 08:57:09 -04:00
Cameron Cawley
94c8c170eb 3DS: Only bundle resources with tests that need them 2024-10-12 13:59:00 -07:00
Anonymous Maarten
7241dd9ec3 Add more SDL_Process tests 2024-09-30 03:03:33 +02:00
Simon McVittie
80da805688 build: Fix testprocess invocation during "as-installed" tests
During build-time testing, we can use `$<TARGET_FILE:childprocess>` to
pass the just-built childprocess executable to it as an argument, but
during "as-installed" testing we need to use the installed path of
the childprocess executable instead.

Signed-off-by: Simon McVittie <smcv@debian.org>
2024-09-25 14:48:26 -07:00
Semphris
9eea8234e6 Add SDL_Process subsystem 2024-09-13 15:19:32 -07:00
Ryan C. Gordon
154452a726 winrt: Removed WinRT/Windows Phone/UWP support.
Fixes #10724.
2024-09-06 13:28:39 -04:00
Ryan C. Gordon
88125e4d2d test: added testgpu_simple_clear.c, for direct comparison to testvulkan.c. 2024-08-31 20:45:41 -04:00
cosmonaut
2e7d5bb429 Add the SDL_GPU API
Project Lead: Evan Hemsley <evan@moonside.games>

Co-designer, Metal Port, Console Ports:

Co-authored-by: Caleb Cornett <caleb.cornett@outlook.com>

Production, QA, Debug:

Co-authored-by: Ethan Lee <flibitijibibo@gmail.com>

SDL_Render Driver, Bugfixes:

Co-authored-by: Andrei Alexeyev <akari@taisei-project.org>

Additional D3D12 Programming, Bugfixes:

Co-authored-by: Bart van der Werf <bluelive@gmail.com>

Bugfixes and Feedback:

Co-authored-by: Zakary Strange <zakarystrange@gmail.com>
Co-authored-by: meyraud705 <meyraud705@gmail.com>
Co-authored-by: Joshua T. Fisher <playmer@gmail.com>
Co-authored-by: Topi Ritala <ritalat@fastmail.com>
Co-authored-by: David Gow <david@ingeniumdigital.com>

Original API Proposal:

Co-authored-by: Ryan C. Gordon <icculus@icculus.org>
2024-08-29 15:57:29 -07:00
Anonymous Maarten
c298d2024a Include SDL_build_config.h without a 'build_config/' prefix 2024-08-23 00:51:35 +00:00
Sam Lantinga
8f546bb3c9 Use C99 bool internally in SDL 2024-08-22 13:30:02 -07:00
Anonymous Maarten
9eac3a434e ctest/emscripten: make audio and video driver configurable 2024-08-21 20:14:55 +02:00
Anonymous Maarten
08661166e9 ci: verify SDL_REVISION 2024-08-20 16:04:58 +00:00
Anonymous Maarten
161761653f test: use Selenium to run Emscripten tests 2024-08-20 16:04:58 +00:00
Anonymous Maarten
46bafda7ab testshader: add -sLEGACY_GL_EMULATION for emscripten 2024-08-20 16:04:58 +00:00
Anonymous Maarten
6052136ced tests/emscripten: add link-time dependency on the resources 2024-08-20 16:04:58 +00:00
Anonymous Maarten
35b61f70da sdlprocdump: add option to print debug stream 2024-08-11 21:00:08 +02:00
Anonymous Maarten
a1c6f99877 android: add script in Android archive to create a SDK
Also,
- Move mingw's pkg-support into build-scripts
- Add type annotations to python scripts for mypy
- ci: use v4 tag of actions/cache
- cmake: use PYTHON3_EXECUTABLE for running xxd.py
  (Python3::Interpreter is not always recognized.)
2024-08-01 05:07:08 +02:00
Anonymous Maarten
b68ac011e0 ctest: fail if there are outstanding allocations 2024-07-30 20:56:19 +00:00
David Gow
540a356199 test: Add testspritesurface
This is a cut-down version of testsprite which uses SDL_Surface (and
SDL_GetWindowSurface), instead of the Render API. It's useful for
quickly validating that blitting works, including some basic format
conversion (with a palette).

Signed-off-by: David Gow <david@ingeniumdigital.com>
2024-07-11 08:11:29 -07:00
Anonymous Maarten
18c9bd21b5 sdlprocdump: become C90 compatible 2024-07-07 21:18:16 +02:00
Sam Lantinga
50f50612bd Removed checkkeysthreads
It's out of date relative to the IME changes and doesn't add any value
2024-06-27 17:43:03 -07:00
Anonymous Maarten
0f27686a51 tests: run tests under a minimal debugger that can create minidumps
Tests on ci are run using this dumper, and will upload the minidumps.
2024-06-21 12:39:11 +02:00
Ryan C. Gordon
38f0214e8a audio: Refer to audio devices to "playback" and "recording".
Fixes #9619.
2024-06-15 01:08:12 -04:00
Anonymous Maarten
fefa47e409 dropfile: main callbacks need extra CMake care on UWP 2024-05-25 16:35:11 +02:00
Anonymous Maarten
9aff68746f cmake: add khronos include directories with PRIVATE visibility 2024-05-07 17:37:21 +02:00
Semphris
c6a70d6898 Add support for modal windows to more platforms
- Adds support for modal windows to Win32, Mac, and Haiku, and enhances functionality on Wayland and X11, which previous set only the parent window, but not the modal state.
- Windows can be declared modal at creation time, and the modal state can be toggled at any time via SDL_SetWindowModalFor() (tested with UE5 through sdl2-compat).
- Allows dynamic unparenting/reparenting of windows.
- Includes a modal window test.
2024-04-30 13:47:57 -04:00
Anonymous Maarten
911fc9b17e testffmpeg: treat Khronos headers as system headers 2024-04-18 09:10:15 -07:00
Ravbug
2d640d0b59 ci: Add iOS and tvOS CMake GitHub Actions checks (#9465)
- Also add watchos support to CMake (SDL does not support this platform yet)

Co-authored-by: Ravbug <ravbug@users.noreply.github.com>
Co-authored-by: Anonymous Maarten <anonymous.maarten@gmail.com>
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
2024-04-08 19:18:28 +02:00
Sam Lantinga
8847b35244 Separate joystick power state into battery status and percentage
This allows you to see battery percentage while the controller is charging
2024-04-01 13:59:00 -07:00
Anonymous Maarten
72cf9c0ef4 test: don't run testautomation in parallel 2024-03-29 21:11:35 +01:00
Anonymous Maarten
89b135e570 cmake: add automation and platform test without simd 2024-03-23 16:36:44 -07:00
Sam Lantinga
6604d423fd Added a test program for multiple mice 2024-03-23 16:31:00 -07:00
Anonymous Maarten
75a71bde4b cmake: build tests against installed SDL prefix 2024-03-23 21:41:20 +01:00
Anonymous Maarten
7f888f98f7 gles2: only build tests when building SDL3 or when the headers are available 2024-03-23 21:41:20 +01:00
Frank Praznik
a6fbf0488c Add time and realtime clock functions
Adds functions to query the system's realtime clock, convert time intervals to/from a calendar date and time in either UTC or the local time, and perform time related calculations.

An SDL_Time type (a time interval represented in nanoseconds), and SDL_DateTime struct (broken down calendar date and time) were added to facilitate this functionality.

Querying the system time results in a value expressed in nanoseconds since the Unix epoch (Jan 1, 1970) in UTC +0000. Conversions to and from the various platform epochs and units are performed when required.

Any direct handling of timezones and DST were intentionally avoided. The offset from UTC is provided when converting from UTC to a local time by calculating the difference between the original UTC and the resulting local time, but no other timezone or DST information is used.

The preferred date formatting and 12/24 hour time for the system locale can be retrieved via global preferences.

Helper functions for obtaining the day of week or day or year for calendar date, and getting the number of days in a month in a given year are provided for convenience. These are simple, but useful for performing various time related calculations.

An automated test for time conversion is included, as is a simple standalone test to display the current system date and time onscreen along with a calendar, the rendering of which demonstrates the use of the utility functions (press up/down to increment or decrement the current month, and keys 1-5 to change the date and time formats).
2024-03-19 10:57:36 -07:00
Semphris
70c2e15615 Add file dialogs 2024-03-14 15:40:25 -07:00
Sam Lantinga
fcb132b8e8 Allow building testffmpeg without Vulkan support 2024-03-08 16:45:27 -08:00
Sam Lantinga
dbec2150d0 testffmpeg: added support for Vulkan rendering 2024-03-04 09:29:36 -08:00
Anonymous Maarten
0a961915dc cmake: testffmpeg requires link to EGL library for EGL feature 2024-02-27 12:28:06 +01:00
Ryan C. Gordon
b1ed49772c camera: Replace testcamera.c with testcameraminimal.c 2024-02-20 15:56:26 -05:00
Ryan C. Gordon
0b8617f71d test: Fixed CMake to build testcameraminimal correctly on WinRT. 2024-02-20 15:56:26 -05:00
Ryan C. Gordon
7ae955ce68 camera: Renamed everything from "video capture" to "camera", wired to CMake. 2024-02-20 15:56:26 -05:00