Commit Graph

10024 Commits (5d50fa52df747ae9d8b2e893dc6309d931bd4ba5)

Author SHA1 Message Date
Ozkan Sezer b8f30c021b SDL_endian.h: check for __powerpc__ and __PPC__ in big endian decision.
Also remove the _M_PPC check from there.
Reference issue: https://github.com/libsdl-org/SDL/issues/5907
2022-07-12 00:55:00 +03:00
SDL Wiki Bot 5d09b63155 Sync SDL wiki -> header 2022-07-11 17:35:11 +00:00
Ethan Lee ecfbdce64b pipewire: Require version 0.3.24 or newer at runtime 2022-07-11 13:34:35 -04:00
Ethan Lee 2f0816adb7 Add SDL_GetDefaultAudioInfo.
This API is supported on pipewire, pulseaudio, wasapi, and directsound.

Co-authored-by: Frank Praznik <frank.praznik@gmail.com>
2022-07-11 13:34:35 -04:00
Ethan Lee 15d0618083 SDL_IMMDevice: Fix a WASAPI-specific leak, clean up Add() 2022-07-11 12:54:34 -04:00
Ethan Lee ae105ae1c7 windows: Move IMMDevice work to common file, implement DirectSound enumeration support 2022-07-11 12:54:34 -04:00
Sam Lantinga 2373da5d94 Exposed SDL_ResetKeyboard() as a public function
This will be used by Source 2 titles to reset keyboard state before showing assertion dialogs
2022-07-11 09:49:00 -07:00
Sam Lantinga 739155c44c We want to ship the CMake input file, not the generated file
Fixes https://github.com/libsdl-org/SDL/issues/5905
2022-07-11 08:55:49 -07:00
Sam Lantinga 2c22d7204c Fixed typo in description 2022-07-11 08:44:49 -07:00
Ozkan Sezer cd2dcf54af regenerated configure script. 2022-07-10 21:10:00 +03:00
Jan Palus 8553632827 autotools: relax soname pattern for dynamic loading
SDL makes assumption that each dynamically loaded library must have
SONAME matching pattern <libname>.so.<digit>+ hence it discards any file
that has two (or more) digits after ".so". in practice however SONAME
might be in the form of ie <libname>.so.<major>.<minor>.

as a solution keep requirement for dynamically loaded files to be named
<libname>.so.* but consider all the possibilities and prefer the shortest
one.
2022-07-10 10:54:29 -07:00
Cameron Gutman 6e712d2440 joystick: Add HIDAPI driver for NVIDIA SHIELD 2017 controller
Basic input already works using the OS HID driver, but this enables
force feedback and battery state reporting.
2022-07-10 10:53:26 -07:00
Cameron Gutman 3242265ff1 joystick: Fix endianness issues in Xbox HIDAPI drivers 2022-07-10 10:49:38 -07:00
Ozkan Sezer 2f21648528 SDL_os2video.c: silenced -Wempty-body warning, along with minor tidy-up. 2022-07-08 20:56:40 +03:00
Sam Lantinga 531647efba Regenerated configure with latest autotools release 2022-07-08 09:46:01 -07:00
285424336 4aad594a8b Update SDL_qsa_audio.c
Fix qnx platform compile error, change SDL_Bool to SDL_bool.
2022-07-08 12:15:00 +03:00
Eric Curtin c0eada2019
Fix assumption that DRI_DEVNAME begins at 0 (#5865)
* Fix assumption that DRI_DEVNAME begins at 0

The existing logic of the code was to count every possible entry in
KMSDRM_DRI_PATH. After this a for loop would start trying to open
filename0, filename1, filename2, etc. In recent Linux kernels (say
5.18) with simpledrm, the lowest KMSDRM_DRI_DEVNAME is often
/dev/dri/card1, rather than /dev/dri/card0, causing the code to fail
once /dev/dri/card0 has failed to open. Running:

modprobe foodrm && modprobe bardrm && rmmod foodrm

before you try to run an application with SDL KMSDRM would have also
made this fail.

* Various changes from review

- Removed newline and period from SDL error
- Explicitely compare memcmp to zero (also changed to SDL_memcmp)
- Changed memcpy to strncpy
- Less aggressive line wrapping

* Various changes from review

- strncpy to SDL_strlcpy
- removed size hardcodings for KMSDRM_DRI_PATHSIZE and
  KMSDRM_DRI_DEVNAMESIZE
- made all KMSDRM_DRI defines, run-time variables to reduce bugs caused
  by these defines being more build-time on Linux and more run-rime on
  OpenBSD
- renamed openbsd69orgreater variable to moderndri
- altered comment from "if on OpenBSD" to add difference in 6.9

* Various changes from review

- Use max size of destination, rather than max size of source
- Less hardcodings
2022-07-06 09:00:16 -07:00
Sam Lantinga adf3ce7c01 Don't drop mouse focus on WM_MOUSELEAVE if the mouse is in relative mode; mouse-level is not meaningful for that case.
Do drop mouse focus when keyboard focus is lost if the mouse is in relative mode.
2022-07-05 21:42:24 -07:00
Sam Lantinga 0253a45029 Fix format specifiers for WPARAM/LPARAM values, they are UINT_PTR. 2022-07-05 21:42:20 -07:00
Sam Lantinga f5cbc440e3 Merge commit 'ad0b91302d34336f8af8787fefeeddb553606ec6' into main 2022-07-05 21:41:34 -07:00
Sam Lantinga 001969b324 Merge commit '98411c0d338933e75221cc9c25bf3d5b9ec977b9' into main 2022-07-05 21:41:32 -07:00
Sam Lantinga b76393f1fe Merge commit '6187edd41e318f9c434ba178fb32a8ef2b07e5da' into main 2022-07-05 21:41:30 -07:00
Sam Lantinga d16a7bb9dc Merge commit 'fdb86b8266947e225f058b32ebb77fa949f6ae42' into main 2022-07-05 21:41:28 -07:00
Sam Lantinga c36025322f Merge commit 'b085c18251bc0298b1a78a621025978702ca07f7' into main 2022-07-05 21:41:26 -07:00
Sam Lantinga 8db084d5e7 Merge commit '51f75b8b309992252a1e18643e310f2774dec4ef' into main 2022-07-05 21:41:24 -07:00
Sam Lantinga 21437ad3f8 Merge commit 'fcb99d783090cc15bc04cdebe877ab36a3697e3d' into main 2022-07-05 21:41:22 -07:00
Sam Lantinga 8d7ea151b4 Merge commit '85bbf8eec9f5e422447807b6cabec8c9ec0859d9' into main 2022-07-05 21:41:20 -07:00
Sam Lantinga b0c9139783 Merge commit '643f9e56d03d8be9adf774c4931fe95742225006' into main 2022-07-05 21:41:19 -07:00
Sam Lantinga e09233cd2e Merge commit '7d7c5b803cecdb87673b824103e4c1c0b3e29fac' into main 2022-07-05 21:41:17 -07:00
Sam Lantinga 9221840280 Merge commit '2a25b69ba580ff63ede93f2b19fa1bca09dab484' into main 2022-07-05 21:41:15 -07:00
Sam Lantinga c218b55c67 Merge commit '0a600b1df45558c16812995aa2c03f0b5f636afb' into main 2022-07-05 21:41:13 -07:00
Sam Lantinga 89c393306d Merge commit 'cd79e9c4e25ffd15010953b15ae8cbc25b7e7a90' into main 2022-07-05 21:41:11 -07:00
Sam Lantinga 23ff1c605a Merge commit 'f317d619ccd22e60cebf1b09d716d3985359c981' into main 2022-07-05 21:41:09 -07:00
Sam Lantinga 95405d9625 Merge commit '0025621b8064f5c72561d5d7b7a1fbdde860c236' into main 2022-07-05 21:39:44 -07:00
Sam Lantinga 4615494f9d Merge commit '391dd0d94b625ae9f7edec2b7514a2f6ba9fb670' into main 2022-07-05 21:39:42 -07:00
Sam Lantinga 85d6d83b6c Merge commit '89624485ccffa9e9b9f1743d431034297daaf251' into main 2022-07-05 21:39:40 -07:00
Sam Lantinga a9a79ddfb1 Merge commit 'e9d5060c4c2df66e8d4ef4f748f80e8ef32fc233' into main 2022-07-05 21:39:38 -07:00
Sam Lantinga 91c7329ce1 Merge commit '209f457ea4eed6a2a3816f42049a17101c049d9c' into main 2022-07-05 21:39:36 -07:00
Sam Lantinga acc03716ea Merge commit 'bdbf90e3fc27c123e699c03f54de3e35e51861dc' into main 2022-07-05 21:39:35 -07:00
Sam Lantinga 6d3ce729a6 Merge commit '7ac5d616f3732b4d98010331d2ae0a24f883092d' into main 2022-07-05 21:39:33 -07:00
Sam Lantinga 7ef298f7c7 Merge commit '37a517dc36b7ba8f703c82a408bef6e44e5786ba' into main 2022-07-05 21:39:31 -07:00
Sam Lantinga 6b0e1adfe9 Merge commit '78089e6598240178b62d6720eec041cc698a5e7c' into main 2022-07-05 21:39:29 -07:00
Sam Lantinga fbc9800304 Merge commit '3e114872e842879c048b2a7808f2cdbfeb2228fe' into main 2022-07-05 21:39:27 -07:00
Sam Lantinga d514f24839 Merge commit '4f732197947d39cf13b4e3de1811d9bcace3798c' into main 2022-07-05 21:39:25 -07:00
Sam Lantinga eaeaf55fc2 Merge commit '24251fb5442296b8066ccc7af6cda430bf2017db' into main 2022-07-05 21:39:23 -07:00
Eddy Jansson ad0b91302d android: Add missing entries to SDL_category_prefixes table.
Add static assert so this shouldn't happen in the future.

Fixes #5883
2022-07-05 17:50:19 -07:00
Chris Mumford 98411c0d33 Added include: libkern/OSAtomic.h
When building on macOS without gcc (e.g. clang) where HAVE_GCC_ATOMICS
is not defined, `SDL_AtomicTryLock` will call
`OSAtomicCompareAndSwap32Barrier` which is not yet declared.
Including OSAtomic.h on OSX resolves this error/warning:

    SDL_spinlock.c:125:12: error: implicit declaration of function
      'OSAtomicCompareAndSwap32Barrier' is invalid in
      C99 [-Werror,-Wimplicit-function-declaration]
        return OSAtomicCompareAndSwap32Barrier(0, 1, lock);

This was reported in issue #3885 but marked Invalid and closed - possibly
because the default CMake build uses gcc instead of clang.
2022-07-05 07:50:57 -07:00
SDL Wiki Bot 6187edd41e Sync SDL wiki -> header 2022-07-04 23:57:05 +00:00
Ryan C. Gordon fdb86b8266
x11: Don't try to use XInput2 multitouch if not supported.
Fixes #5889.
2022-07-04 12:48:32 -04:00
rohlem b085c18251 make SDL_SetTextInputRect take a pointer to const
The documentation doesn't state that the argument is ever modified,
and no implementation does so currently.
This is a non-breaking change to guarantee as much to callers.
2022-07-04 09:38:01 -07:00