Sam Lantinga
d5fe6dd627
Don't use const for non-pointer API parameters
2024-10-02 09:17:31 -04:00
Sam Lantinga
91b074beb7
Removed SDL_IPHONE_MAX_GFORCE
...
We no longer support interpreting the accelerometer as a joystick.
Fixes https://github.com/libsdl-org/SDL/issues/11005
2024-10-01 18:00:22 -07:00
SDL Wiki Bot
34033d5838
Sync SDL3 wiki -> header
2024-10-01 18:45:52 +00:00
Sam Lantinga
eced9f58a9
Added a userdata parameter for EGL attribute callbacks
...
Fixes https://github.com/libsdl-org/SDL/issues/11013
2024-10-01 11:45:19 -07:00
SDL Wiki Bot
798c9574d0
Sync SDL3 wiki -> header
2024-10-01 17:46:16 +00:00
Sam Lantinga
89e68aa801
Added missing return value documentation for bsearch()
2024-10-01 10:45:32 -07:00
Sam Lantinga
4fa92d233d
Include stdbool.h when using Visual Studio 2017+
...
Also cleaned up some incorrect return values from bool functions.
2024-10-01 09:57:59 -07:00
Anthony
5f5379dc99
Add `SDL_IsTV()` ( #11004 )
...
Moved SDL_IsAndroidTV() out of public API, to match SDL_IsAndroidTablet().
Added SDL_IsTV(), to mirror existing SDL_IsTablet().
2024-10-01 09:20:00 -07:00
SDL Wiki Bot
6bcf2f919a
Sync SDL3 wiki -> header
2024-10-01 16:16:44 +00:00
Ryan C. Gordon
0b5e01a305
loadso: library handles are now `SDL_SharedObject*` instead of `void*`.
...
Improved the SDL_loadso.h documentation a little, too.
Fixes #11009 .
2024-10-01 12:16:10 -04:00
SDL Wiki Bot
f351395c46
Sync SDL3 wiki -> header
2024-10-01 15:10:40 +00:00
Sam Lantinga
3234a3b902
Simplified internal SDL_Surface structure
2024-10-01 08:10:04 -07:00
Sam Lantinga
1f3a0d12e6
Made texture size and format public in the API
...
Also added refcount to textures so they can be retained by application code.
2024-10-01 08:10:04 -07:00
Ryan C. Gordon
b4fcd1f345
pen: Corrected some documentation.
...
Fixes #10863 .
2024-10-01 10:24:17 -04:00
Sam Lantinga
e3dbd74fe7
Improved documentation for SDL_Surface fields
2024-09-30 21:34:00 -07:00
SDL Wiki Bot
c16d7c87d6
Sync SDL3 wiki -> header
2024-09-30 18:18:49 +00:00
Sam Lantinga
ab832f1be0
Added documentation for qsort and bsearch functions
2024-09-30 11:18:17 -07:00
SDL Wiki Bot
dcc7560a5c
Sync SDL3 wiki -> header
2024-09-30 17:23:50 +00:00
Evan Hemsley
afdf325fb4
GPU: Add swapchain dimension out params ( #11003 )
2024-09-30 10:23:19 -07:00
Ryan C. Gordon
1787d6ca5c
main: SDL_AppQuit() now reports the result value.
...
Fixes #10994 .
2024-09-29 23:24:04 -04:00
SDL Wiki Bot
62938837c2
Sync SDL3 wiki -> header
2024-09-29 01:10:39 +00:00
Evan Hemsley
fc242abbd2
GPU: recreate swapchain on window pixel size change event ( #10985 )
2024-09-28 18:09:56 -07:00
Sam Lantinga
a923771978
Added SDL_murmur3_32()
2024-09-28 17:19:01 -07:00
Sam Lantinga
039148fb0e
Updated check for stdbool.h
...
If you're building in a C99 or newer environment, we'll automatically include stdbool.h.
If you're building in a C89 or C90 environment, we'll assume that stdbool.h isn't available and define bool as an unsigned char. If you have a working stdbool.h and want SDL to use it, you can either include stdbool.h before SDL headers, or define SDL_INCLUDE_STDBOOL_H in your project.
Closes https://github.com/libsdl-org/SDL/pull/10980
2024-09-28 16:55:09 -07:00
Petar Popovic
dee62e1b47
Remove trailing comma in enum
2024-09-28 17:47:37 +03:00
Ryan C. Gordon
7d21a49c9c
filesystem: SDL_EnumerateDirectoryCallback uses an enum now, not an int.
...
Fixes #10955 .
2024-09-28 01:33:40 -04:00
SDL Wiki Bot
0542bbbf1a
Sync SDL3 wiki -> header
2024-09-27 22:55:29 +00:00
Ryan C. Gordon
428f2f35be
filesystem: SDL_CreateDirectory should make parent directories.
...
Fixes #10502 .
2024-09-27 18:54:18 -04:00
SDL Wiki Bot
8d6b397cd8
Sync SDL3 wiki -> header
2024-09-27 21:11:58 +00:00
Sam Lantinga
3f446d8fb5
Minor cleanup
2024-09-27 14:10:46 -07:00
SDL Wiki Bot
8377cad974
Sync SDL3 wiki -> header
2024-09-27 20:50:17 +00:00
cosmonaut
c39e8298b7
GPU: Document swapchain dimensions
2024-09-27 13:49:27 -07:00
SDL Wiki Bot
0e5a49542d
Sync SDL3 wiki -> header
2024-09-27 20:39:24 +00:00
David Fort
f32e96f5e2
clipboard: add SDL_ClipboardMimeTypes
...
This function allows to retrieve the available mime types without doing any
synthesizing.
2024-09-27 13:38:40 -07:00
SDL Wiki Bot
0befa7d8e9
Sync SDL3 wiki -> header
2024-09-27 20:27:48 +00:00
cosmonaut
eedd2039f9
GPU: 32-bit component texture formats
2024-09-27 16:26:43 -04:00
SDL Wiki Bot
769ff47461
Sync SDL3 wiki -> header
2024-09-27 19:50:13 +00:00
Evan Hemsley
05d0656bd6
GPU: Simultaneous compute pass read-write ( #10965 )
2024-09-27 12:49:37 -07:00
Caleb Cornett
5ff6e8d522
GPU: Add enable_depth_clip to RasterizerState ( #10964 )
2024-09-27 11:18:54 -05:00
Sam Lantinga
04bb105d09
Added header for SDL_ThreadID type
2024-09-27 08:16:49 -07:00
SDL Wiki Bot
c7442b04f0
Sync SDL3 wiki -> header
2024-09-27 07:30:57 +00:00
Evan Hemsley
be401dd1e3
GPU: More robust error reporting ( #10958 )
...
---------
Co-authored-by: Ethan Lee <flibitijibibo@gmail.com>
Co-authored-by: Caleb Cornett <caleb.cornett@outlook.com>
2024-09-27 00:30:18 -07:00
SDL Wiki Bot
0d593cf39a
Sync SDL3 wiki -> header
2024-09-26 23:29:38 +00:00
Ryan C. Gordon
f267ec7681
filesystem: Improve docs, make some promises about overwrites and file caches.
...
Note that SDL_FlushIO() doesn't make promises about file data sync but that
is intended to be changed in the IOStream code in a later commit.
Fixes #10886 .
2024-09-26 19:29:03 -04:00
SDL Wiki Bot
c1587b1eac
Sync SDL3 wiki -> header
2024-09-26 23:26:52 +00:00
Sam Lantinga
125e592844
Added SDL_ShouldInit() and SDL_ShouldQuit()
...
These are handy functions to support thread-safe initialization and shutdown.
2024-09-26 16:26:12 -07:00
Ryan C. Gordon
4e09e58f62
include: Small clarification on directory enumeration documentation.
2024-09-26 16:39:35 -04:00
Anonymous Maarten
345cae361d
Document mode parameter of SDL_GetRenderLogicalPresentation
2024-09-26 16:12:13 +02:00
SDL Wiki Bot
59d69a3ba3
Sync SDL3 wiki -> header
2024-09-26 04:21:40 +00:00
Sam Lantinga
d9a7da4fac
Optimized SDL_HasEvent() and SDL_HasEvents()
...
Also document the counting behavior of SDL_PEEKEVENT.
Fixes https://github.com/libsdl-org/SDL/issues/6209
2024-09-25 21:20:00 -07:00
SDL Wiki Bot
81644d260f
Sync SDL3 wiki -> header
2024-09-25 20:31:24 +00:00
Ryan C. Gordon
122cd4db2b
include: Added `\threadsafety` notes to all SDL_render.h functions.
2024-09-25 16:30:04 -04:00
SDL Wiki Bot
276969cd58
Sync SDL3 wiki -> header
2024-09-25 20:27:11 +00:00
Ryan C. Gordon
4c48ff51f8
render: SDL_RenderPresent now behaves when a render target is currently set.
...
It'll temporarily unbind it, draw letterboxing if necessary, present, and
then rebind the previous render target.
2024-09-25 16:26:36 -04:00
Ryan C. Gordon
7a6a0becb8
render: Fixed a FIXME for SDL_SetRenderViewport with a negative size.
2024-09-25 16:26:36 -04:00
Ryan C. Gordon
54459def69
render: Remove the logical presentation render target.
...
Now we render directly to the window, scaling as appropriate. This fixes some
concerns the render target introduced, like the quality of the final scaled
output, how to step outside of the logical size temporarily to draw some
things sharply at the native resolution, and loss of sub-pixel precision.
Fixes #8736 .
2024-09-25 16:26:36 -04:00
Petar Popovic
043c876a15
Move default colorspace aliases into enum
2024-09-23 07:37:02 -07:00
Susko3
0478a6ee3b
Move endian pixel format aliases into enum
...
Matches the same thing in `SDL_AudioFormat`.
2024-09-22 16:34:42 -07:00
Sam Lantinga
b0e528cc88
Switched ifdef from negative to positive
2024-09-21 20:12:54 -07:00
Ozkan Sezer
254b36361e
Add SDL_PRILL? format specifiers specifically for long long type.
2024-09-21 23:03:50 +03:00
Sam Lantinga
6f80d47d64
Use hexidecimal code for ±
2024-09-21 10:43:34 -07:00
Petar Popovic
4392233007
Removed tabs from headers
2024-09-21 10:39:53 -07:00
SDL Wiki Bot
1f727b61f3
Sync SDL3 wiki -> header
2024-09-18 21:04:36 +00:00
Sam Lantinga
398dff7c25
Added support for the HORI licensed Steam Controller
2024-09-18 14:08:32 -07:00
Ozkan Sezer
7edf7fad66
fix bool define when SDL_DEFINE_STDBOOL is defined:
...
it should be unsigned.
2024-09-18 12:17:22 -07:00
Ozkan Sezer
ff90570a3c
define SDL_DEFINE_STDBOOL for gcc < 3
2024-09-18 12:17:22 -07:00
Sam Lantinga
ea640894d3
Fixed SDL_DEFINE_STDBOOL logic if __bool_true_false_are_defined is defined
2024-09-18 10:50:52 -07:00
Sam Lantinga
32fd1878a0
Provide a definition of bool if needed for your environment
2024-09-18 10:37:11 -07:00
SDL Wiki Bot
026d3c2306
Sync SDL3 wiki -> header
2024-09-18 15:33:11 +00:00
Sam Lantinga
a90ad3b0e2
Removed SDL_bool in favor of plain bool
...
We require stdbool.h in the build environment, so we might as well use the plain bool type.
If your environment doesn't have stdbool.h, this simple replacement will suffice:
typedef signed char bool;
2024-09-18 08:32:30 -07:00
SDL Wiki Bot
9dd8859240
Sync SDL3 wiki -> header
2024-09-18 15:19:01 +00:00
Sam Lantinga
bd04459cde
Fix typos (thanks @qndel!)
...
Fix typos in comments and in one case in a returned error ("insuffient -> insufficient" fb273eb )
codespell src/ *.cpp *.h *.hpp --ignore-words-list unknwn,thid,algebric,statics,pixelX,pEvents,caf,ptd,parms,pEvent,parm,TextureRS,TE,HDA,LOD,datas,UE,xwindows,IIF
cd src; git checkout \
events/imKStoUCS.* \
hidapi \
joystick/controller_type.c \
joystick/controller_type.h \
joystick/hidapi/steam/controller_constants.h \
joystick/hidapi/steam/controller_structs.h \
libm \
stdlib/SDL_malloc.c \
stdlib/SDL_qsort.c \
stdlib/SDL_strtokr.c \
video/khronos \
video/x11/edid.h \
video/x11/edid-parse.c \
video/x11/xsettings-client.* \
video/yuv2rgb
2024-09-18 08:18:26 -07:00
SDL Wiki Bot
8481d1a12b
Sync SDL3 wiki -> header
2024-09-17 15:54:09 +00:00
Sam Lantinga
d0edf68774
Added Uint32 versions of the atomic functions
2024-09-17 08:53:27 -07:00
Sam Lantinga
8d223b3037
Renamed atomic functions to match SDL 3.0 naming convention
...
This will also allow us to cleanly add atomic operations for other types in the future.
2024-09-17 08:53:27 -07:00
Sam Lantinga
f3e419596b
Removed SDL_INIT_TIMER
...
This is no longer necessary before calling SDL_AddTimer()
2024-09-17 08:53:27 -07:00
Sam Lantinga
231ea07617
Added SDL_LogTrace()
2024-09-17 02:04:54 -07:00
SDL Wiki Bot
926d143966
Sync SDL3 wiki -> header
2024-09-16 20:12:52 +00:00
Sam Lantinga
1bbc897e48
Updated documentation for bool return type
...
Also updated the test CRC functions to return bool.
2024-09-16 13:12:15 -07:00
SDL Wiki Bot
4a2683e2c1
Sync SDL3 wiki -> header
2024-09-16 20:09:54 +00:00
Sam Lantinga
dc639956ba
Improve logging performance and make log priorities thread-safe
...
Fixes https://github.com/libsdl-org/SDL/issues/9679
2024-09-16 13:09:17 -07:00
SDL Wiki Bot
f006d61bd1
Sync SDL3 wiki -> header
2024-09-16 17:57:51 +00:00
SDL Wiki Bot
fd1fcfc951
Sync SDL3 wiki -> header
2024-09-16 17:19:42 +00:00
Caleb Cornett
9416917353
GPU: Rework MSAA ( #10859 )
2024-09-16 12:19:09 -05:00
Caleb Cornett
4f722d372a
GPU: Metal vertex buffer indices should grow upward ( #10837 )
2024-09-15 20:17:43 -05:00
Sam Lantinga
97d40b9218
Removed SDL_CleanupEnvironment()
2024-09-15 10:00:21 -07:00
SDL Wiki Bot
a7f1deae8d
Sync SDL3 wiki -> header
2024-09-15 16:38:38 +00:00
Sam Lantinga
28b94c4758
Re-added SDL_getenv() as a thread-safe getenv() implementation
2024-09-15 09:37:04 -07:00
Sam Lantinga
19243092c6
Renamed SDL_GpuGraphicsPipelineTargetInfo to SDL_GPUGraphicsPipelineTargetInfo
...
Fixes https://github.com/libsdl-org/SDL/issues/10855
2024-09-15 07:46:26 -07:00
Carl Åstholm
1f3fd65c4c
cpuinfo: Rename SDL_GetCPUCount to SDL_GetNumLogicalCPUCores
...
This was the only API that broke the "GetNumThings" convention
used elsewhere, so renaming it helps with consistency.
Adding "logical cores" to the name also makes it a bit
more immediately obvious what the count actually represents.
2024-09-14 19:33:30 -07:00
Maia
e5bd3bbcd6
add missing includes
2024-09-14 14:38:44 -07:00
Sam Lantinga
8569bde053
Fixed typo
2024-09-14 14:35:57 -07:00
SDL Wiki Bot
706aaaf280
Sync SDL3 wiki -> header
2024-09-14 20:23:16 +00:00
Ryan C. Gordon
3bc0347761
Revert "Sync SDL3 wiki -> header"
...
This reverts commit 35427ff9ec .
2024-09-14 16:22:16 -04:00
Ryan C. Gordon
c2e4b14a82
Revert "stdinc: Added missing `\param` to SDL_CreateEnvironment."
...
This reverts commit 919f8d3e2b .
2024-09-14 16:22:09 -04:00
Ryan C. Gordon
11c9975caa
Revert "Sync SDL3 wiki -> header"
...
This reverts commit ba65767afa .
2024-09-14 16:22:00 -04:00
SDL Wiki Bot
ba65767afa
Sync SDL3 wiki -> header
2024-09-14 20:18:20 +00:00
Ryan C. Gordon
919f8d3e2b
stdinc: Added missing `\param` to SDL_CreateEnvironment.
2024-09-14 16:17:29 -04:00
SDL Wiki Bot
35427ff9ec
Sync SDL3 wiki -> header
2024-09-14 20:11:24 +00:00
Sam Lantinga
e97f636590
SDL_PROP_PROCESS_CREATE_ENVIRONMENT_POINTER is an SDL_Environment pointer
2024-09-14 12:27:22 -07:00
Sam Lantinga
e673479449
Removed SDL_WriteProcess()
...
This had the unfortunate side-effect of blocking if you tried to write too much. Instead you can use SDL_GetProcessInput() and handle SDL_IO_STATUS_NOT_READY as needed.
Fixes https://github.com/libsdl-org/SDL/issues/10834
2024-09-14 11:15:50 -07:00
ritalat
f6f49de134
Add convenience functions to get process IOStreams
2024-09-14 10:33:29 -07:00
Sam Lantinga
aa7357a14d
SDL_CreateEnvironment() fills the environment with a non-zero parameter
2024-09-14 10:29:02 -07:00
Sam Lantinga
76c469910e
Added SDL_PROP_PROCESS_CREATE_BACKGROUND_BOOLEAN
2024-09-14 10:29:02 -07:00
Sam Lantinga
90e01040c5
Added thread-safe environment functions
...
Also marked the existing functions as unsafe, as they can cause crashes if used in multi-threaded applications.
As a bonus, since the new functions are hashtable based, hint environment lookups are much faster.
2024-09-13 22:14:54 -07:00
Ethan Lee
16ff7503b7
gpu: Update GPU support queries to better match naming conventions
2024-09-13 23:08:44 -04:00
SDL Wiki Bot
d21c1de651
Sync SDL3 wiki -> header
2024-09-13 22:20:35 +00:00
Semphris
9eea8234e6
Add SDL_Process subsystem
2024-09-13 15:19:32 -07:00
Sam Lantinga
6c83491116
Added SDL_FlushIO()
...
Also added SDL_PROP_IOSTREAM_FILE_DESCRIPTOR_NUMBER and refactored the internal API to be able to create SDL_IOStream objects from native file handles.
2024-09-13 15:19:32 -07:00
Sam Lantinga
93caf1cd21
Fixed typo
2024-09-13 14:59:52 -07:00
SDL Wiki Bot
1c5b063ade
Sync SDL3 wiki -> header
2024-09-13 20:56:16 +00:00
Sam Lantinga
f1d0a71629
Fixed the documentation for SDL_SetError()
2024-09-13 13:54:54 -07:00
SDL Wiki Bot
d483886ec5
Sync SDL3 wiki -> header
2024-09-13 19:32:14 +00:00
Carl Åstholm
7d94bf528d
stdlib: Document SDL_strtox functions
2024-09-13 12:30:58 -07:00
Carl Åstholm
fb82772fb3
stdlib: Rewrite SDL_strtoull impl
2024-09-13 12:30:58 -07:00
Carl Åstholm
4efbe1ca28
stdlib: Assert that signed integers use two's complement arithmetic
2024-09-13 12:30:58 -07:00
Carl Åstholm
fd53b3e112
stdlib: Rewrite SDL_wcstol impl
...
SDL_wcstol should now fully adhere to the libc spec.
2024-09-13 12:30:58 -07:00
Anonymous Maarten
ee65176eec
SDL_test: add SDLTest_LogEscapedString
2024-09-13 20:52:32 +02:00
Ethan Lee
0160e9eac6
gpu: Add SDL_QueryGPUSupport
2024-09-13 13:42:07 -04:00
SDL Wiki Bot
262ffa27e7
Sync SDL3 wiki -> header
2024-09-13 16:30:11 +00:00
Ethan Lee
96e147b2b9
gpu: Rework driver name queries, add GetGPUShaderFormats
2024-09-13 12:29:40 -04:00
Ethan Lee
371cfaf8fe
gpu: Implement support for SDL_GPU_DISABLED
2024-09-13 10:32:12 -04:00
SDL Wiki Bot
d3932b1ba2
Sync SDL3 wiki -> header
2024-09-12 23:03:48 +00:00
Caleb Cornett
a45a2caf49
GPU: Rename VertexBinding to VertexBufferDescription ( #10811 )
2024-09-12 18:02:39 -05:00
Evan Hemsley
66489f91bb
GPU: Cube Arrays ( #10800 )
...
---------
Co-authored-by: Caleb Cornett <caleb.cornett@outlook.com>
2024-09-12 13:41:46 -07:00
SDL Wiki Bot
f8d4c49264
Sync SDL3 wiki -> header
2024-09-12 14:11:07 +00:00
Caleb Cornett
d5e1385c91
Fixed typos in SDL_gpu.h
2024-09-12 09:10:20 -05:00
SDL Wiki Bot
6e2f2428ba
Sync SDL3 wiki -> header
2024-09-12 06:31:07 +00:00
Caleb Cornett
ddd5723e2e
GPU: Remove pitch parameters from indirect draw calls ( #10803 )
2024-09-11 23:30:14 -07:00
Sam Lantinga
b15fab0207
Fixed typo in SDL_dialog.h
2024-09-11 17:35:23 -07:00
cosmonaut
d62e3c3791
Fix SDL_GPUShaderFormat flag values
...
Fixes #10797
2024-09-11 15:40:13 -07:00
Sam Lantinga
77c569496d
SDL_GPUShaderFormat isn't an enum anymore
2024-09-11 09:32:17 -07:00
Sam Lantinga
37c9fb490e
Changed enums to use XXX_COUNT for the count or number of values
...
Fixes https://github.com/libsdl-org/SDL/issues/10763
2024-09-11 09:32:17 -07:00
SDL Wiki Bot
eeb465e2fc
Sync SDL3 wiki -> header
2024-09-11 02:20:48 +00:00
Evan Hemsley
2b8a349b26
Add SDL_BindGPUComputeSamplers ( #10778 )
...
---------
Co-authored-by: Caleb Cornett <caleb.cornett@outlook.com>
2024-09-10 19:20:14 -07:00
Evan Hemsley
0b6f993dea
GPU: Zero-init handling ( #10786 )
2024-09-10 18:17:08 -07:00
Sam Lantinga
817f1b3da8
Revert "Changed SDL_GPU_TEXTUREFORMAT_INVALID to 0"
...
This reverts commit b51c6551d6 .
2024-09-10 09:22:49 -07:00
Sam Lantinga
b51c6551d6
Changed SDL_GPU_TEXTUREFORMAT_INVALID to 0
...
This is more in line with SDL's convention and makes it easier to do zero-based structure initialization.
2024-09-10 08:37:52 -07:00
Sam Lantinga
4eb4370500
SDL_strtoll(), SDL_strtoull(), SDL_lltoa(), and SDL_ulltoa() use long long values
2024-09-09 15:46:26 -07:00
SDL Wiki Bot
68c61ff3a8
Sync SDL3 wiki -> header
2024-09-09 21:01:45 +00:00
Sam Lantinga
6fc6e3dc7e
Use SDL_bool where appropriate in SDL events
...
This involved changing button state from Uint8 to SDL_bool, and made SDL_PRESSED and SDL_RELEASED unnecessary.
Fixes https://github.com/libsdl-org/SDL/issues/10069
2024-09-09 14:00:19 -07:00
SDL Wiki Bot
7d1bbae6b2
Sync SDL3 wiki -> header
2024-09-09 20:51:57 +00:00
Carl Åstholm
af37056c0d
stdinc: Fix typos and reword comments about aliasing
2024-09-09 13:51:16 -07:00
Carl Åstholm
8eb194b6f8
stdinc: Document number parsing APIs
2024-09-09 13:51:16 -07:00
Carl Åstholm
eda459ac49
stdinc: Fix up some printf definitions
2024-09-09 13:51:16 -07:00
Carl Åstholm
d6caf2abe7
Remove SDL_RESTRICT in favor of doc comments
2024-09-09 13:51:16 -07:00
Carl Åstholm
731939fca1
stdinc: Document memcpy APIs
2024-09-09 13:51:16 -07:00
Carl Åstholm
8cea4bd3c9
stdinc: Document memory allocation APIs
2024-09-09 13:51:16 -07:00
Simon McVittie
7713a7eec7
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>
2024-09-09 12:27:54 -07:00
Ryan C. Gordon
412a8244b6
audio: Make system-specific audio format types part of SDL_AudioFormat.
...
This keeps them all in the same place, and merges them into the documentation.
2024-09-09 15:17:18 -04:00
cosmonaut
d3091b9538
Remove SDL_GPUDepthStencilValue struct
2024-09-09 10:55:05 -07:00
Evan Hemsley
668e2f82d2
Add load op and clear color to SDL_BlitGPUTexture ( #10767 )
2024-09-09 10:19:52 -07:00
SDL Wiki Bot
6e885d9619
Sync SDL3 wiki -> header
2024-09-09 06:56:45 +00:00
SDL Wiki Bot
301f3ffa9d
Sync SDL3 wiki -> header
2024-09-09 06:50:28 +00:00
Ryan C. Gordon
050aa4d084
include: Filling in more documentation gaps.
2024-09-09 02:49:43 -04:00
Maia
0da2bd49c8
Remove unused includes. This only removes includes that aren't used at all, not even in comments.
2024-09-08 17:11:23 -07:00
Sam Lantinga
7df1caba7c
Clarified that the contents of new textures aren't defined.
2024-09-08 07:23:17 -07:00
Anonymous Maarten
ac0b1b207f
SDL_hints: fix gpu direct3d11 driver name in documentation
...
This was renamed in b17ca32d8c
2024-09-08 15:56:17 +02:00
SDL Wiki Bot
1ba99c53d4
Sync SDL3 wiki -> header
2024-09-08 04:22:26 +00:00
SDL Wiki Bot
2b77b2e4ef
Sync SDL3 wiki -> header
2024-09-08 04:18:26 +00:00
Ryan C. Gordon
4f6e81cf62
include: Fixed up some minor documentation gaps.
2024-09-08 00:17:53 -04:00
SDL Wiki Bot
7ec998819d
Sync SDL3 wiki -> header
2024-09-07 23:13:46 +00:00
Maia
fd6056307f
fix trailing doc comments
2024-09-07 09:11:13 -07:00
cosmonaut
1a13acac09
Always blit to the swapchain in GPU_RenderPresent
...
Fixes #10744
2024-09-07 08:43:02 -07:00
Maia
fa892d15b7
include files with required types directly
2024-09-07 08:37:46 -07:00
SDL Wiki Bot
e9c7b36fbd
Sync SDL3 wiki -> header
2024-09-07 15:30:40 +00:00
Evan Hemsley
68a9991ec9
GPU: Document structs ( #10742 )
2024-09-07 08:29:14 -07:00
Sam Lantinga
a01e8a5e10
The GPU log category ate one of the SDL reserved categories
...
Fixes https://github.com/libsdl-org/SDL/issues/10739
2024-09-07 07:54:13 -07:00
SDL Wiki Bot
f42da35ef9
Sync SDL3 wiki -> header
2024-09-06 23:39:48 +00:00
Caleb Cornett
9730f62e8c
GPU: Rename struct members and parameters for SDL3 naming conventions ( #10730 )
...
---------
Co-authored-by: Evan Hemsley <2342303+thatcosmonaut@users.noreply.github.com>
2024-09-06 16:38:23 -07:00
Ryan C. Gordon
845855d657
Revert "stdinc: Document more symbols."
...
This reverts commit c93f76436f .
This looked better with the #defines attached to the typedef symbols.
2024-09-06 15:33:27 -04:00
Ryan C. Gordon
c93f76436f
stdinc: Document more symbols.
2024-09-06 15:30:56 -04:00
Ryan C. Gordon
73b294cb1c
SDL_platform_defines.h: Added documentation, and a little whitespace.
...
wikiheaders needs the documentation in the first row of the line, at least
currently, so I've only indented things I could get away with, but it might
be a little easier to follow the preprocessor logic now.
2024-09-06 15:09:29 -04:00
Ryan C. Gordon
ac08dde1b2
windows: Clean out things that should be using `defined(SDL_PLATFORM_WINDOWS)`.
2024-09-06 13:28:39 -04:00
Ryan C. Gordon
154452a726
winrt: Removed WinRT/Windows Phone/UWP support.
...
Fixes #10724 .
2024-09-06 13:28:39 -04:00
Anonymous Maarten
360bc667a8
SDL_Log: restore SDL2's SDL_LogCategory order
2024-09-06 17:40:59 +02:00
Anonymous Maarten
26728c321f
SDL_test: add include for SDLTest_CommonState
2024-09-06 14:23:08 +02:00
Anonymous Maarten
b4c3df1189
SDL_test: whitespace header fixes
2024-09-06 14:19:05 +02:00
Anonymous Maarten
db96ddca34
SDL_test: use SDLCALL calling convention
...
This is needed when using a pre-built static SDL3_test library.
2024-09-06 14:19:05 +02:00
SDL Wiki Bot
e7969553f8
Sync SDL3 wiki -> header
2024-09-06 02:17:29 +00:00
Sam Lantinga
702ed83f72
Initialize interface structures so they can be extended in the future
...
We guarantee that we will only add to the end of these interfaces, and any new fields will be optional.
2024-09-05 19:16:00 -07:00
Anonymous Maarten
102b3b480b
SDL_test: move argument parsing into SDL_test
2024-09-06 03:06:40 +02:00
Anonymous Maarten
09af4a8086
SDL_test: make argument parsing extendable
2024-09-06 03:06:40 +02:00
Anonymous Maarten
872608b8af
Don't allocate in SDLTest_GenerateRunSeed
2024-09-06 03:06:40 +02:00
Anonymous Maarten
2f4b2df595
SDL_test: pass data pointer to unit tests
2024-09-06 03:06:40 +02:00
SDL Wiki Bot
741c04b339
Sync SDL3 wiki -> header
2024-09-05 23:36:17 +00:00
Anonymous Maarten
baa1a5e2f4
Add SDL_strpbrk
2024-09-06 01:35:43 +02:00
Anonymous Maarten
55934bc85e
include: add SDL_RESTRICT for restricted pointer aliasing
2024-09-06 01:35:43 +02:00
Caleb Cornett
2d4eb29c37
Add SDL_SetGPUBlendConstants, SDL_SetGPUStencilReference ( #10704 )
2024-09-05 17:41:23 -05:00
Sam Lantinga
04a732881a
Add a test to verify structure alignment
2024-09-05 15:27:56 -07:00
SDL Wiki Bot
22aeb1bbba
Sync SDL3 wiki -> header
2024-09-05 19:23:35 +00:00
Frank Praznik
a46e7027ce
video: Allow setting the parents of toplevel windows
...
Allow setting a parent/child relationship on toplevel windows, which allows raising sets of windows together, and allows child windows to always float above their parents.
Modal windows are now set by setting the parent, then toggling modal status, as the previous interface duplicated functionality now handled by SDL_SetWindowParent().
2024-09-05 15:22:23 -04:00
SDL Wiki Bot
af4c6682ce
Sync SDL3 wiki -> header
2024-09-05 16:59:20 +00:00
cosmonaut
cba5ccb9cf
GPU: Fix documentation formatting
2024-09-05 09:57:54 -07:00
Evan Hemsley
42a0df91bf
Add padding for non-32-bit-aligned types in structs ( #10701 )
2024-09-05 09:52:57 -07:00
Sam Lantinga
387774ab8a
Build config flags are either defined or undefined, never 0
...
This is for consistency with CMake build configuration
Also added SDL_VIDEO_RENDER_GPU to the non-CMake build configurations
2024-09-05 09:52:40 -07:00
Quinn X. J.
f61d4db39a
GPU: `colorAttachmentDescriptions` should be `const`
...
The `colorAttachmentDescriptions` field of `SDL_GPUGraphicsPipelineAttachmentInfo` should be marked `const`,
similarly to the `vertexBindings` and `vertexAttributes` fields of `SDL_GPUVertexInputState`.
2024-09-05 05:22:52 -07:00
SDL Wiki Bot
249a74e436
Sync SDL3 wiki -> header
2024-09-05 01:25:36 +00:00
Evan Hemsley
1c8c014481
GPU: Document opaque handles and enums ( #10700 )
2024-09-04 18:24:11 -07:00
Evan Hemsley
1788be8547
GPU: Add const to some function parameters ( #10694 )
2024-09-04 13:53:41 -07:00
Ozkan Sezer
f317581c91
SDL_log.h: Use ASCII characters.
...
(was missed in commit 7ca676aeed for issue #10636 )
2024-09-04 14:56:40 +03:00
Sam Lantinga
7ca676aeed
Use ASCII characters in SDL source and headers
...
Fixes https://github.com/libsdl-org/SDL/issues/10636
2024-09-03 12:52:27 -07:00
Sam Lantinga
575d9cda6f
The parameter to SDL_AppEvent() should be non-const
...
This allows functions like SDL_ConvertEventToRenderCoordinates() to work without having to copy the event.
Fixes https://github.com/libsdl-org/SDL/issues/10691
2024-09-03 08:18:36 -07:00
Sam Lantinga
73898a0a64
Renamed NDA platform constants to "PRIVATE"
2024-09-02 21:00:34 -07:00
Caleb Cornett
b233beca47
GPU: Minor documentation cleanup
2024-09-02 18:01:43 -07:00
SDL Wiki Bot
19fb43b94f
Sync SDL3 wiki -> header
2024-09-03 00:19:03 +00:00
Sam Lantinga
46ffa82f4e
Added SDL_ALPHA_OPAQUE_FLOAT and SDL_ALPHA_TRANSPARENT_FLOAT
...
Fixes https://github.com/libsdl-org/SDL/issues/10684
2024-09-02 17:17:48 -07:00
Sam Lantinga
18c46a3313
Fixed SDL_pen.h for SDL3 bit flag conventions
2024-09-02 17:17:48 -07:00
Sam Lantinga
eacf119923
Renamed SDL_size_add_overflow() and SDL_size_mul_overflow()
2024-09-02 17:17:48 -07:00
Andrei Alexeyev
fb7245fb93
GPU: Add support for more texture formats ( #10641 )
2024-09-02 19:14:48 -05:00
Caleb Cornett
f405def691
Change GPU flag enums to defines ( #10681 )
2024-09-02 15:19:43 -07:00
Petar Popovic
1751e127c8
Removed trailing commas in enums
2024-09-01 06:23:20 -07:00
Maia
35ebaf4a45
Fix multiple definitions of SDL_assert* when SDL_WIKI_DOCUMENTATION_SECTION is defined
2024-08-31 20:08:36 -07:00
Petar Popovic
0f59d2f8c9
SDL_test_memory.h: Added void to function prototype
2024-08-31 20:03:25 -07:00
Petar Popovic
d1739ce3a8
Added headers to some SDL_test_*.h files
2024-08-31 11:56:27 -07:00
Sam Lantinga
92d1689eb4
Added missing SDL_begin_code.h and SDL_close_code.h to SDL_gpu.h
2024-08-31 10:02:46 -07:00
Sam Lantinga
60760b9abb
Sort headers in SDL_gpu.h
2024-08-31 10:00:11 -07:00
Petar Popovic
3f05e9cd58
Added includes to SDL_gpu.h
2024-08-31 09:59:17 -07:00
Sam Lantinga
f827c1322c
Renamed SDL_Del* to SDL_Remove*
2024-08-31 07:46:28 -07:00
Sam Lantinga
cf1d8e2dfd
Renamed SDL_AtomicSetPtr() and SDL_AtomicGetPtr()
...
Fixes https://github.com/libsdl-org/SDL/issues/10601
2024-08-31 07:46:28 -07:00
Evan Hemsley
12ecdb9dde
GPU: Rename some awkwardly named functions ( #10642 )
2024-08-30 15:31:10 -07:00
Sam Lantinga
b602c449e5
Remove SDL_SCALEMODE_BEST
...
Fixes https://github.com/libsdl-org/SDL/issues/10619
2024-08-30 10:30:14 -07:00
SDL Wiki Bot
04845bd39c
Sync SDL3 wiki -> header
2024-08-30 13:27:33 +00:00
Sam Lantinga
138f3a3c91
Fixed documentation for SDL_SetAudioStreamGetCallback()
...
Fixes https://github.com/libsdl-org/SDL/issues/10633
2024-08-30 06:26:23 -07:00
Anonymous Maarten
88fe52df7b
SDL_test: add --gpu option
2024-08-30 13:43:38 +02:00
Sam Lantinga
f1b4c2bbbb
Removed Unicode BOM from SDL_gpu.h
2024-08-29 18:03:59 -07:00
SDL Wiki Bot
9f0b23d3ad
Sync SDL3 wiki -> header
2024-08-30 00:35:24 +00:00
Sam Lantinga
d86f504637
Fix potential cases where we define SDL_GPU_* as an undefined symbol
2024-08-29 17:33:52 -07:00
Sam Lantinga
62f6e6b701
Removed the preferLowPower parameter from SDL_CreateGPUDevice()
2024-08-29 17:33:52 -07:00
Sam Lantinga
3046335f28
Fixed device creation property documentation formatting
2024-08-29 17:33:52 -07:00
Sam Lantinga
b8e7ef27f3
Renamed GPU device creation properties
2024-08-29 17:33:52 -07:00
Sam Lantinga
d70578b9aa
Renamed Gpu to GPU
2024-08-29 17:33:52 -07:00
SDL Wiki Bot
717f4f6fb4
Sync SDL3 wiki -> header
2024-08-29 23:54:57 +00:00
Ryan C. Gordon
8ea38ebedc
gpu: Fix wiki category capitalization.
2024-08-29 19:45:03 -04:00
SDL Wiki Bot
68038394d1
Sync SDL3 wiki -> header
2024-08-29 22:58:01 +00: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
hwsmm
940f7535ef
Remove SDL_PEN hints that are no longer used
2024-08-28 07:04:48 -07:00
Maia
a24c164956
Fix trailing doc comments
2024-08-27 13:23:26 -07:00
SDL Wiki Bot
85bbc6028a
Sync SDL3 wiki -> header
2024-08-27 17:33:28 +00:00
Sam Lantinga
47926d7bd0
Added a cleanup function for virtual joysticks
2024-08-27 10:31:46 -07:00
Sam Lantinga
00c409cff8
Additional cleanup exposed by building with a C++ compiler
2024-08-27 10:31:46 -07:00
Sam Lantinga
f08ac438ed
Use stdbool for SDL_bool
...
This helps the compiler warn people when they're doing something like "if (SDL_Init(0) < 0)"
2024-08-27 10:31:46 -07:00
Sam Lantinga
9ff3446f03
Use SDL_bool instead an int return code in the SDL API
...
Most SDL functions used to indicate success or failure using an int return code. These functions have been changed to return SDL_bool.
Here is a coccinelle patch to change code that previously compared the return value to 0 and changes it to a boolean test:
@ bool_return_type @
identifier func =~ "^(SDL_AddEventWatch|SDL_AddHintCallback|SDL_AddSurfaceAlternateImage|SDL_AddVulkanRenderSemaphores|SDL_BindAudioStream|SDL_BindAudioStreams|SDL_BlitSurface|SDL_BlitSurface9Grid|SDL_BlitSurfaceScaled|SDL_BlitSurfaceTiled|SDL_BlitSurfaceTiledWithScale|SDL_BlitSurfaceUnchecked|SDL_BlitSurfaceUncheckedScaled|SDL_CaptureMouse|SDL_ClearAudioStream|SDL_ClearClipboardData|SDL_ClearComposition|SDL_ClearError|SDL_ClearProperty|SDL_ClearSurface|SDL_CloseIO|SDL_CloseStorage|SDL_ConvertAudioSamples|SDL_ConvertEventToRenderCoordinates|SDL_ConvertPixels|SDL_ConvertPixelsAndColorspace|SDL_CopyFile|SDL_CopyProperties|SDL_CopyStorageFile|SDL_CreateDirectory|SDL_CreateStorageDirectory|SDL_CreateWindowAndRenderer|SDL_DateTimeToTime|SDL_DestroyWindowSurface|SDL_DetachVirtualJoystick|SDL_DisableScreenSaver|SDL_EnableScreenSaver|SDL_EnumerateDirectory|SDL_EnumerateProperties|SDL_EnumerateStorageDirectory|SDL_FillSurfaceRect|SDL_FillSurfaceRects|SDL_FlashWindow|SDL_FlipSurface|SDL_FlushAudioStream|SDL_FlushRenderer|SDL_GL_DestroyContext|SDL_GL_GetAttribute|SDL_GL_GetSwapInterval|SDL_GL_LoadLibrary|SDL_GL_MakeCurrent|SDL_GL_SetAttribute|SDL_GL_SetSwapInterval|SDL_GL_SwapWindow|SDL_GetAudioDeviceFormat|SDL_GetAudioStreamFormat|SDL_GetCameraFormat|SDL_GetClosestFullscreenDisplayMode|SDL_GetCurrentRenderOutputSize|SDL_GetCurrentTime|SDL_GetDXGIOutputInfo|SDL_GetDateTimeLocalePreferences|SDL_GetDisplayBounds|SDL_GetDisplayUsableBounds|SDL_GetGDKDefaultUser|SDL_GetGDKTaskQueue|SDL_GetGamepadSensorData|SDL_GetGamepadTouchpadFinger|SDL_GetHapticEffectStatus|SDL_GetJoystickBall|SDL_GetMasksForPixelFormat|SDL_GetPathInfo|SDL_GetRectUnion|SDL_GetRectUnionFloat|SDL_GetRenderClipRect|SDL_GetRenderColorScale|SDL_GetRenderDrawBlendMode|SDL_GetRenderDrawColor|SDL_GetRenderDrawColorFloat|SDL_GetRenderLogicalPresentation|SDL_GetRenderLogicalPresentationRect|SDL_GetRenderOutputSize|SDL_GetRenderSafeArea|SDL_GetRenderScale|SDL_GetRenderVSync|SDL_GetRenderViewport|SDL_GetSensorData|SDL_GetStorageFileSize|SDL_GetStoragePathInfo|SDL_GetSurfaceAlphaMod|SDL_GetSurfaceBlendMode|SDL_GetSurfaceClipRect|SDL_GetSurfaceColorKey|SDL_GetSurfaceColorMod|SDL_GetTextInputArea|SDL_GetTextureAlphaMod|SDL_GetTextureAlphaModFloat|SDL_GetTextureBlendMode|SDL_GetTextureColorMod|SDL_GetTextureColorModFloat|SDL_GetTextureScaleMode|SDL_GetTextureSize|SDL_GetWindowAspectRatio|SDL_GetWindowBordersSize|SDL_GetWindowMaximumSize|SDL_GetWindowMinimumSize|SDL_GetWindowPosition|SDL_GetWindowRelativeMouseMode|SDL_GetWindowSafeArea|SDL_GetWindowSize|SDL_GetWindowSizeInPixels|SDL_GetWindowSurfaceVSync|SDL_HideCursor|SDL_HideWindow|SDL_Init|SDL_InitHapticRumble|SDL_InitSubSystem|SDL_LoadWAV|SDL_LoadWAV_IO|SDL_LockAudioStream|SDL_LockProperties|SDL_LockSurface|SDL_LockTexture|SDL_LockTextureToSurface|SDL_MaximizeWindow|SDL_MinimizeWindow|SDL_MixAudio|SDL_OpenURL|SDL_OutOfMemory|SDL_PauseAudioDevice|SDL_PauseAudioStreamDevice|SDL_PauseHaptic|SDL_PlayHapticRumble|SDL_PremultiplyAlpha|SDL_PremultiplySurfaceAlpha|SDL_PushEvent|SDL_PutAudioStreamData|SDL_RaiseWindow|SDL_ReadStorageFile|SDL_ReadSurfacePixel|SDL_ReadSurfacePixelFloat|SDL_RegisterApp|SDL_ReloadGamepadMappings|SDL_RemovePath|SDL_RemoveStoragePath|SDL_RemoveTimer|SDL_RenamePath|SDL_RenameStoragePath|SDL_RenderClear|SDL_RenderCoordinatesFromWindow|SDL_RenderCoordinatesToWindow|SDL_RenderFillRect|SDL_RenderFillRects|SDL_RenderGeometry|SDL_RenderGeometryRaw|SDL_RenderLine|SDL_RenderLines|SDL_RenderPoint|SDL_RenderPoints|SDL_RenderPresent|SDL_RenderRect|SDL_RenderRects|SDL_RenderTexture|SDL_RenderTexture9Grid|SDL_RenderTextureRotated|SDL_RenderTextureTiled|SDL_RequestAndroidPermission|SDL_RestoreWindow|SDL_ResumeAudioDevice|SDL_ResumeAudioStreamDevice|SDL_ResumeHaptic|SDL_RumbleGamepad|SDL_RumbleGamepadTriggers|SDL_RumbleJoystick|SDL_RumbleJoystickTriggers|SDL_RunHapticEffect|SDL_SaveBMP|SDL_SaveBMP_IO|SDL_SendAndroidMessage|SDL_SendGamepadEffect|SDL_SendJoystickEffect|SDL_SendJoystickVirtualSensorData|SDL_SetAppMetadata|SDL_SetAppMetadataProperty|SDL_SetAudioDeviceGain|SDL_SetAudioPostmixCallback|SDL_SetAudioStreamFormat|SDL_SetAudioStreamFrequencyRatio|SDL_SetAudioStreamGain|SDL_SetAudioStreamGetCallback|SDL_SetAudioStreamInputChannelMap|SDL_SetAudioStreamOutputChannelMap|SDL_SetAudioStreamPutCallback|SDL_SetBooleanProperty|SDL_SetClipboardData|SDL_SetClipboardText|SDL_SetCursor|SDL_SetFloatProperty|SDL_SetGamepadLED|SDL_SetGamepadMapping|SDL_SetGamepadPlayerIndex|SDL_SetGamepadSensorEnabled|SDL_SetHapticAutocenter|SDL_SetHapticGain|SDL_SetJoystickLED|SDL_SetJoystickPlayerIndex|SDL_SetJoystickVirtualAxis|SDL_SetJoystickVirtualBall|SDL_SetJoystickVirtualButton|SDL_SetJoystickVirtualHat|SDL_SetJoystickVirtualTouchpad|SDL_SetLinuxThreadPriority|SDL_SetLinuxThreadPriorityAndPolicy|SDL_SetLogPriorityPrefix|SDL_SetMemoryFunctions|SDL_SetNumberProperty|SDL_SetPaletteColors|SDL_SetPointerProperty|SDL_SetPointerPropertyWithCleanup|SDL_SetPrimarySelectionText|SDL_SetRenderClipRect|SDL_SetRenderColorScale|SDL_SetRenderDrawBlendMode|SDL_SetRenderDrawColor|SDL_SetRenderDrawColorFloat|SDL_SetRenderLogicalPresentation|SDL_SetRenderScale|SDL_SetRenderTarget|SDL_SetRenderVSync|SDL_SetRenderViewport|SDL_SetScancodeName|SDL_SetStringProperty|SDL_SetSurfaceAlphaMod|SDL_SetSurfaceBlendMode|SDL_SetSurfaceColorKey|SDL_SetSurfaceColorMod|SDL_SetSurfaceColorspace|SDL_SetSurfacePalette|SDL_SetSurfaceRLE|SDL_SetTLS|SDL_SetTextInputArea|SDL_SetTextureAlphaMod|SDL_SetTextureAlphaModFloat|SDL_SetTextureBlendMode|SDL_SetTextureColorMod|SDL_SetTextureColorModFloat|SDL_SetTextureScaleMode|SDL_SetThreadPriority|SDL_SetWindowAlwaysOnTop|SDL_SetWindowAspectRatio|SDL_SetWindowBordered|SDL_SetWindowFocusable|SDL_SetWindowFullscreen|SDL_SetWindowFullscreenMode|SDL_SetWindowHitTest|SDL_SetWindowIcon|SDL_SetWindowKeyboardGrab|SDL_SetWindowMaximumSize|SDL_SetWindowMinimumSize|SDL_SetWindowModalFor|SDL_SetWindowMouseGrab|SDL_SetWindowMouseRect|SDL_SetWindowOpacity|SDL_SetWindowPosition|SDL_SetWindowRelativeMouseMode|SDL_SetWindowResizable|SDL_SetWindowShape|SDL_SetWindowSize|SDL_SetWindowSurfaceVSync|SDL_SetWindowTitle|SDL_SetiOSAnimationCallback|SDL_ShowAndroidToast|SDL_ShowCursor|SDL_ShowMessageBox|SDL_ShowSimpleMessageBox|SDL_ShowWindow|SDL_ShowWindowSystemMenu|SDL_StartTextInput|SDL_StartTextInputWithProperties|SDL_StopHapticEffect|SDL_StopHapticEffects|SDL_StopHapticRumble|SDL_StopTextInput|SDL_SyncWindow|SDL_TimeToDateTime|SDL_TryLockMutex|SDL_TryLockRWLockForReading|SDL_TryLockRWLockForWriting|SDL_TryWaitSemaphore|SDL_UnlockAudioStream|SDL_UpdateHapticEffect|SDL_UpdateNVTexture|SDL_UpdateTexture|SDL_UpdateWindowSurface|SDL_UpdateWindowSurfaceRects|SDL_UpdateYUVTexture|SDL_Vulkan_CreateSurface|SDL_Vulkan_LoadLibrary|SDL_WaitConditionTimeout|SDL_WaitSemaphoreTimeout|SDL_WarpMouseGlobal|SDL_WriteStorageFile|SDL_WriteSurfacePixel|SDL_WriteSurfacePixelFloat)$";
@@
(
func(
...
)
- == 0
|
- func(
+ !func(
...
)
- < 0
|
- func(
+ !func(
...
)
- != 0
|
- func(
+ !func(
...
)
- == -1
)
2024-08-27 10:31:46 -07:00
Sam Lantinga
fa2c9c46c5
Default SDL_HINT_JOYSTICK_GAMEINPUT to SDL_FALSE
...
This was causing crashes in IGameInput_RegisterSystemButtonCallback(), presumably on older systems with runtimes using a different function signature. We'll just disable it for now until the GameInput runtime has stabilized and we can tell when it's safe to use.
2024-08-23 11:34:15 -07:00
Sam Lantinga
8f546bb3c9
Use C99 bool internally in SDL
2024-08-22 13:30:02 -07:00
Sam Lantinga
9c7c0646c9
Fixed typo
2024-08-22 09:04:30 -07:00
Sam Lantinga
03ace96e5b
Document that new surfaces are initialized to zero.
...
Fixes https://github.com/libsdl-org/SDL/issues/10577
2024-08-22 06:27:56 -07:00
Sam Lantinga
d29276e625
Include SDL_events.h in SDL_init.h for SDL_AppEvent_func()
2024-08-20 07:53:07 -07:00
Ryan C. Gordon
eb212ac4ed
main: Emscripten needs SDL_main_impl.h now that it has its own SDL_RunApp.
...
Reference PR #10171 .
2024-08-18 23:54:55 -04:00
SDL Wiki Bot
1f34f35b25
Sync SDL3 wiki -> header
2024-08-19 00:55:27 +00:00
Ryan C. Gordon
9c5bd98a0f
assert: Added SDL_HINT_ASSERT.
...
Same environment variable, but now accessible as a formal SDL hint.
Reference PR #10171 .
2024-08-18 20:53:55 -04:00
Ryan C. Gordon
42e43697cf
include: Minor SDL_AppResult documentation tweak.
2024-08-17 00:42:33 -04:00
SDL Wiki Bot
4147ff6a4e
Sync SDL3 wiki -> header
2024-08-17 04:39:06 +00:00
Ryan C. Gordon
4c30e555fe
include: Clean up SDL_AppResult documentation.
2024-08-17 00:37:56 -04:00
Sam Lantinga
156aab2147
Added documentation for SDL_DisplayID and SDL_WindowID for consistency.
2024-08-16 15:46:43 -07:00
SDL Wiki Bot
4fbdbbbde6
Sync SDL3 wiki -> header
2024-08-16 22:22:07 +00:00
Sam Lantinga
cb85894e94
Clarified device ID documentation
...
Fixes https://github.com/libsdl-org/SDL/issues/10558
2024-08-16 15:20:34 -07:00
SDL Wiki Bot
ab53ff77bb
Sync SDL3 wiki -> header
2024-08-16 18:17:21 +00:00
Sam Lantinga
438a214420
Changed main callback return values to an enumeration
...
Fixes https://github.com/libsdl-org/SDL/issues/10515
2024-08-16 11:16:05 -07:00
Sam Lantinga
83adcb9d38
Added SDL_PROP_WINDOW_CREATE_FLAGS_NUMBER
...
This is undocumented since the individual flags are separate window creation properties, but it's useful to have a shared definition for this, which is used internally and for migrating code from SDL2.
2024-08-15 13:33:06 -07:00
Sam Lantinga
d7b027a241
Namespace the object creation properties
...
Fixes https://github.com/libsdl-org/SDL/issues/10543
2024-08-15 12:56:04 -07:00
SDL Wiki Bot
0822d94631
Sync SDL3 wiki -> header
2024-08-15 14:29:23 +00:00
Kaktus514
3586df3151
Prefer downscaling in SDL_GetSurfaceImage.
...
This implements the ideas described in #10536
2024-08-15 07:28:31 -07:00
Sam Lantinga
1a729251ad
Added references to SDL_GetPixelFormatDetails() from the SDL_*RGB functions
2024-08-12 09:22:59 -07:00
Ryan C. Gordon
871d0074d2
SDL_GLattr: Added some documentation from SDL2.
2024-08-12 01:33:05 -04:00
Ryan C. Gordon
bec701dd04
pen: Add support for tangential pressure axis.
2024-08-11 18:00:13 -04:00
SDL Wiki Bot
a7fa375275
Sync SDL3 wiki -> header
2024-08-10 02:09:54 +00:00
Ryan C. Gordon
a9d70dbacb
pen: Rework public API.
...
This changes the API in various ways, and updates the backends for this.
Overall, this is a massive simplification of the API, as most future backends
can't support the previously-offered API.
This also removes the testautomation pen code (not only did these interfaces
change completely, it also did something no other test did: mock the internal
API), and replaces testpen.c with a different implementation (the existing
code was fine, it was just easier to start from scratch than update it).
2024-08-09 22:09:23 -04:00
SDL Wiki Bot
78b1e0e299
Sync SDL3 wiki -> header
2024-08-09 16:57:18 +00:00
Sam Lantinga
c2085dad8f
Added SDL_HINT_JOYSTICK_GAMEINPUT
2024-08-09 09:56:47 -07:00
Sam Lantinga
4cc3410dce
Added SDL_GetAudioFormatName()
...
Fixes https://github.com/libsdl-org/SDL/issues/10489
2024-08-08 15:05:37 -07:00
SDL Wiki Bot
d2bdfd7792
Sync SDL3 wiki -> header
2024-08-08 17:56:53 +00:00
Frank Praznik
ae8065e1ec
Use more stringent criteria for entering warp emulation mode
...
Require more than one warp to the window center within a certain timespan (currently 30ms, but can be tweaked) to better avoid erroneously entering warp emulation mode.
This also correctly resets the warp emulation mode activation if the window loses and regains focus.
2024-08-08 10:56:20 -07:00
Sam Lantinga
058781f514
Include GameInput.h as gameinput.h for compatibility with non-MSVC toolchains
2024-08-08 09:14:38 -07:00
Anonymous Maarten
8714de9f46
SDL_GetAudioStreamAvailable and SDL_GetAudioStreamAvailable return error codes
2024-08-08 10:11:39 +00:00
Sam Lantinga
a38cd7a067
Added checks for GameInput.h to the build system
2024-08-07 17:57:33 -07:00
SDL Wiki Bot
212f7cc355
Sync SDL3 wiki -> header
2024-08-07 19:19:43 +00:00
Sam Lantinga
001dbc5da8
Added support for raw mouse and keyboard using GameInput on Windows
...
Fixes https://github.com/libsdl-org/SDL/issues/10442
2024-08-07 12:19:09 -07:00
Sylvain
20a6193eaa
Run test suites and test cases in non-linear order (see libsdl-org#9303)
2024-08-07 10:25:30 +02:00
SDL Wiki Bot
8a3bb11024
Sync SDL3 wiki -> header
2024-08-06 17:17:11 +00:00
SDL Wiki Bot
1ecf05be93
Sync SDL3 wiki -> header
2024-08-06 17:12:54 +00:00
Anonymous Maarten
0fa2049fef
Document iconv functions + add testautomation ( #10131 )
...
* stdinc: document SDL_iconv* functions
* iconv: add automation tests
* iconv: don't potentially crash on invalid inputs
2024-08-06 10:12:25 -07:00
SDL Wiki Bot
57fa3bc08e
Sync SDL3 wiki -> header
2024-08-06 15:00:23 +00:00
Sam Lantinga
627cb8acd0
SDL_EventFilter functions now return SDL_bool
2024-08-06 07:59:45 -07:00
Sam Lantinga
57f9c6f7bb
Renamed SDL_Get/SetRelativeMouseMode to SDL_Get/SetWindowRelativeMouseMode()
...
Fixes https://github.com/libsdl-org/SDL/issues/10041
2024-08-06 07:59:45 -07:00
Sam Lantinga
a1998d106d
Putting the simple back into Simple DirectMedia Layer
2024-08-05 21:20:26 -07:00
SDL Wiki Bot
0d3db8390d
Sync SDL3 wiki -> header
2024-08-06 02:47:18 +00:00
Sam Lantinga
afec46dbee
Re-added SDL_GetScancodeFromKey()
2024-08-05 19:46:45 -07:00
Sam Lantinga
a13c993e40
Removed keymaps from the API
...
This is unnecessary complication for applications. We can always add it again later if we find that it's really useful.
2024-08-05 19:46:45 -07:00
SDL Wiki Bot
1966472f73
Sync SDL3 wiki -> header
2024-08-06 00:02:59 +00:00
Sam Lantinga
c298a3749b
Expose the keymap separately from the event keycode
...
This adds functions to query the keymap:
* SDL_GetCurrentKeymap()
* SDL_GetKeymapKeycode()
* SDL_GetKeymapScancode()
* SDL_ReleaseKeymap()
and these are distinct from the function to query the event keycode associated with a scancode, which might be affected by SDL_HINT_KEYCODE_OPTIONS.
Also added an SDL_bool parameter to SDL_GetKeyName() and SDL_GetKeyFromName() to enable upper case handling of the name.
2024-08-05 17:02:25 -07:00
Sam Lantinga
d223264f17
Updated the documentation for SDL_HINT_KEYCODE_OPTIONS
2024-08-05 10:17:48 -07:00
SDL Wiki Bot
ad27d73a19
Sync SDL3 wiki -> header
2024-08-05 16:03:59 +00:00
Sam Lantinga
6161c437c7
Added SDL_SetLogPriorityPrefix()
...
SDL_Log() no longer prints a log prefix by default for SDL_LOG_PRIORITY_INFO and below. The log prefixes can be customized with SDL_SetLogPriorityPrefix().
2024-08-05 09:02:50 -07:00
Ryan C. Gordon
074dd8c35f
hints: Change hints to be backed by Properties, add documentation. ( #9892 )
...
This makes the subsystem thread-safe, more performant, and cleans up the code a little.
Also removed SDL_HINT_WINDOWS_FORCE_MUTEX_CRITICAL_SECTIONS, since setting this hint programmatically initializes properties, which creates a lock, so we can't check hints while creating locks. The slim reader-writer locks have been the default for ages and are solid, so we'll just use those when available.
2024-08-05 09:02:28 -07:00
SDL Wiki Bot
e3682995f5
Sync SDL3 wiki -> header
2024-08-05 15:54:41 +00:00
Sam Lantinga
746b8eb14b
Added SDL_HINT_MUTE_CONSOLE_KEYBOARD
2024-08-05 08:54:10 -07:00
Sam Lantinga
afde1cc9c2
Added SDL_HINT_EVDEV_DEVICES
2024-08-05 08:54:10 -07:00
Sam Lantinga
0da346f129
Added SDL_HINT_HIDAPI_LIBUSB, SDL_HINT_HIDAPI_LIBUSB_WHITELIST, and SDL_HINT_HIDAPI_UDEV
2024-08-05 08:54:10 -07:00
Sam Lantinga
d9f9e9e764
Added SDL_HINT_VIDEO_DUMMY_SAVE_FRAMES and SDL_HINT_VIDEO_OFFSCREEN_SAVE_FRAMES
2024-08-05 08:54:10 -07:00
Sam Lantinga
a97dadf779
Added hints to replace environment variables on the PlayStation Vita
2024-08-05 08:54:10 -07:00
Sam Lantinga
3669d1e76a
Added SDL_HINT_VULKAN_DISPLAY
2024-08-05 08:54:10 -07:00
Sam Lantinga
997df06320
Added SDL_HINT_X11_XCB_LIBRARY
2024-08-05 08:54:10 -07:00
Sam Lantinga
175f28f59f
Added SDL_HINT_VIDEO_X11_NODIRECTCOLOR
2024-08-05 08:54:10 -07:00
Sam Lantinga
8cde570ad9
Added SDL_HINT_VIDEO_X11_VISUALID
2024-08-05 08:54:10 -07:00
Sam Lantinga
05f870f20d
Added SDL_HINT_OPENGL_LIBRARY and SDL_HINT_VULKAN_LIBRARY
2024-08-05 08:54:10 -07:00
Sam Lantinga
c9b2bfa7c1
Added SDL_HINT_AUDIO_DISK_INPUT_FILE, SDL_HINT_AUDIO_DISK_OUTPUT_FILE, and SDL_HINT_AUDIO_DISK_TIMESCALE
2024-08-05 08:54:10 -07:00
Sam Lantinga
e1ee0e748d
Added SDL_HINT_WAVE_CHUNK_LIMIT
2024-08-05 08:54:10 -07:00
Sam Lantinga
f05cd85048
Added SDL_HINT_AUDIO_ALSA_DEFAULT_DEVICE
2024-08-05 08:54:10 -07:00
Sam Lantinga
71574ac985
Added SDL_HINT_AUDIO_DUMMY_TIMESCALE
2024-08-05 08:54:10 -07:00
Sam Lantinga
5aa1a48ac3
Added SDL_HINT_AUDIO_FREQUENCY, SDL_HINT_AUDIO_CHANNELS, and SDL_HINT_AUDIO_FORMAT
2024-08-05 08:54:10 -07:00
Sam Lantinga
0a6bab3ac7
Added SDL_CreateRenderer to the "see also" for SDL_RenderPresent()
2024-08-05 07:56:29 -07:00
SDL Wiki Bot
6212497ea3
Sync SDL3 wiki -> header
2024-08-05 03:00:45 +00:00
Sam Lantinga
b1af91e788
Clarified timer documentation
...
Fixes https://github.com/libsdl-org/SDL/issues/10079
2024-08-04 19:44:13 -07:00
SDL Wiki Bot
a699ff2419
Sync SDL3 wiki -> header
2024-08-04 17:49:28 +00:00
Sam Lantinga
bc1c3f826f
Added SDL_HINT_LOGGING documentation to the logging category page.
...
Fixes https://github.com/libsdl-org/SDL/issues/10335
2024-08-04 10:48:42 -07:00
SDL Wiki Bot
454c85ad51
Sync SDL3 wiki -> header
2024-08-04 17:39:54 +00:00
Sam Lantinga
6da4278d37
Clarify how to check for EOF in SDL_ReadIO() documentation.
...
Fixes https://github.com/libsdl-org/SDL/issues/8564
2024-08-04 10:37:51 -07:00
Sam Lantinga
ef6521aee7
testnative: print events with --info event
2024-08-04 09:07:19 -07:00
SDL Wiki Bot
cb440ec4a4
Sync SDL3 wiki -> header
2024-08-03 13:40:37 +00:00
Sam Lantinga
cd5f0d2cce
Added SDL_RectToFRect()
2024-08-03 06:40:06 -07:00
SDL Wiki Bot
2f24e9c2f2
Sync SDL3 wiki -> header
2024-08-03 13:30:08 +00:00
SDL Wiki Bot
b5c0921196
Sync SDL3 wiki -> header
2024-08-03 02:37:43 +00:00
Anonymous Maarten
f57c597c60
Added SDL_GetWindowFromEvent
2024-08-03 02:37:11 +00:00
SDL Wiki Bot
e058aa6d65
Sync SDL3 wiki -> header
2024-08-02 21:50:11 +00:00
Sam Lantinga
50492e1d03
Change the text input defaults to match the natural input experience
2024-08-02 14:49:37 -07:00
Sam Lantinga
81f8e6aba6
Added SDL_StartTextInputWithProperties()
...
This allows you to customize the text input so you can have numeric text entry, hidden passwords, etc.
Fixes https://github.com/libsdl-org/SDL/issues/7101
Fixes https://github.com/libsdl-org/SDL/issues/7965
Fixes https://github.com/libsdl-org/SDL/issues/9439
2024-08-02 14:49:37 -07:00
SDL Wiki Bot
f01d4278c6
Sync SDL3 wiki -> header
2024-08-01 20:49:00 +00:00
Sam Lantinga
31ed3665ad
Added support for high-DPI cursors and icons
...
Fixes https://github.com/libsdl-org/SDL/issues/9838
2024-08-01 13:48:28 -07:00
Sam Lantinga
94d9229ce2
Added SDL_AddSurfaceAlternateImage(), SDL_SurfaceHasAlternateImages(), SDL_GetSurfaceImages() and SDL_RemoveSurfaceAlternateImages()
...
These functions allow you to create surfaces with alternate high DPI content, and will be used for high DPI icon and cursor support.
2024-08-01 13:48:28 -07:00
Sam Lantinga
22ffb487d0
Added SDL_ScaleSurface()
2024-08-01 13:48:28 -07:00
Anonymous Maarten
68fb07787b
cmake: Remove HAVE_D3D12_H from sources and introduce SDL_RENDER_D3D(11|12)
2024-08-01 17:49:02 +00:00
SDL Wiki Bot
2e058ba7a4
Sync SDL3 wiki -> header
2024-08-01 05:37:11 +00:00
Sam Lantinga
a5f18048b2
Extend the 9-grid functions to handle a non-uniform grid layout (thanks @zaun!)
...
Fixes https://github.com/libsdl-org/SDL/issues/10389
2024-07-31 22:36:39 -07:00
Sam Lantinga
a6407e88da
Document the events that need to be handled in a callback
2024-07-30 07:52:13 -07:00
Sam Lantinga
691cf15e75
Removed the ancient Android audio driver
...
OpenSLES is well supported on Android 4.0 and later.
2024-07-29 08:05:36 -07:00
SDL Wiki Bot
3b01a0b884
Sync SDL3 wiki -> header
2024-07-29 11:26:36 +00:00
Sam Lantinga
61a88077a7
Re-added SDL_HINT_APP_ID and SDL_HINT_APP_NAME
2024-07-29 07:26:03 -04:00
Sam Lantinga
383ccb2b6a
Finish removing SDL_DECLSPEC_FREE
2024-07-28 08:06:20 -07:00
Sam Lantinga
728bf363cb
Make sure we call SDL_Quit() before SDLTest_CommonDestroyState()
...
Otherwise we'll report leaks that will be cleaned up in SDL_Quit()
2024-07-28 08:05:31 -07:00
Sam Lantinga
b5ad74998b
Removed SDL_DECLSPEC_FREE
2024-07-28 07:24:21 -07:00
SDL Wiki Bot
18fe89e036
Sync SDL3 wiki -> header
2024-07-28 14:23:13 +00:00
Sam Lantinga
a36fe632fd
Added SDL_SetAppMetadata() ( #10404 )
...
Removed duplicate hints SDL_HINT_APP_NAME, SDL_HINT_APP_ID, and
SDL_HINT_AUDIO_DEVICE_APP_NAME.
Wired up a few things to use the metadata; more to come!
Fixes https://github.com/libsdl-org/SDL/issues/4703
2024-07-28 07:22:46 -07:00
Sam Lantinga
473feab2a4
Added SDL_unsetenv()
2024-07-27 09:10:08 -07:00
Anonymous Maarten
3374e57102
stdinc: strcasecmp is declared in strings.h
2024-07-27 15:19:20 +00:00
SDL Wiki Bot
0f2fc2fbaa
Sync SDL3 wiki -> header
2024-07-27 03:59:43 +00:00
Sam Lantinga
4f55271571
Removed temporary memory from the API
...
It was intended to make the API easier to use, but various automatic garbage collection all had flaws, and making the application periodically clean up temporary memory added cognitive load to using the API, and in many cases was it was difficult to restructure threaded code to handle this.
So, we're largely going back to the original system, where the API returns allocated results and you free them.
In addition, to solve the problems we originally wanted temporary memory for:
* Short strings with a finite count, like device names, get stored in a per-thread string pool.
* Events continue to use temporary memory internally, which is cleaned up on the next event processing cycle.
2024-07-26 20:59:14 -07:00
SDL Wiki Bot
2137e6eed1
Sync SDL3 wiki -> header
2024-07-26 17:05:33 +00:00
Sam Lantinga
5e513ecc7f
Don't automatically free temporary memory, let the application call SDL_FreeTemporaryMemory() when it's ready.
...
Also mark up all functions that return temporary memory with SDL_DECLSPEC_TEMP, to help people implementing language bindings.
Fixes https://github.com/libsdl-org/SDL/issues/10378
2024-07-26 10:05:03 -07:00
Eduard Gushchin
2f38a4bf5e
Fixed a typo in the link to the GetTouchFingers function
2024-07-26 07:59:08 -07:00
SDL Wiki Bot
a1a8278029
Sync SDL3 wiki -> header
2024-07-26 00:47:35 +00:00
Sam Lantinga
750aef2bee
Clarified that temporary memory shouldn't be kept beyond the current function scope or event handling.
2024-07-25 17:47:00 -07:00
SDL Wiki Bot
a880410cb2
Sync SDL3 wiki -> header
2024-07-25 23:58:09 +00:00
Frank Praznik
66eb2ea443
mouse: Make pointer warp emulation via relative mode available to all platforms
...
Move the Wayland pointer warp emulation code up to the SDL mouse layer, and activate it when a client attempts to warp a hidden mouse cursor when the hint is set.
testrelative adds the ability to test the warp emulation activation/deactivation with the --warp parameter and 'c' key for toggling cursor visibility.
2024-07-25 19:57:39 -04:00
Eduard Gushchin
92667e3066
Update SDL_keycode.h
...
Removed the link referring to yourself
2024-07-25 14:12:04 -07:00
Eduard Gushchin
3ee59359c4
Fix documentation references and update method usage for SDL_GetGamepadGUIDForID in SDL_gamepad.h
...
In the documentation for the SDL_GetGamepadGUIDForID method in the SDL_gamepad.h file, there are two references to the methods SDL_GetGamepadGUID and SDL_GetGamepadGUIDString, but there are no methods of its own. I replaced these two methods with the existing SDL_GUIDToString.
2024-07-25 11:43:41 -07:00
SDL Wiki Bot
ba8495c214
Sync SDL3 wiki -> header
2024-07-25 00:41:44 +00:00
Sam Lantinga
cf8b158ccb
Added SDL_GetRenderSafeArea()
2024-07-24 17:40:41 -07:00
Sam Lantinga
b98e1e9ef0
Fixed the render viewport not updating when the metal view resizes
...
When the phone is in portrait mode and the window is in landscape mode, the view changes orientation after layoutSubviews runs. In this case we need some way of notifying the application that the Metal view has changed.
2024-07-24 16:12:29 -07:00
Sam Lantinga
f562a6d9f7
Added Android API level 35 to the table
2024-07-24 14:09:54 -07:00
Sam Lantinga
a7c0192017
Renamed SDL_PostSemaphore() to SDL_SignalSemphore()
2024-07-24 13:37:40 -07:00
Sam Lantinga
ca4bd4b63c
Android life cycle behavior more closely matches iOS
...
This change also decouples the pause/resume handling from the video subsystem on Android, so applications that don't use SDL for video can get application life cycle events.
The semantics for the life cycle events are that they need to be handled in an event watch callback, and once they've been delivered, the application will block until it's been resumed. SDL_HINT_ANDROID_BLOCK_ON_PAUSE can be used to control that behavior, and if that's set to "0", then the application will continue to run in the background at low CPU usage until being resumed or stopped.
SDL_HINT_ANDROID_BLOCK_ON_PAUSE_PAUSEAUDIO has been removed, and the audio will be paused when the application is paused.
Fixes https://github.com/libsdl-org/SDL/issues/3193
2024-07-24 05:11:13 -07:00
Sam Lantinga
fa0918a686
Renamed SDL life cycle functions
...
This maps better to how SDL delivers the events, and the iOS delegate methods are in the documentation for reference.
2024-07-24 05:11:13 -07:00
Sam Lantinga
f0363a0466
Functions that return display modes return temporary memory.
...
Also use the real pointer to display modes for internal mode processing
Fixes https://github.com/libsdl-org/SDL/issues/10353
2024-07-23 19:26:19 -07:00
SDL Wiki Bot
10dcae784b
Sync SDL3 wiki -> header
2024-07-24 00:07:31 +00:00
Sam Lantinga
457ca3995c
Added SDL_GetWindowSafeArea()
...
Fixes https://github.com/libsdl-org/SDL/issues/3243
2024-07-23 17:06:04 -07:00
SDL Wiki Bot
230161a50c
Sync SDL3 wiki -> header
2024-07-23 22:49:23 +00:00
Sam Lantinga
66011e497d
Removed duplication in SDL_EGL_* function names
2024-07-23 13:11:37 -07:00
Eduard Gushchin
86934975b9
Update SDL_video.h
...
Fixed a typo in the function name in the documentation for SDL_EGL_GetProcAddress
2024-07-23 12:48:10 -07:00
SDL Wiki Bot
2aea74aa84
Sync SDL3 wiki -> header
2024-07-22 22:19:38 +00:00
Sam Lantinga
a36be94ad1
More clarification on temporary memory
2024-07-22 15:19:26 -07:00
Sam Lantinga
29f0fd33dc
SDL_getenv() should return const
...
This also allows us to use SDL_FreeLater() and make SDL_getenv() thread-safe on Windows.
2024-07-22 13:00:39 -07:00
Sam Lantinga
ef21e31a9a
SDL_GUIDFromString() renamed SDL_StringToGUID()
2024-07-22 12:39:15 -07:00
SDL Wiki Bot
5e12706ae0
Sync SDL3 wiki -> header
2024-07-22 17:05:52 +00:00
Eduard Gushchin
24bb95f60c
Fixed a typo in the name of the method in the documentation for SDL_GetDisplayProperties
2024-07-22 10:04:59 -07:00
Sam Lantinga
c4bf5f9f59
SDL_CreateTexture() uses the SDL_TextureAccess type for the access parameter
2024-07-22 09:32:02 -07:00
SDL Wiki Bot
3e943090d0
Sync SDL3 wiki -> header
2024-07-22 14:50:48 +00:00
Eduard Gushchin
61565b7f61
Update SDL_video.h
...
Led to the actual list of WindowsFlag in the documentation of the SDL_CreateWindow method
2024-07-22 07:50:07 -07:00
SDL Wiki Bot
40cb3fb74a
Sync SDL3 wiki -> header
2024-07-22 14:35:35 +00:00
Sam Lantinga
ff1d351390
Removed SDL_FreeTemporaryMemory()
...
This was just causing confusion and anxiety. SDL temporary memory will be automatically freed on the main thread when processing events and on other threads when it ages out after a second. The application can free it directly by calling SDL_ClaimTemporaryMemory() to get ownership of the pointer, if necessary.
2024-07-22 07:34:25 -07:00
Ozkan Sezer
70c1012e8c
SDL_stdinc.h (SDL_COMPILE_TIME_ASSERT): Keep C++ case alone (after PR/10331)
...
Some versions of gcc will define __STDC_VERSION__ even when compiling in C++ mode.
Reference issue: https://github.com/libsdl-org/SDL/issues/6078 which was fixed by
f6b81125b3
2024-07-22 16:00:37 +03:00
SDL Wiki Bot
230f2a684d
Sync SDL3 wiki -> header
2024-07-22 12:59:19 +00:00
Sam Lantinga
685e381735
Add an overview of how to handle temporary memory
2024-07-22 05:58:19 -07:00
Sam Lantinga
9bfd0d901c
Audio device IDs are unsigned
2024-07-22 05:48:01 -07:00
Sam Lantinga
033c9c5951
Added SDL_CopyFile() and SDL_CopyStorageFile()
...
Fixes https://github.com/libsdl-org/SDL/issues/9553
2024-07-21 19:58:23 -07:00
Anonymous Maarten
22bfbdbc02
stdinc: c23 deprecated _Static_assert in favor of static_assert
2024-07-21 21:51:55 +03:00
Sam Lantinga
c040a02d6c
Removed SDL_PROP_SURFACE_COLORSPACE_NUMBER
...
Now that we have surface internal data, we can store it there. This slightly improves performance in the surface blitting paths.
2024-07-21 09:36:22 -07:00
SDL Wiki Bot
4a7e95402f
Sync SDL3 wiki -> header
2024-07-21 15:09:24 +00:00
Sam Lantinga
e0fd59de64
Fixed floating point rectangles to be mathematically correct.
...
* A floating point rectangle contains all points >= x and <= x + w
* A floating point rectangle is only empty if it has negative width. The zero rectangle contains the zero point.
* Adjacent floating point rectangles intersect along their shared side
Fixes https://github.com/libsdl-org/SDL/issues/6791
2024-07-21 08:08:15 -07:00
Sam Lantinga
b0a6afaa35
Updated documentation for SDL_GetPreferredLocales()
2024-07-20 20:12:55 -07:00
SDL Wiki Bot
979c71b18b
Sync SDL3 wiki -> header
2024-07-21 01:22:39 +00:00
Sam Lantinga
6209c71f54
Added SDL_BlitSurface9Grid() and SDL_RenderTexture9Grid()
2024-07-20 18:21:19 -07:00
Sam Lantinga
9294476788
Added SDL_WriteSurfacePixel() and SDL_WriteSurfacePixelFloat()
2024-07-20 18:21:19 -07:00
Sam Lantinga
12e50d17a2
Removed SDL_SoftStretch() from the public API
...
SDL_BlitSurfaceScaled() is more flexible and uses the SDL_SoftStretch() fast path when possible. Having two surface scaling APIs was confusing, especially when one of them has unexpected limitations.
2024-07-20 18:21:19 -07:00
Sam Lantinga
5ce81ebcc9
Corrected blit colorkey documentation
...
Fixes https://github.com/libsdl-org/sdlwiki/issues/576
2024-07-20 18:21:19 -07:00
Sam Lantinga
67fa7a9138
SDL_BlitSurface() and SDL_BlitSurfaceScaled() now have a const dstrect parameter
...
This was originally to avoid duplicating clipping work in Maelstrom on a 486 computer. This has been confusing for users and computers are a little faster these days, so we'll make it work the way people expect.
2024-07-20 18:21:19 -07:00
Sam Lantinga
198caa54a1
Added SDL_RenderTextureTiled()
2024-07-20 18:21:19 -07:00
Sam Lantinga
9e55ee9391
Added SDL_BlitSurfaceTiledWithScale()
2024-07-20 18:21:19 -07:00
Sam Lantinga
f47ddbf1ac
Added SDL_BlitSurfaceTiled()
...
Fixes https://gamedev.stackexchange.com/questions/136792/is-there-a-way-to-set-texture-wrap-mode-as-repeat-in-sdl-2
2024-07-20 18:21:19 -07:00
hwsmm
6a62c54b93
Remove a duplicate definition that is already in SDL_guid.h
2024-07-20 12:23:50 +03:00
Anonymous Maarten
476b987f1b
intrinsics: avx, avx2 and avx512f are (currently) unsupported on arm64ec
2024-07-20 00:59:58 +02:00
Sam Lantinga
f0a839b9b7
Removed SDL 2.1 note, we're not going to revisit this for SDL 3.0
...
Closes https://github.com/libsdl-org/SDL/issues/9480
2024-07-19 13:39:22 -07:00
SDL Wiki Bot
fc8cd657a5
Sync SDL3 wiki -> header
2024-07-19 20:08:05 +00:00
Sam Lantinga
b80784fced
SDL_GetGamepadBindings() follows the SDL_GetStringRule
2024-07-19 13:06:54 -07:00
Sam Lantinga
93db5ef135
Fixed documentation for SDL_GlobDirectory()
2024-07-19 13:06:54 -07:00
Sam Lantinga
0079b6d45f
SDL_GetTouchFingers() follows the SDL_GetStringRule
2024-07-19 13:06:54 -07:00
SDL Wiki Bot
975457cfb6
Sync SDL3 wiki -> header
2024-07-19 19:23:24 +00:00
Sam Lantinga
71a60d4c0e
Updated documentation for functions that return temporary memory
2024-07-19 12:22:03 -07:00
Sam Lantinga
68322ac851
Ensure that all functions that follow the SDL_GetStringRule return temporary memory
2024-07-19 12:22:03 -07:00
Sam Lantinga
fd9fe1bb7b
Renamed event memory to temporary memory, since it's not just used for events
2024-07-19 12:22:03 -07:00
Sam Lantinga
c4eac60000
SDL_GetClipboardData() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
61a7a0e579
SDL_GUIDToString() follows the SDL_GetStringRule
...
Also removed the distinction between SDL_GUID and SDL_JoystickGUID
2024-07-19 12:22:03 -07:00
Sam Lantinga
892df4bf4b
SDL_GetWindowICCProfile() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
eb22fcce35
SDL_GetTouchDevices() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
856d598d6e
SDL_GetSensors() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
4f8c348402
SDL_GetPreferredLocales() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
9be73ed7c5
SDL_GetMice() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
6ca18ed0e5
SDL_GetKeyboards() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
5ce0aacaa4
SDL_GetGamepads() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
4961af4569
SDL_GetJoysticks() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
b32c9615a7
SDL_GetHaptics() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
9de8cb888a
SDL_GetFullscreenDisplayModes() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
9758e102bc
SDL_GetDisplays() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
01199469de
SDL_GetCameras() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
0fe6603747
SDL_GetCameraSupportedFormats() follows the SDL_GetStringRule
...
Also changed the function to return an array of pointers and added example usage to testcamera
2024-07-19 12:22:03 -07:00
Sam Lantinga
637e9700dd
Standardize placement of '*' in function declarations
...
Implemented using these sed commands on the headers:
sed -E -i'' '/SDLCALL|;/ s,([a-z])\* ,\1 *,g' *
sed -E -i'' 's,(\(.*[^\*])\* ([a-z])(.*\)),\1*\2\3,g' *
sed -E -i'' 's,\*const,* const,g' *
sed -E -i'' 's,\*SDLCALL,* SDLCALL,g' *
sed -E -i'' 's,void\(,void (,g' *
git checkout *gl*
2024-07-19 12:22:03 -07:00
Sam Lantinga
bdafc8e212
SDL_GetWindows() follows the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
8ca6caeda5
SDL_GetAudioPlaybackDevices() and SDL_GetAudioRecordingDevices() follow the SDL_GetStringRule
2024-07-19 12:22:03 -07:00
Sam Lantinga
ef884c8aa6
Transfer event memory between the local pool and the event queue
...
This allows threads to free memory from their local pool without affecting events that are queued, and to transfer memory ownership cleanly between threads that are queuing and dequeuing events.
2024-07-19 12:22:03 -07:00
Sam Lantinga
f95ecac300
Added SDL_ClaimEventMemory()
2024-07-19 12:22:03 -07:00
Sam Lantinga
2816745f48
Allow passing a pointer to SDL_FreeEventMemory()
...
Also clarify in the documentation that you should not call SDL_FreeEventMemory(NULL) from your main thread.
2024-07-19 12:22:03 -07:00
Sam Lantinga
217330a7b3
Made return value descriptions more consistent across the API
2024-07-19 12:22:03 -07:00
Sam Lantinga
d73c7311d5
Clarify that the SDL_GetStringRule means that SDL will automatically free the memory later.
2024-07-19 12:22:03 -07:00
SDL Wiki Bot
e949f12f63
Sync SDL3 wiki -> header
2024-07-18 01:04:46 +00:00
Sam Lantinga
02a072a1b7
Added SDL_ClearSurface() and SDL_ReadSurfacePixelFloat()
2024-07-17 18:04:16 -07:00
Sam Lantinga
de6595bda6
SDL_MUSTLOCK() should return true if the surface needs locking even if it's currently locked.
...
There's a bunch of code that assumes this in SDL, and presumably in applications as well.
2024-07-17 18:04:16 -07:00
Sam Lantinga
334962b056
Enhancements for SDL_PremultiplyAlpha()
...
The function can now convert between pixels of different formats, and takes a parameter to control whether the premultiplication is done in sRGB or linear space.
Also added SDL_PremultiplySurfaceAlpha(), which can premultiply the pixels of a surface in-place.
2024-07-17 18:04:16 -07:00
Frank Praznik
b99ea1ff75
wayland: Add SDL_VIDEO_DOUBLE_BUFFER support
...
Manual cherry-pick of 9e6b8d56e3
thanks @vanfanel
2024-07-17 18:27:46 -04:00
Sam Lantinga
5f5e91eab6
Reverted 3d2e5a0b66
...
Applying these changes to external code doesn't actually improve anything, and within the context of the other Get* functions for renderers and surfaces, these stand out as outliers, so I'm going to back this change out.
2024-07-17 10:27:37 -07:00
Sam Lantinga
8c25129458
SDL_EVENT_WINDOW_LAST should be SDL_EVENT_WINDOW_HDR_STATE_CHANGED
...
Fixes https://github.com/libsdl-org/SDL/issues/10299
2024-07-16 22:43:02 -07:00
SDL Wiki Bot
b92ec25147
Sync SDL3 wiki -> header
2024-07-17 04:33:30 +00:00
Sam Lantinga
3d2e5a0b66
Fixed a few remaining functions to directly return their values instead of an error code.
2024-07-16 21:32:17 -07:00
Sam Lantinga
b7ec2119dd
Use a dither palette when converting RGB images to indexed formats
2024-07-16 17:57:12 -07:00
Sam Lantinga
9ca1792848
Renamed driverdata to internal
...
This was done to SDL_DisplayMode for consistency with SDL_Surface and gives it a type so we don't have to do casts in SDL code.
I considered switching to an ID and hashing the driver data, etc. but all of that involved a lot of internal code churn and this solution gives us flexibility in how we handle this in the future.
After consideration, I made this renaming global across the project, for consistency.
Fixes https://github.com/libsdl-org/SDL/issues/10198
2024-07-16 17:17:13 -07:00
SDL Wiki Bot
fe183872ee
Sync SDL3 wiki -> header
2024-07-16 20:45:34 +00:00
Ryan C. Gordon
4dda785c69
gamepad: Several gamepad mapping functions now follow the SDL_GetStringRule.
...
Reference Issue #10229 .
2024-07-16 16:44:36 -04:00
Ryan C. Gordon
ed1f93cd11
filesystem: `SDL_Glob*Directory()` functions now follow the SDL_GetStringRule.
...
Reference Issue #10229 .
2024-07-16 16:44:36 -04:00
Ryan C. Gordon
52bf7ff42d
filesystem: SDL_GetPrefPath() now follows the SDL_GetStringRule.
...
Reference Issue #10229 .
2024-07-16 16:44:36 -04:00
Ryan C. Gordon
2321726ff1
filesystem: SDL_GetUserFolder() now follows the SDL_GetStringRule.
...
It also now caches at the higher level, so the platform-specific bits don't
change their interface much.
Reference Issue #10229 .
2024-07-16 16:44:36 -04:00
Ryan C. Gordon
d40b89dff6
clipboard: SDL_GetPrimarySelectionText() now follows the SDL_GetStringRule.
...
Reference Issue #10229 .
2024-07-16 16:44:36 -04:00
Ryan C. Gordon
158fc459f1
clipboard: SDL_GetClipboardText() now follows the SDL_GetStringRule.
...
Reference Issue #10229 .
2024-07-16 16:44:36 -04:00
Ryan C. Gordon
3bc81a81f5
filesystem: SDL_GetBasePath() now follows the SDL_GetStringRule.
...
It also now caches at the higher level, so the platform-specific bits don't
change their interface much.
A little code hygiene work was applied to some of the platform bits on top of
this.
Reference Issue #10229 .
2024-07-16 16:44:36 -04:00
SDL Wiki Bot
d65a8146b9
Sync SDL3 wiki -> header
2024-07-16 19:03:15 +00:00
Sam Lantinga
4aeabb3c3b
Made event and temporary string memory thread-local and added SDL_FreeEventMemory()
...
Fixes https://github.com/libsdl-org/SDL/issues/10283
2024-07-16 12:01:51 -07:00
Sam Lantinga
ec3bb4c029
Removed the need for SDL_CreateTLS()
...
This eliminates the tap dancing needed for allocating TLS slots, we'll automatically allocate them as needed, in a thread-safe way.
2024-07-16 12:01:51 -07:00
SDL Wiki Bot
70727d36b2
Sync SDL3 wiki -> header
2024-07-16 16:37:08 +00:00
Sam Lantinga
027671bedb
SDL_GetWindowOpacity() directly returns the opacity instead of using an out parameter.
...
Fixes https://github.com/libsdl-org/SDL/issues/10286
2024-07-16 09:36:11 -07:00
Sam Lantinga
58270ef3f2
Finished renaming functions in SDL_system.h
2024-07-16 09:35:49 -07:00
SDL Wiki Bot
4ac67f5ba6
Sync SDL3 wiki -> header
2024-07-16 01:38:55 +00:00
Sam Lantinga
033df70d4c
SDL_DelayNS() will attempt to sleep exactly the requested amount of time
...
This provides a highly accurate sleep function for your application, although you are still subject to being switched out occasionally.
Fixes https://github.com/libsdl-org/SDL/issues/10210
2024-07-15 18:38:09 -07:00
Sam Lantinga
54366181c3
Rename functions in SDL_system.h to match SDL 3.0 naming convention
...
Fixes https://github.com/libsdl-org/SDL/issues/10277
2024-07-15 16:27:48 -07:00
Sam Lantinga
70c8fe61d7
Align SDL_BLENDMODE_INVALID with the other constants
2024-07-15 15:00:09 -07:00
Sam Lantinga
bf501ab2d4
Made the SDL_BlendMode values wiki-friendly
2024-07-15 14:46:56 -07:00
Sam Lantinga
df573391b1
Added SDL_BLENDMODE_BLEND_PREMULTIPLIED and SDL_BLENDMODE_ADD_PREMULTIPLIED
...
Fixes https://github.com/libsdl-org/SDL/issues/2485
2024-07-15 14:12:33 -07:00
SDL Wiki Bot
9406a9d527
Sync SDL3 wiki -> header
2024-07-14 23:42:33 +00:00
Sam Lantinga
5c875e1183
Renamed *FromID() to *ForID()
...
While it makes sense to get an object pointer from an object ID, you want to get object attributes for an ID, otherwise e.g. GetNameFromID() sounds like it's a name ID, not an object ID. This is also consistent with the function naming convention in SDL2.
2024-07-14 15:56:50 -07:00
SDL Wiki Bot
0cdc60666b
Sync SDL3 wiki -> header
2024-07-14 21:04:37 +00:00
Ryan C. Gordon
f61900465c
stdinc: Fixed up documentation details for standard types.
2024-07-14 17:03:15 -04:00
SDL Wiki Bot
cb854d1bc9
Sync SDL3 wiki -> header
2024-07-14 20:02:23 +00:00
Sam Lantinga
9797c5d0c0
Renamed CameraDevice to Camera
...
This is consistent with the rest of the SDL API
2024-07-14 13:01:53 -07:00
Sam Lantinga
9358333286
Renamed SDL_GetKeyboardInstanceName() and SDL_GetMouseInstanceName()
...
For consistency with other device APIs
2024-07-14 13:01:53 -07:00
Sam Lantinga
d154b37b41
Renamed *FromInstanceID() to *FromID()
2024-07-14 13:01:53 -07:00
Sam Lantinga
cad9e6ea20
Fixed SDL_SINT64_C typo
...
Apparently all the platforms we compile on have INT64_C defined?
Fixes https://github.com/libsdl-org/SDL/issues/10268
2024-07-14 12:53:32 -07:00
Ryan C. Gordon
90e69f81e5
SDL_hidapi.h: Fixed something that apparently upset wikiheaders.
2024-07-14 15:20:26 -04:00
Ryan C. Gordon
15f850babc
SDL_hidapi.h: remove struct predeclaration before typedef.
2024-07-14 15:18:08 -04:00
Sam Lantinga
a17b742e34
Added documentation references to the components of a colorspace
2024-07-14 11:43:39 -07:00
SDL Wiki Bot
abaef81615
Sync SDL3 wiki -> header
2024-07-14 18:04:00 +00:00
Sam Lantinga
6217094c40
Updated colorspace documentation for the wiki
2024-07-14 11:02:56 -07:00
Sam Lantinga
1fecef5e4b
Assign numeric values to pixel format enums
...
This makes it easier to generate language bindings for these.
2024-07-14 11:02:56 -07:00
Sam Lantinga
cb395f7e80
Change SDL_AudioFormat into an enum
...
This makes it easier to understand in the debugger, and is consistent with SDL_PixelFormat and SDL_Colorspace
2024-07-14 10:04:31 -07:00
Sam Lantinga
e90060d07f
Renamed functions to get information from device IDs
...
Fixes https://github.com/libsdl-org/SDL/issues/10237
2024-07-14 09:03:59 -07:00
Sam Lantinga
bfee544685
Changed SDL_GetWindowPixelFormat() to return SDL_PixelFormat
...
Fixes https://github.com/libsdl-org/SDL/issues/10257
Closes https://github.com/libsdl-org/SDL/pull/10258
2024-07-14 07:19:20 -07:00
SDL Wiki Bot
2596482c3f
Sync SDL3 wiki -> header
2024-07-13 21:32:39 +00:00
Sam Lantinga
650271af46
Added SDL_CreateSurfacePalette()
2024-07-13 14:31:28 -07:00
captain0xff
0506cf18ab
android: enable vulkan renderer
2024-07-13 08:16:26 -07:00
Sam Lantinga
730d5cf2f8
Added fractional representation of refresh rate to SDL_DisplayMode
2024-07-12 18:09:14 -07:00
Sam Lantinga
1162a1cb8e
Added SDL_EVENT_DISPLAY_DESKTOP_MODE_CHANGED and SDL_EVENT_DISPLAY_CURRENT_MODE_CHANGED
2024-07-12 18:09:14 -07:00
SDL Wiki Bot
3f446a12df
Sync SDL3 wiki -> header
2024-07-12 19:42:55 +00:00
Ryan C. Gordon
8779c95905
android: Added SDL_AndroidGetCachePath().
...
Fixes #8408 .
2024-07-12 15:41:54 -04:00
SDL Wiki Bot
d949673bc9
Sync SDL3 wiki -> header
2024-07-12 18:25:57 +00:00
Sam Lantinga
4c88ddf86d
More property documentation clarification
2024-07-12 11:24:40 -07:00
SDL Wiki Bot
cf441332c4
Sync SDL3 wiki -> header
2024-07-12 18:21:05 +00:00
Sam Lantinga
0e56f6a3ca
Clarify property group documentation
...
Fixes https://github.com/libsdl-org/SDL/issues/10241
2024-07-12 11:20:15 -07:00
SDL Wiki Bot
d6fe06bb5d
Sync SDL3 wiki -> header
2024-07-12 17:42:22 +00:00
Sam Lantinga
5bf6bc4d7d
Renamed SDL_Get/SetProperty() to SDL_Get/SetPointerProperty()
...
This is consistent with the naming for the functions that affect other data types
Fixes https://github.com/libsdl-org/SDL/issues/10241
2024-07-12 10:41:02 -07:00
Ryan C. Gordon
bf03dee866
Remove `struct SDL_Camera` predeclare.
...
This is unnecessary and confuses the wiki bridge.
2024-07-12 13:25:06 -04:00
SDL Wiki Bot
f531003776
Sync SDL3 wiki -> header
2024-07-12 15:37:23 +00:00
SDL Wiki Bot
68dfae1322
Sync SDL3 wiki -> header
2024-07-12 15:35:05 +00:00
Sam Lantinga
282cf286fc
SDL_GetPixelFormatName() returns a string
2024-07-12 05:59:45 -07:00
SDL Wiki Bot
50589cbff6
Sync SDL3 wiki -> header
2024-07-12 12:33:26 +00:00
SDL Wiki Bot
f0ceb92dca
Sync SDL3 wiki -> header
2024-07-11 19:01:27 +00:00
Ethan Lee
1993ef664e
Add SDL_Vulkan_GetPresentationSupport
2024-07-11 15:00:59 -04:00
Ryan C. Gordon
af2dbf3ff3
video: Rename SDL_GL_DeleteContext to SDL_GL_DestroyContext.
...
Turns out that there isn't a strong OpenGL naming convention for "Delete" ...
WGL offers "wglDeleteContext" but the GLX equivalent is "glxDestroyContext"
and then EGL sealed the deal by going with Destroy as well! Since it matches
SDL3 naming conventions (Create/Destroy), we're renaming it.
Fixes #10197 .
2024-07-10 15:54:08 -04:00
SDL Wiki Bot
29b0076659
Sync SDL3 wiki -> header
2024-07-10 19:45:01 +00:00
Ryan C. Gordon
4755055bc3
audio: Separate channel maps out of SDL_AudioSpec.
2024-07-10 15:43:57 -04:00
SDL Wiki Bot
fdc04708f1
Sync SDL3 wiki -> header
2024-07-10 07:48:48 +00:00
Sam Lantinga
2ba76dbe80
Simplified SDL_Surface
...
SDL_Surface has been simplified and internal details are no longer in the public structure.
The `format` member of SDL_Surface is now an enumerated pixel format value. You can get the full details of the pixel format by calling `SDL_GetPixelFormatDetails(surface->format)`. You can get the palette associated with the surface by calling SDL_GetSurfacePalette(). You can get the clip rectangle by calling SDL_GetSurfaceClipRect().
SDL_PixelFormat has been renamed SDL_PixelFormatDetails and just describes the pixel format, it does not include a palette for indexed pixel types.
SDL_PixelFormatEnum has been renamed SDL_PixelFormat and is used instead of Uint32 for API functions that refer to pixel format by enumerated value.
SDL_MapRGB(), SDL_MapRGBA(), SDL_GetRGB(), and SDL_GetRGBA() take an optional palette parameter for indexed color lookups.
2024-07-10 00:48:18 -07:00
Sam Lantinga
4fa5196820
Revert "Switch pixel format loss fields to number of bits"
...
This reverts commit 3c90b1c1f6 .
It turns out this is problematic for sdl2-compat. We're investigating a more complete separation between SDL2 and SDL3 surfaces, but in the meantime, I'll fix the breakage.
2024-07-07 19:41:05 -07:00
SDL Wiki Bot
bfa4e71284
Sync SDL3 wiki -> header
2024-07-07 18:05:35 +00:00
SDL Wiki Bot
e37d6f71b3
Sync SDL3 wiki -> header
2024-07-07 18:02:15 +00:00
Sam Lantinga
3c90b1c1f6
Switch pixel format loss fields to number of bits
...
This makes more sense and handles pixel formats with > 8 bits per channel
Fixes https://github.com/libsdl-org/SDL/issues/10168
2024-07-06 11:37:16 -07:00
SDL Wiki Bot
f3ac2d9d4f
Sync SDL3 wiki -> header
2024-07-06 15:46:41 +00:00
Frank Praznik
fbb5652d3e
video: Document that SDL_RaiseWindow is a request and subject to window manager policy
...
The result of SDL_RaiseWindow is ultimately subject to window manager policy, particularly if the request would result in stealing focus from another window. Document that this is only a request, and if successful, will result in a focus gained event along with the input focus flag being set on the window.
2024-07-06 11:45:43 -04:00
Sam Lantinga
0fa74d8aa8
Wiki-compatible documentation for SDL_ALPHA_OPAQUE and SDL_ALPHA_TRANSPARENT
2024-07-06 05:53:40 -07:00
SDL Wiki Bot
d5a0f60963
Sync SDL3 wiki -> header
2024-07-05 15:59:26 +00:00
Sam Lantinga
8412f52853
Clarified that the renderer should be destroyed before the window
...
I didn't add a note to SDL_DestroyWindow() because we actually protect against this case now, but it's useful information to know conceptually when working with the renderer.
2024-07-05 08:57:30 -07:00
SDL Wiki Bot
b43f1688d9
Sync SDL3 wiki -> header
2024-07-04 15:12:07 +00:00
Ryan C. Gordon
c3bf874abf
stdlib: Clean up and export SDL_UCS4ToUTF8().
...
Also fix internal usage of the function.
Fixes #10157 .
2024-07-04 11:10:50 -04:00
Ryan C. Gordon
f338fa20dd
emscripten: Let SDL hints be set by URL parameters.
...
Any parameters (key/value pairs after the '?' in a URL) that have a keyname
that starts with `SDL_` will be put into Emscripten's environment variable
emulation table at startup, before SDL_main runs.
This lets users set hints the same way they might set them from a shell's
command line on a desktop platform:
For example:
`https://example.com/my_sdl3_application.html?SDL_RENDER_DRIVER=software `
Fixes #10154 .
2024-07-04 11:09:42 -04:00
SDL Wiki Bot
d7a875432b
Sync SDL3 wiki -> header
2024-07-03 20:07:11 +00:00
Ryan C. Gordon
2a8f1e11ca
audio: Add gain support to audio streams and logical audio devices.
...
Fixes #10028 .
2024-07-03 16:05:55 -04:00
Frank Praznik
74cc06db1b
Remove the SDL_EVENT_WINDOW_TAKE_FOCUS event
...
This was added by the Unreal Engine to handle the input focus for popups and dialogs, window types for which SDL3 has built-in, cross-platform support.
This was only ever implemented in X11, and the only purpose was to hint that a client application may want to call the SDL_SetWindowInputFocus() function, which has since been removed, rendering it pointless now.
2024-07-03 15:08:21 -04:00
Frank Praznik
be13328cb1
Remove SDL_SetWindowInputFocus
...
This was added to SDL2 for the Unreal Engine's implementation of menus and dialogs on X11, window types for which SDL3 has added built-in, cross-platform support.
Remove this function, as it was only ever implemented for X11 and is now basically useless aside from allowing annoying or malicious client apps to discretely steal focus. As the documentation states: "You almost certainly want SDL_RaiseWindow() instead of this function."
2024-07-03 15:08:21 -04:00
SDL Wiki Bot
98f27b8f2e
Sync SDL3 wiki -> header
2024-07-03 18:39:46 +00:00
Ryan C. Gordon
16e7fdc4f2
audio: Add channel remapping to SDL_AudioSpec and SDL_AudioStream.
...
Fixes #8367 .
2024-07-03 14:38:33 -04:00
SDL Wiki Bot
b948d1446a
Sync SDL3 wiki -> header
2024-07-03 01:35:19 +00:00
Sam Lantinga
ed9bbb2dca
Restore default behavior for keypad keycodes
...
Added a hint to translate numpad keycodes into their non-numpad versions based on the NumLock state
2024-07-02 18:34:35 -07:00
Ryan C. Gordon
e290d16c47
include: Clean up SDL_GetKeyName documentation.
2024-07-02 12:29:33 -04:00
SDL Wiki Bot
f787790243
Sync SDL3 wiki -> header
2024-07-01 20:57:56 +00:00
Sam Lantinga
d4497ecdbd
Numpad scancodes have non-numpad keycodes
...
This allows the numpad to work as the user expects based on the numlock state. If the application needs to distinguish the keys, it can check to see whether the scancode is a numpad key or not.
2024-07-01 13:56:49 -07:00
Sam Lantinga
78dbf9be50
Document that SDL_GetKeyName() always returns uppercase names for alphabetic keycodes
2024-07-01 13:56:49 -07:00
Sam Lantinga
e8dbbf8380
Renamed SDLK_a-z to SDLK_A-Z
...
Made the symbols uppercase for consistency with the other SDLK_* constants, but the values are still lowercase.
2024-07-01 13:56:49 -07:00
Sam Lantinga
d9dc4b320a
The keycode in key events is the base, unmodified, keycode for the current keyboard layout
2024-07-01 13:56:49 -07:00
SDL Wiki Bot
ede4483420
Sync SDL3 wiki -> header
2024-06-29 21:26:31 +00:00
Sam Lantinga
473257cce6
Added SDL_GetRenderLogicalPresentationRect()
...
Fixes https://github.com/libsdl-org/SDL/issues/8815
2024-06-29 14:25:59 -07:00
Sam Lantinga
6f199eabb8
Removed SDL_RenderGeometryRawFloat()
...
After discussion with @ocornut, SDL_RenderGeometryRaw() will take floating point colors and conversion from 8-bit color can happen on the application side. We can always add an 8-bit color fast path in the future if we need it on handheld platforms.
If you need code to do this in your application, you can use the following:
int SDL_RenderGeometryRaw8BitColor(SDL_Renderer *renderer, SDL_Texture *texture, const float *xy, int xy_stride, const SDL_Color *color, int color_stride, const float *uv, int uv_stride, int num_vertices, const void *indices, int num_indices, int size_indices)
{
int i, retval, isstack;
const Uint8 *color2 = (const Uint8 *)color;
SDL_FColor *color3;
if (num_vertices <= 0) {
return SDL_InvalidParamError("num_vertices");
}
if (!color) {
return SDL_InvalidParamError("color");
}
color3 = (SDL_FColor *)SDL_small_alloc(SDL_FColor, num_vertices, &isstack);
if (!color3) {
return -1;
}
for (i = 0; i < num_vertices; ++i) {
color3[i].r = color->r / 255.0f;
color3[i].g = color->g / 255.0f;
color3[i].b = color->b / 255.0f;
color3[i].a = color->a / 255.0f;
color2 += color_stride;
color = (const SDL_Color *)color2;
}
retval = SDL_RenderGeometryRaw(renderer, texture, xy, xy_stride, color3, sizeof(*color3), uv, uv_stride, num_vertices, indices, num_indices, size_indices);
SDL_small_free(color3, isstack);
return retval;
}
Fixes https://github.com/libsdl-org/SDL/issues/9009
2024-06-29 00:10:08 -07:00
SDL Wiki Bot
2cfcb144e4
Sync SDL3 wiki -> header
2024-06-29 02:42:49 +00:00
Sam Lantinga
212a491f7c
Renamed SDL_HINT_IME_NATIVE_UI to SDL_HINT_IME_IMPLEMENTED_UI
...
This inverts the logic to make more sense from an application perspective.
2024-06-28 19:41:37 -07:00
SDL Wiki Bot
9332de9f25
Sync SDL3 wiki -> header
2024-06-29 00:09:51 +00:00
Sam Lantinga
4c7db129df
SDL_HINT_IME_INTERNAL_EDITING and SDL_HINT_IME_SHOW_UI are replaced with SDL_HINT_IME_NATIVE_UI
2024-06-28 17:09:22 -07:00
Sam Lantinga
bdd531986b
SDL_SetTextInputRect() has been renamed to SDL_SetTextInputArea()
...
The new function includes the cursor position so IME UI elements can be placed relative to the cursor, as well as having the whole text area available so on-screen keyboards can avoid it.
2024-06-28 17:09:22 -07:00
Sam Lantinga
ed2022a175
Added SDL_EVENT_TEXT_EDITING_CANDIDATES
...
This allows applications that have set SDL_HINT_IME_SHOW_UI to "0" to get candidates lists they can draw themselves.
Fixes https://github.com/libsdl-org/SDL/issues/4855
2024-06-28 17:09:22 -07:00
Ryan C. Gordon
ecfa363889
begin_code: Solaris Studio has `__has_attribute` defined by isn't usable here.
...
Fixes #10095 .
(cherry picked from commit d96f1d5360 )
2024-06-27 22:13:48 -07:00
Ryan C. Gordon
d7ee9ce455
SDL_endian.h: Fix byte order detection on Solaris (and some SPARC compilers).
...
Fixes #10093 .
(Sort of cherry-picked from 14183f8ecac099982883331ae7e405f82e42aa6b.)
2024-06-28 00:14:26 -04:00
SDL Wiki Bot
b7ab5182d3
Sync SDL3 wiki -> header
2024-06-27 21:37:27 +00:00
Ryan C. Gordon
a9cfcf6bde
stdinc: Drastically improve SDL_StepUTF8() and make it a public API.
...
Fixes #10105 .
2024-06-27 17:36:09 -04:00
Ryan C. Gordon
982feb7a65
vulkan: SDL_Vulkan_CreateSurface now returns the usual int (0=ok, -1=error).
...
Fixes #10091 .
2024-06-27 15:25:10 -04:00
Sam Lantinga
c7f7464174
Updated scancode documentation
2024-06-26 12:33:16 -07:00
Ryan C. Gordon
9fd54b724f
include: Added documentation for SDL_PRESSED and SDL_RELEASED.
...
Fixes #10069 .
2024-06-26 14:08:56 -04:00
SDL Wiki Bot
3d121d9bc7
Sync SDL3 wiki -> header
2024-06-25 03:32:46 +00:00
Sam Lantinga
def7a43a2e
SDL_HINT_IME_SHOW_UI defaults to SDL_TRUE
...
This hint is currently only used on Windows, and this matches the behavior of other platforms.
2024-06-24 20:32:03 -07:00
Sam Lantinga
377014c430
Added some documentation to the SDL_EVENT_TEXT_EDITING event
2024-06-24 20:32:03 -07:00
Anonymous Maarten
d52ea20916
cmake: check for valid isinf/isinff/isnan/isnanf macros
2024-06-24 22:00:53 +02:00
SDL Wiki Bot
ea11c9e0c7
Sync SDL3 wiki -> header
2024-06-24 19:23:37 +00:00
Sam Lantinga
0ff5c05486
Added SDL_GetWindows()
2024-06-24 12:22:12 -07:00
SDL Wiki Bot
2c745dbd3c
Sync SDL3 wiki -> header
2024-06-24 18:50:19 +00:00
Sam Lantinga
2f5b20fcb5
Updated based on feedback from @JKaniarz
2024-06-24 11:49:15 -07:00
Sam Lantinga
a938e2b979
Replaced test framework random code with SDL random functions
2024-06-24 11:49:15 -07:00
Sam Lantinga
96f2f23240
Simplified SDL random function names and added thread-safe versions
2024-06-24 11:49:15 -07:00
Sam Lantinga
89cdadf7c3
Added SDL_isinf(), SDL_isinff(), SDL_isnan(), and SDL_isnanf()
2024-06-24 11:49:15 -07:00
SDL Wiki Bot
410bed20ba
Sync SDL3 wiki -> header
2024-06-24 18:21:18 +00:00
Sam Lantinga
76631a0978
The text input state has been changed to be window-specific.
...
SDL_StartTextInput(), SDL_StopTextInput(), SDL_TextInputActive(), SDL_ClearComposition(), and SDL_SetTextInputRect() all now take a window parameter.
This change also fixes IME candidate positioning when SDL_SetTextInputRect() is called before SDL_StartTextInput(), as is recommended in the documentation.
2024-06-24 11:20:08 -07:00
Anonymous Maarten
5217c040be
Sort possible SDL_KeyCode values (swap SDLK_PERCENT and SDLK_DOLLAR)
2024-06-23 22:52:17 +02:00
Frank Praznik
974bbea20b
x11: Add keymap support
...
XkbKeycodeToKeySym is replaced with XkbLookupKeySym, which can take the modifier states. The associated cmake check has been renamed for consistency.
Only the XKB path is currently handled. The deprecated XKeycodeToKeysym path is TODO.
2024-06-23 15:40:55 -04:00
Sam Lantinga
fd3143f445
Added more documentation for SDL_HINT_MOUSE_RELATIVE_CURSOR_VISIBLE and SDL_HINT_MOUSE_RELATIVE_CLIP_INTERVAL
2024-06-23 00:11:56 -07:00
SDL Wiki Bot
398391b01e
Sync SDL3 wiki -> header
2024-06-23 07:11:23 +00:00
expikr
3b504c4a89
Add SDL_HINT_MOUSE_RELATIVE_CLIP_INTERVAL ( #10085 )
2024-06-23 00:09:59 -07:00
SDL Wiki Bot
ba188e7555
Sync SDL3 wiki -> header
2024-06-22 07:20:00 +00:00
Sam Lantinga
90034b16dc
The keycode in key events is affected by modifiers by default.
...
This behavior can be customized with SDL_HINT_KEYCODE_OPTIONS.
2024-06-22 00:19:06 -07:00
SDL Wiki Bot
1e81424b3d
Sync SDL3 wiki -> header
2024-06-22 05:06:38 +00:00
Sam Lantinga
c9cfa4688e
Use unsigned constants for SDL_Keycode values
...
Fixes https://github.com/libsdl-org/SDL/issues/10020
Closes https://github.com/libsdl-org/SDL/pull/10070
2024-06-21 22:06:08 -07:00
Sam Lantinga
0dd579d40d
Removed SDL_Keysym
2024-06-21 22:06:08 -07:00
Sam Lantinga
679e4471ed
Added the ability to query the keymap for keycodes based on modifier state
2024-06-21 22:06:08 -07:00
Sam Lantinga
ef9bd8b609
Add the raw platform specific key code to SDL_Keysym
...
This allows applications to handle keys that SDL doesn't recognize, in a platform dependent way.
Fixes https://github.com/libsdl-org/SDL/issues/6390
2024-06-21 22:06:08 -07:00
Sam Lantinga
9d816c72ef
Updated SDL3 scancode list
...
This adds more app editing and audio control keys and removes keys that launch applications
Work in progress on https://github.com/libsdl-org/SDL/issues/6390
2024-06-21 22:06:08 -07:00
Sam Lantinga
306c4164bc
Added SDL_AllocateEventString()
2024-06-21 22:06:08 -07:00
Sam Lantinga
fa5367d379
Enable virtual joystick support for Emscripten
2024-06-21 12:06:53 -07:00
SDL Wiki Bot
83933fdfa0
Sync SDL3 wiki -> header
2024-06-20 19:55:37 +00:00
Frank Praznik
2f276a2eea
video: Expose HDR metadata per-window
...
Moves the HDR properties from the display to be per-window, and adds the frog_color protocol to enable HDR under Wayland.
2024-06-20 15:55:07 -04:00
SDL Wiki Bot
e6944584a0
Sync SDL3 wiki -> header
2024-06-20 00:01:27 +00:00
John Kaniarz
8f29f8cae5
Renamed SDL_rand() to SDL_rand_bits() and updated tests
2024-06-19 17:00:58 -07:00
SDL Wiki Bot
237bbfcb9d
Sync SDL3 wiki -> header
2024-06-19 18:02:45 +00:00
John Kaniarz
16e69cb4c9
Removed SDL_rand_r()
2024-06-19 11:02:02 -07:00
John Kaniarz
86b06f74dc
Updated docs
2024-06-19 11:02:02 -07:00
John Kaniarz
83d21e20df
Added SDL_rand_float and SDL_rand_n to API
2024-06-19 11:02:02 -07:00
SDL Wiki Bot
ab98d51b9f
Sync SDL3 wiki -> header
2024-06-19 14:15:46 +00:00
Hubert Maier
81d8fcb5d8
JANITORIAL: Fix judgement typos ( #10059 )
2024-06-19 07:14:58 -07:00
Hubert Maier
3acdb8a90b
JANITORIAL: Fix typos in comments in various files ( #10058 )
2024-06-19 07:13:46 -07:00
Zack Middleton
5ecf125456
Update descriptions for window resize cursors
...
The SIZENWSE, SIZENS, etc cursors were renamed.
2024-06-18 12:22:02 -04:00
Sam Lantinga
d7391394d3
Switched the camera format to use framerate ratio instead of interval ratio
...
This is more intuitive for game developers and users.
Fixes https://github.com/libsdl-org/SDL/issues/9896
2024-06-18 07:39:52 -07:00
Sam Lantinga
aeea819494
Added colorspace to SDL_CameraSpec
2024-06-16 17:47:16 -07:00
Sam Lantinga
182a28b343
Fixed documentation typo
2024-06-16 08:01:16 -07:00
SDL Wiki Bot
4e5ed569c3
Sync SDL3 wiki -> header
2024-06-16 14:42:00 +00:00
Sam Lantinga
d1d484ddbe
Added SDL_srand(), SDL_rand(), and SDL_rand_r() (thanks @JKaniarz!)
...
These are simple random functions that should not be used for serious random number generation.
Fixes https://github.com/libsdl-org/SDL/issues/4968
2024-06-16 07:41:00 -07:00
SDL Wiki Bot
65f0691866
Sync SDL3 wiki -> header
2024-06-16 13:21:56 +00:00
expikr
ee559d51be
Add SDL_MOUSE_RELATIVE_CURSOR_VISIBLE ( #7947 )
2024-06-16 06:21:29 -07:00
Anonymous Maarten
a64960cfc0
SDL_GLContext is not a void* pointer anymore
2024-06-15 14:44:09 +02:00
SDL Wiki Bot
63138c79af
Sync SDL3 wiki -> header
2024-06-15 05:09:09 +00: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
031dc0743f
Use an opaque struct typedef for SDL_GLContext
...
Using a struct typedef instead of a void pointer results in extra C typechecks
2024-06-15 01:43:22 +02:00
Ryan C. Gordon
51902d4ac5
Updated headers with latest wikiheaders tweaks.
2024-06-14 02:09:55 -04:00
Ryan C. Gordon
5bc654aad3
camera: SDL_GetCameraDeviceName() now follows the SDL_GetStringRule.
2024-06-13 18:13:51 -04:00
Ryan C. Gordon
2ad7c70ac6
documentation: clean up a minor syntax issue.
2024-06-13 18:10:28 -04:00
Ryan C. Gordon
466886049c
SDL_main.h: fix up SDL_main_func documentation to match SDL_main.
2024-06-13 18:08:40 -04:00
SDL Wiki Bot
2253c3cacf
Sync SDL3 wiki -> header
2024-06-13 21:49:55 +00:00
Sam Lantinga
0635112119
Added SDL_HINT_WINDOWS_ERASE_BACKGROUND_MODE (thanks @lostgoat!)
2024-06-13 14:54:36 -07:00
SDL Wiki Bot
d46b8bc54e
Sync SDL3 wiki -> header
2024-06-13 21:31:58 +00:00
SDL Wiki Bot
fa3e22c5da
Sync SDL3 wiki -> header
2024-06-13 21:04:27 +00:00
Ryan C. Gordon
12119cbaad
include: Several documentation tweaks; cleaned up new wikiheaders warnings.
2024-06-13 17:03:31 -04:00
SDL Wiki Bot
49f2a3463f
Sync SDL3 wiki -> header
2024-06-13 19:34:29 +00:00
SDL Wiki Bot
674cc04ef4
Sync SDL3 wiki -> header
2024-06-13 02:25:45 +00:00
Sam Lantinga
80a907e0e6
Backed out the viewport and cliprect changes in 9fb5a9ccac
...
This ended up being lots of application code churn without any real benefit in practice.
2024-06-12 19:25:15 -07:00
SDL Wiki Bot
99f0309ac1
Sync SDL3 wiki -> header
2024-06-12 23:34:42 +00:00
SDL Wiki Bot
9e3e489012
Sync SDL3 wiki -> header
2024-06-12 19:10:53 +00:00
Ryan C. Gordon
5416bd5fdc
ios: Move animation callback to its own typedef.
2024-06-12 15:10:16 -04:00
SDL Wiki Bot
5b0f14a936
Sync SDL3 wiki -> header
2024-06-12 17:19:08 +00:00
Sam Lantinga
9fb5a9ccac
Use floating point values for viewport, clip rectangle, and texture sizes
...
These are integer values internally, but the API has been changed to make it easier to mix other render code with querying those values.
Fixes https://github.com/libsdl-org/SDL/issues/7519
2024-06-12 10:18:39 -07:00
SDL Wiki Bot
2d13fefc20
Sync SDL3 wiki -> header
2024-06-12 02:20:21 +00:00
SDL Wiki Bot
a4bb93e8e4
Sync SDL3 wiki -> header
2024-06-12 01:34:03 +00:00
Anonymous Maarten
32907a9606
Rename SDL_Swap(16|32|64)(LE|BE) to SDL_Swap(LE|BE)(16|32|64)
2024-06-12 02:29:39 +02:00
Anonymous Maarten
ef6123886e
Add SDL_ReadS8 and SDL_WriteS8
2024-06-12 01:39:08 +02:00
SDL Wiki Bot
f003461a0b
Sync SDL3 wiki -> header
2024-06-11 16:23:27 +00:00
Ryan C. Gordon
96f2ef77ab
include: Make function pointer params into typedefs.
...
This is easier to read and document in general, but will also make some
new parsing work in wikiheaders much easier.
2024-06-11 12:22:46 -04:00
Ryan C. Gordon
8e782602de
wikiheaders: Fixes and cleanups to fix SDL_ReportAssertion's wiki page.
2024-06-11 11:29:44 -04:00
Sam Lantinga
66aac9aced
Fixed channel order typo
2024-06-10 18:05:31 -07:00
SDL Wiki Bot
454d890bef
Sync SDL3 wiki -> header
2024-06-11 00:57:54 +00:00
Ryan C. Gordon
d3a62d8298
audio: Update docs on channel ordering.
2024-06-10 20:56:50 -04:00
Sam Lantinga
4fc68a48f2
Keep track of whether a controller was a gamepad
...
Fixes https://github.com/libsdl-org/SDL/issues/9996
2024-06-09 17:45:20 -07:00
Ryan C. Gordon
8ddf05855b
iostream: clarified SDL_IO_STATUS_READY documentation.
2024-06-09 13:21:31 -04:00
SDL Wiki Bot
9651ca5918
Sync SDL3 wiki -> header
2024-06-09 05:52:14 +00:00
Ryan C. Gordon
6110405c07
include: Fill in some documentation gaps.
2024-06-09 01:51:30 -04:00
Ryan C. Gordon
7d54a37d74
iostream: Make seeking's `whence` value a real enum.
2024-06-09 01:50:48 -04:00
SDL Wiki Bot
35adef17a8
Sync SDL3 wiki -> header
2024-06-09 05:33:28 +00:00
Ryan C. Gordon
40e8d0155e
SDL_joystick.h: Add some notes to the category documentation.
2024-06-09 01:32:41 -04:00
Ryan C. Gordon
8af58b4bec
SDL_FLT_EPSILON: Updated documentation to be wikiheaders-friendly.
2024-06-08 23:15:21 -04:00
Green Sky
997dd3e6eb
reword SDL_FlashWindow params
...
so they link the types in the wiki
2024-06-08 17:25:27 -04:00
Anthony
e9982bf1b5
Filter Android drivers according to SDL_***_DISABLED macros to help reduce APK size ( #9986 )
2024-06-08 08:55:15 -07:00
Sam Lantinga
e69272344c
Added documentation for SDL_FLT_EPSILON (thanks @MrOnlineCoder!)
...
Closes https://github.com/libsdl-org/sdlwiki/pull/549
2024-06-08 08:29:17 -07:00
SDL Wiki Bot
9a4fc81bff
Sync SDL3 wiki -> header
2024-06-06 17:59:48 +00:00
Sam Lantinga
5701c4f4bc
Added migration documentation for iOS window properties
...
Fixes https://github.com/libsdl-org/SDL/issues/9430
2024-06-06 10:59:15 -07:00
SDL Wiki Bot
a5356f9b45
Sync SDL3 wiki -> header
2024-06-06 17:08:43 +00:00
Sam Lantinga
23db1062fc
Document that you can pass NULL to SDL_PeepEvents()
...
Fixes https://github.com/libsdl-org/sdlwiki/issues/547
2024-06-06 10:08:20 -07:00
Sam Lantinga
9b2debb131
Renamed old function reference
2024-06-04 22:25:37 -07:00
SDL Wiki Bot
e5101ebae6
Sync SDL3 wiki -> header
2024-06-04 04:11:34 +00:00
Sam Lantinga
a0d1445ccb
Replaced SDL_GetRendererInfo() with SDL_GetRendererName()
...
The texture formats are available via the SDL_PROP_RENDERER_TEXTURE_FORMATS_POINTER property
Fixes https://github.com/libsdl-org/SDL/issues/9851
2024-06-03 21:10:58 -07:00
SDL Wiki Bot
74c9c9a325
Sync SDL3 wiki -> header
2024-06-04 01:23:30 +00:00
Semphris
8c8ee2174d
Dialog: Add filter number, remove NULL termination
2024-06-03 18:22:26 -07:00
Sam Lantinga
a9a51cebde
Disable raw keyboard input by default
...
It interferes with keyboard hooks and most applications don't expect key events coming from another thread
2024-06-03 14:43:46 -07:00
SDL Wiki Bot
39c2dacc8f
Sync SDL3 wiki -> header
2024-06-03 18:21:49 +00:00
Ryan C. Gordon
e23257307e
Introduce formal policy for APIs that return strings.
...
This declares that any `const char *` returned from SDL is owned by SDL, and
promises to be valid _at least_ until the next time the event queue runs, or
SDL_Quit() is called, even if the thing that owns the string gets destroyed
or changed before then.
This is noted in the headers as "the SDL_GetStringRule", so this will both be
greppable to find a detailed explaination in docs/README-strings.md and
wikiheaders will automatically turn it into a link we can point at the
appropriate documentation.
Fixes #9902 .
(and several FIXMEs, both known and yet-undocumented.)
2024-06-03 14:20:49 -04:00