Sam Lantinga
fb92d150d9
Removed unused SDL_OSEvent
2023-11-07 09:15:18 -08:00
Sam Lantinga
e8f4045d0b
Use XINPUT_STATE instead of XINPUT_STATE_EX (thanks Andrew!)
...
XINPUT_STATE_EX isn't actually a thing, we can just use the normal XINPUT_STATE
Fixes https://github.com/libsdl-org/SDL/issues/2797
2023-11-04 22:24:55 -07:00
Sam Lantinga
4c2eb6b95d
Use the default UCS2/UCS4 conversion rather than non-portable INTERNAL encoding
...
Fxies https://github.com/libsdl-org/SDL/issues/1497
(cherry picked from commit d07a264a9bc42bd2d92ce12fab55f1855d0e8277)
2023-11-04 12:02:18 -07:00
Ryan C. Gordon
32587bd7de
Sync wiki -> header
2023-10-10 10:19:51 -04:00
Anonymous Maarten
a263cc2369
Allow the use of posix_spawn() instead of vfork/execlp()
...
Backport of #7041
Co-authored-by: elahav <elahav@users.noreply.github.com>
2023-09-30 16:48:51 +02:00
Ryan C. Gordon
25eca09c7e
include: Replaced old Bugzilla URL.
...
(cherry picked from commit fb137703537411b9aa2206351082b87aba23a843)
2023-09-07 10:53:02 -04:00
Jeremy Demeule
aa7ba62978
metal: Add hint to select low power device instead of the default one ( #8182 )
...
On some system like MacBook Pro Intel with AMD card, asking for the default device will always return the AMD GPU.
This is not an issue for 99% of the case when the renderer context is here to provide the maximum performance level like for game.
However, for video application using GPU for 1 quad and 1 texture, using the discrete GPU for that lead to an important power consumption (4 to 8W), heat increase, and fan noise.
With this patch, I successfully amend ffplay to only use the integrated GPU (i.e. the Intel one), instead of the discrete GPU (i.e. the AMD one).
2023-08-31 01:55:18 -07:00
Ethan Lee
24fcb61470
gdk: Add SDL_GDKGetDefaultUser, SDL_GetPrefPath implementation
2023-08-25 10:41:14 -04:00
David CARLIER
4a0f56b679
SDL_TriggerBreakppoint for riscv arch (both 32/64) version.
...
`ebreak` acts like int3 for x86, giving control of running process to debuggers.
(cherry picked from commit 723bcd0a8be4e816f6555b6bbbd5e9c26ab27137)
2023-08-13 23:02:02 +03:00
Anonymous Maarten
64f17314a2
MSVC has __declspec(deprecated)
2023-08-09 02:53:48 +02:00
Ryan C. Gordon
8087c0a5d2
include: fixed a typo in SDL_RenderGetMetalCommandEncoder docs.
2023-08-06 10:45:11 -04:00
Anonymous Maarten
2b0ca87119
SDL_atomic.h: __ARM_ARCH is not always defined for an arm platform
...
e.g. riscos toolchain
(cherry picked from commit 8105f1d5b5b83328f4d0017a562674efca821077)
2023-07-26 20:39:20 +03:00
Sam Lantinga
a6228e7aaf
Added the hint SDL_HINT_JOYSTICK_WGI to control whether to use Windows.Gaming.Input for controllers
2023-07-08 09:34:58 -07:00
Sam Lantinga
ceece918e4
Updated to version 2.29.0 for development
2023-06-20 11:50:19 -07:00
Sam Lantinga
ffa78e6bea
Updated to version 2.28.0 for release
2023-06-20 11:00:20 -07:00
Eric Wasylishen
76392f4fe1
Handle DPI scaling in SDL_GetWindowSurface
...
Fixes DPI awareness of testdrawchessboard (previously, the surface was
being created in points instead of pixels, resulting in the demo app
only drawing in a corner of the screen on High-DPI displays)
*_CreateWindowFramebuffer()/*_UpdateWindowFramebuffer(): are updated
to use SDL_GetWindowSizeInPixels instead of SDL_GetWindowSize() or
window->w/window->h.
Most of the _CreateWindowFramebuffer backends are untested except
for Windows.
Fixes #7047
(cherry picked from commit 67c91353e01f6f2c0cc80c17eeddbad6def7cb01)
2023-06-14 17:23:54 -07:00
Sam Lantinga
d4f9be4416
Updated to version 2.27.1 for release candidate
2023-06-13 19:44:26 -07:00
Sam Lantinga
36033e3832
Make it clear that you can't mix 2D rendering and the window surface API
...
Also added functions to query and destroy the window surface so you can switch between modes if you want.
See https://github.com/pygame-community/pygame-ce/issues/2190 for more details.
2023-06-10 08:54:36 -07:00
Eddy Jansson
2660da6f5c
Always allocate zt in output of SDL_iconv_string()
...
Before this, the function could not be used on buffers,
as it would not account for the zero-termination unless
it was included in the input.
(cherry picked from commit 5f5abb680523e1adedd3fca2a8e252db01fc1c52)
2023-06-04 05:17:15 -07:00
Alibek Omarov
c395240425
hints: clarify support for comma-separated values for QtWayland orientation that's available since 2.0.22
...
Signed-off-by: Alibek Omarov <a1ba.omarov@gmail.com>
2023-06-02 07:41:08 -07:00
Ozkan Sezer
9dea06f5b5
fix mingw build failures in CI with clang-tidy.
...
(cherry-picked from commit a8a72de6fbcf9afe8a6e8760f31a79a0ed6fed1a)
2023-05-26 23:55:04 +03:00
Sam Lantinga
a2f4783e75
Don't map the top keyboard row to numbers when using the one-handed DVORAK layouts (thanks @tormol!)
...
Fixes https://github.com/libsdl-org/SDL/pull/5127
2023-05-22 11:30:42 -07:00
Sam Lantinga
69644346ac
Added the hint SDL_HINT_ENABLE_SCREEN_KEYBOARD to control whether the on-screen keyboard should be shown when text input is active
...
Fixes https://github.com/libsdl-org/SDL/issues/7160
2023-05-20 11:09:36 -07:00
Sam Lantinga
237348c772
Changed all variadic macros into fixed (thanks @Wohlstand!)
2023-05-10 06:29:35 -07:00
Sam Lantinga
707e9397ca
Removed memset_pattern4() from SDL headers
...
This requires including string.h, which isn't always done, so this commit simplifies dependencies on macOS
Fixes https://github.com/libsdl-org/SDL/issues/3657
2023-04-30 21:38:29 -07:00
Sam Lantinga
6d7269815b
Clarified the expected sensor value when a game controller is at rest
...
(cherry picked from commit 1a20ccb2897fc9b12ad5242f9128cb6bb60368b1)
2023-04-06 09:55:43 -07:00
Wohlstand
2aeac8de51
include: Fixed a C++-style single line comment.
...
78725dc0cd
2023-03-29 21:43:15 +00:00
Anonymous Maarten
03c239ded9
testsurround: fix channel names
...
Used table in include/SDL3/SDL_audio.h as reference.
(cherry picked from commit e1b8a032391f4b24453d5bcbe725a35b3894ea5d)
2023-03-28 10:21:35 -07:00
Pierre Wendling
0081174689
Fix clang-tidy error on LLVM 16.
...
Starting LLVM 16, clang-diagnostic-implicit-function-declaration is
treated as an error.
(cherry picked from commit ea093378a29b786edbaa265045638f66d7f83d8b)
2023-03-27 12:51:21 +03:00
Anonymous Maarten
ae3a34a388
byteswap: Don't use intrinsic byteswap functions with Intel C compiler
...
It reroutes intrinsic _byteswap_u(short|long|int64) call to libc function.
2023-03-27 06:13:28 +00:00
Sylvain
7d26ba754a
Simplify SDL_BLENDMODE_MUL
2023-03-16 20:27:09 +01:00
Ozkan Sezer
22de91a947
Removed guard around the enabled assertions support code
...
Otherwise, SDL_assert_always() wouldn't work.
Fixes https://github.com/libsdl-org/SDL/issues/7433
2023-03-09 20:51:50 +03:00
Sam Lantinga
d9c07d9ef7
Fixed the documentation for SDL_SetRelativeMouseMode()
...
(cherry picked from commit fb0c3197e0e4696551822815bdce0e187a0b06fc)
2023-03-08 22:33:23 -08:00
Ryan C. Gordon
7abb748134
Sync wiki -> headers.
2023-02-24 11:47:13 -05:00
Ryan C. Gordon
e6e654e25c
include: Fix symbols in public headers that start with an underscore.
...
Fixes #7352 .
2023-02-20 11:38:26 -05:00
Knightly
a23d1af0ac
Guard against _USE_MATH_DEFINES redefinition
2023-02-12 20:47:00 +03:00
Ozkan Sezer
c68cfcdb2d
make sure to not enable SDL_PASSED_BEGINTHREAD_ENDTHREAD for WinRT
2023-02-07 00:21:56 +03:00
Ozkan Sezer
4f7f72c257
replaced line comments in public header.
2023-02-04 10:02:10 +03:00
Anonymous Maarten
c5035d8ffd
include: add comment documenting the change(s) to SDL_opengl_glext.h
2023-02-04 02:44:37 +01:00
Anonymous Maarten
0dc4373aad
opengl: make SDL_opengl_glext.h's include compatible with macos
...
- Mesa defines __gl_glext_h_
- Apple defines __glext_h_
2023-02-03 21:05:54 +01:00
Ryan C. Gordon
1069c8931d
wikiheaders: Add a \threadsafety
tag to document threading details.
...
Reference Issue #7140 .
(cherry picked from commit 01cba48d18f9002e5aae66d4b009f5f0195dc8d7)
2023-01-26 10:23:08 -05:00
Jiří Malák
507fc462db
SDL_atomic.h: Update SDL_CPUPauseInstruction for Watcom. ( #7157 )
...
Appropriate CPU directive can be used in #pragma aux so that it is not
necessary to hardcode instruction bytes.
2023-01-26 17:00:02 +03:00
Frank Praznik
ea179abdb7
wayland: Enforce or override libdecor minimum window size
...
libdecor plugins can change the min/max window size values internally to enforce a minimum window size, and errors and crashes can result if the window size is below the internal limit.
On versions of libdecor >= 0.1.1, the minimum width and height can be queried and the minimum required window size will be enforced. The application requested window size is still respected, however, the actual window may be slightly larger than the drawable area to accommodate the required libdecor minimum size.
On version 0.1.0 of libdecor, which lacks the function to retrieve the minimum size, the internal limits are overridden before committing a frame, so that the internal limits always match the window size as a workaround, even if the window is technically smaller than the plugin would normally allow.
(cherry picked from commit 423a82cd4b65cf72668551093bfdf58d49bce9ce)
2023-01-22 08:20:34 -08:00
Frank Praznik
44dc90dcc8
autotools: Add check for libdecor get min/max functions
2023-01-18 10:32:43 -08:00
Sam Lantinga
0479df53ca
Updated copyright for 2023
2023-01-09 09:48:21 -08:00
Sam Lantinga
78d3a713de
Fixed documentation for SDL_JoystickGetDeviceInstanceID
...
Fixes https://github.com/libsdl-org/SDL/issues/6946
2022-12-29 15:00:32 -08:00
Ozkan Sezer
d47ff8ae73
SDL_thread.h: fix SDL_CreateThreadWithStackSize macro for OS/2
2022-12-27 00:14:00 +03:00
Ozkan Sezer
738442b82a
SDL_thread.h: fix beginthread param of SDL_CreateThreadWithStackSize for win32
...
(cherry-picked from commit 29ba5f5d6426f36ee84304dc8a0e111416450aab)
2022-12-27 00:11:55 +03:00
Vincent Hamm
68073c6276
Fix SDL_CreateThreadWithStackSize not passing staacksize with win32 static api
2022-12-26 11:22:41 -08:00
Rudolf-Walter Kiss-Szakacs
232ed540db
Add SDL_HINT_WINDOWS_ENABLE_MENU_MNEMONICS.
2022-12-22 08:59:56 -08:00