Sam Lantinga
a864dcac25
Added support for using the GPU renderer as an offscreen renderer
...
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
SDL_CreateGPURenderer() now allows passing in an existing GPU device and passing in a NULL window to create an offscreen renderer.
Also renamed SDL_SetRenderGPUState() to SDL_SetGPURenderState().
2025-10-01 23:32:18 -07:00
Frank Praznik
9461db1ec8
Fix typo
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-10-01 19:21:10 -04:00
Frank Praznik
9182b8ab61
wayland: Add a fallback for xkb_keymap_key_get_syms_by_level() for old xkbcommon versions
...
This function is only available since version 1.0.0, but the SDL minimum is 0.5.0, and Steam Runtime 2 'soldier' uses 0.8.2, so add a fallback function with similar functionality for older versions.
xkb_keymap_key_get_mods_for_level() is more efficient, so it is still favored when available.
2025-10-01 17:59:07 -04:00
Sam Lantinga
8d7cd3c6c2
Fixed line endings
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-10-01 14:01:59 -07:00
Sam Lantinga
33c849d030
Always enable object validation when checking is explicitly enabled
2025-10-01 13:53:19 -07:00
Sam Lantinga
f66e4d0a43
Enable full object validation by default
...
Full object validation was always done before this hint and there are a number of shipping products that relied on this, so don't change it by default.
2025-10-01 12:46:33 -07:00
Mathieu Eyraud
86da08b0be
Zero-initialize SDL_GPUDevice
2025-10-01 07:22:17 -07:00
Mathieu Eyraud
409bb7722c
Fix uninitialized variables
2025-10-01 07:21:44 -07:00
Sam Lantinga
9735c45db6
Added an advanced shader for the GPU renderer
...
This allows us to support YUV colorspaces and HDR in the GPU renderer.
Fixes https://github.com/libsdl-org/SDL/issues/11281
Fixes https://github.com/libsdl-org/SDL/issues/11282
2025-10-01 07:17:55 -07:00
Sam Lantinga
fe3b399b7e
Added support for P010 pixel format in SDL_UpdateNVTexture()
2025-10-01 07:17:55 -07:00
Sam Lantinga
548063e578
Fixed pixel shader for palettized textures using pixelart scaling
2025-10-01 07:17:55 -07:00
Sam Lantinga
224b4917a3
testpalette: added a --renderer command line option
2025-10-01 07:17:55 -07:00
Frank Praznik
b54c5fd79c
x11: Check for a valid input context before destroying it
...
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
XDestroyIC crashes if passed a null parameter.
2025-09-30 14:48:39 -04:00
Sam Lantinga
8a5f9a3837
Removed validate_feature_indirect_draw_first_instance_disabled (thanks @rabbit-ecl!)
...
It was incorrectly checking the direct draw functions instead of checking indirect draw buffers.
2025-09-30 11:36:29 -07:00
Anonymous Maarten
fd4c2f8cfd
ci: build testffmpeg on MinGW (msys2) build bots
2025-09-30 17:42:11 +02:00
eafton
76308181b9
Fix #14072
2025-09-30 08:41:23 -07:00
Simon McVittie
c81b4e8493
test: Space-separate arguments in as-installed tests' .test files
...
The "as-installed" tests have metadata files in the .desktop-like format
used by gnome-desktop-testing, which uses a subset of shell syntax for
the Exec field. The list of arguments is represented as a
semicolon-separated list by CMake, but we need to convert that into a
space-separated list for the Exec field.
Strictly speaking we should be quoting the arguments with the equivalent
of Python's shlex.quote, but I couldn't find a way to do that in CMake,
and currently none of the tests have arguments that need quoting.
Signed-off-by: Simon McVittie <smcv@collabora.com >
2025-09-30 15:58:49 +02:00
Anonymous Maarten
30c2cda25e
Don't use assert(0) for SDL_TriggerBreak
...
The assert macro is disabled when building with -DNDEBUG.
On Android, the debugger stopped in the wrong frame.
2025-09-30 15:45:26 +02:00
Wohlstand
e3d65796f4
SDL_render_psp.c: Implemented working viewport support
...
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
Backported from the SDL2 branch
2025-09-29 19:09:26 -07:00
Sam Lantinga
baed512453
Fixed building tests on visionOS
2025-09-29 13:28:00 -07:00
Sam Lantinga
15f1cb4c98
Added GPU API support on visionOS
...
You must set SDL_PROP_GPU_DEVICE_CREATE_FEATURE_DEPTH_CLAMPING_BOOLEAN to false on this platform, since setDepthClipMode is not supported on Apple headsets (as of visionOS 2.3) and clipping is the default.
2025-09-29 13:28:00 -07:00
Sam Lantinga
2809ce9389
Set enable_depth_clip to true by default if SDL_PROP_GPU_DEVICE_CREATE_FEATURE_DEPTH_CLAMPING_BOOLEAN is false
2025-09-29 13:28:00 -07:00
SDL Wiki Bot
da6fa5e65f
Sync SDL3 wiki -> header
...
[ci skip]
2025-09-29 19:44:11 +00:00
Sam Lantinga
f61e271e11
Generalize and validate optional GPU feature properties
...
Fixes https://github.com/libsdl-org/SDL/issues/13139
Fixes https://github.com/libsdl-org/SDL/issues/13138
2025-09-29 12:42:47 -07:00
Sam Lantinga
37410908c7
Fixed building on visionOS
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-09-29 12:17:48 -07:00
Sam Lantinga
595f7b7ed9
Revert "Fixed Vulkan validation error"
...
This reverts commit b82b1f416f .
The renderer should not be enabling depth clamping.
2025-09-29 06:08:27 -07:00
Ozkan Sezer
5fffa8b9ad
SDL_video_unsupported.c: fix SDL_iOSAnimationCallback type redefinition error
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-09-29 08:41:14 +03:00
SDL Wiki Bot
1d7e70833b
Sync SDL3 wiki -> header
...
[ci skip]
2025-09-29 05:11:33 +00:00
Sam Lantinga
b65590159b
Each application palette corresponds to one hardware palette
...
When the application modifies the palette, any textures that use it will automatically be updated.
2025-09-28 22:10:06 -07:00
Sam Lantinga
5d311635cf
Added Vulkan support for palettized textures
2025-09-28 22:10:06 -07:00
Sam Lantinga
e2fe23ddab
Added hardware accelerated support for palettized textures
...
Supported backends: direct3d, direct3d11, direct3d12, gpu, metal, opengl, opengles2
2025-09-28 22:10:06 -07:00
Sam Lantinga
b82b1f416f
Fixed Vulkan validation error
...
VUID-VkPipelineRasterizationStateCreateInfo-depthClampEnable-00782(ERROR / SPEC): msgNum: -316906200 - Validation Error: [ VUID-VkPipelineRasterizationStateCreateInfo-depthClampEnable-00782 ] | MessageID = 0xed1c6528 | vkCreateGraphicsPipelines(): pCreateInfos[0].pRasterizationState->depthClampEnable is VK_TRUE, but the depthClamp feature was not enabled. The Vulkan spec states: If the depthClamp feature is not enabled, depthClampEnable must be VK_FALSE (https://vulkan.lunarg.com/doc/view/1.3.268.0/windows/1.3-extensions/vkspec.html#VUID-VkPipelineRasterizationStateCreateInfo-depthClampEnable-00782 )
2025-09-28 22:10:06 -07:00
Sam Lantinga
524ba0a4ad
Reduce the size of the D3D12 vertex shader constants
...
This is needed to add more fragment shader constants in the future as we're already at our 64 size limit
2025-09-28 22:10:06 -07:00
Sam Lantinga
5622eef5a8
Fixed memory leak if requested renderer isn't available
2025-09-28 22:10:06 -07:00
Sam Lantinga
2a01e12d34
Simplify palette code
...
Each texture gets its own palette, the palette is updated when it is rendered if necessary, rendering is flushed if a texture render is already queued up.
Trying to share palettes and handle the different cases of queued rendering and changing palettes in the middle of the frame ends up being very complicated, so we'll keep it simple for now.
2025-09-28 22:10:06 -07:00
Sam Lantinga
7dcc09986d
Test changing the palette for a single texture
2025-09-28 22:10:06 -07:00
Sam Lantinga
264b436dba
Fixed changing palettes while rendering is in flight
2025-09-28 22:10:06 -07:00
Sam Lantinga
0b4b254a53
Added support for textures with palettes
...
Closes https://github.com/libsdl-org/SDL/pull/6192
2025-09-28 22:10:06 -07:00
mccakit
d42bf59c66
wasm64 lto fix
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-09-28 19:33:48 -04:00
Victor Ilyushchenko
a34d31322c
Fix Metal 3D texture upload stride calculation
...
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
Signed-off-by: Victor Ilyushchenko <alt13ri@gmail.com >
2025-09-28 07:32:17 -07:00
Sam Lantinga
da84d78796
Fixed unknown frees being reported when SDL is built without allocation counts
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-09-27 23:47:09 -07:00
Ryan C. Gordon
a1672f2d2f
docs: Fix param call on SDL_SetEventFilter.
...
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
https://wiki.libsdl.org/SDL3/README-documentation-rules#dont-repeat-type-names-in-param-and-returns-sections
2025-09-27 13:55:31 -04:00
Ryan C. Gordon
2676f23910
audio: fix crash in SDL_GetAudioStreamOutputChannelMap.
...
Fixes #14058 .
2025-09-27 13:31:29 -04:00
ProgramGamer
2c8c2d72b5
Allow in-memory IOStreams to be of length 0 ( #13840 )
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-09-27 09:36:30 -07:00
mccakit
26f961ab05
wasm64 fix
2025-09-27 11:41:31 -04:00
Frank Praznik
191f46dd36
wayland: Rename some callbacks to be closer to their canonical Wayland names
...
The old names made it difficult for people searching or otherwise trying to understand the codebase, as they were somewhat mangled from their expected names (e.g. configure_toplevel_xdg vs xdg_toplevel_configure, the latter of which would be expected by someone reading the spec).
2025-09-27 10:59:52 -04:00
Anonymous Maarten
9f721e8a9c
Add test that verifies all SDL3 symbols are available
Build (All) / Create test plan (push) Has been cancelled
Build (All) / level1 (push) Has been cancelled
Build (All) / level2 (push) Has been cancelled
2025-09-26 21:42:04 +02:00
Anonymous Maarten
4718000dba
Add JNI_OnLoad to dynamic API
2025-09-26 21:42:04 +02:00
Anonymous Maarten
cdc4609993
Add headers for unsupported sources
2025-09-26 21:42:04 +02:00
Anonymous Maarten
f9f172cf60
gamepad: use SDL_PLATFORM_ANDROID macro instead of ANDROID
2025-09-26 21:39:06 +02:00