Sam Lantinga
483a010f0c
Fixed accidentally deadlocking the rumble thread with combined Joy-Cons
...
Also added more accurate check for sensor data. At least one axis will always have acceleration because of gravity.
2022-08-09 15:39:39 -07:00
Sam Lantinga
5d63a3d435
Re-enumerate devices if a read fails
...
This allows combined Joy-Con devices to immediately separate if one of them is disconnected
2022-08-09 14:06:49 -07:00
Sam Lantinga
da50f1bd3e
Bluetooth devices can recover from over a second of dropped reports
2022-08-09 14:05:43 -07:00
Sam Lantinga
824f2d4650
Added a second hint SDL_HINT_JOYSTICK_HIDAPI_JOYCON_HOME_LED to control the Home button LED on Nintendo Joy-Con controllers separately from Nintendo Switch Pro controllers
2022-08-09 13:41:58 -07:00
Sam Lantinga
8aa6922fec
Fixed detecting Bluetooth disconnection on Nintendo Switch controllers
2022-08-09 13:26:10 -07:00
Ryan C. Gordon
3a9295e14f
build-scripts: Removed winrtbuild.*, no longer used.
...
WinRT/UWP is still supported, but you have to use the VS2019
project files, now.
Fixes #5639 .
2022-08-09 16:17:28 -04:00
Anonymous Maarten
53141a56b4
Expand CMake documentation a bit ( #5961 )
...
* cmake: remove duplicate check_required_components macro
* Expand docs/README-cmake.md a bit
* cmake: path needs `/` infix
2022-08-09 13:05:03 -07:00
Ryan C. Gordon
a346c4bbef
egl: Add support for SDL_GL_FLOATBUFFERS.
...
Fixes #6001 .
2022-08-09 15:41:02 -04:00
Sam Lantinga
201484ff6f
Don't duplicate the serial number twice if a child doesn't set one
2022-08-09 09:03:28 -07:00
Sam Lantinga
d90c0d41cc
Include the child serial numbers in the serial number for a HIDAPI combined device
2022-08-09 09:00:56 -07:00
SDL Wiki Bot
523bedac1a
Sync SDL wiki -> header
2022-08-09 15:48:12 +00:00
Sam Lantinga
aad2df7f0d
Document passing -1 to clear the player index for a controller
2022-08-09 08:47:49 -07:00
Ryan C. Gordon
8695d982d2
README-winrt.md: Updates for newer build details.
2022-08-09 10:09:54 -04:00
Ryan C. Gordon
b599205d0c
x11: Don't look up xinput2 devices unless we're in relative mode.
2022-08-09 09:50:55 -04:00
Ryan C. Gordon
2dd7659884
test: Fixed wrong arguments to SDL_SetWindowFullscreen.
2022-08-09 09:29:30 -04:00
Ryan C. Gordon
07b0ec539f
SDL_video.h: Added \since info to new APIs.
2022-08-09 09:05:08 -04:00
Sam Lantinga
55882e43c4
Fixed invalid read when SDL_GameControllerSetPlayerIndex() is passed a negative player_index
2022-08-09 00:19:02 -07:00
Sam Lantinga
df537a7c0e
SDL_GameControllerSetPlayerIndex(gamecontroller, -1) means turn off the player LED if possible
2022-08-09 00:18:19 -07:00
Sam Lantinga
5545be8530
The player LED index wraps for PS5 controllers, like it does for other controller types
2022-08-08 23:44:50 -07:00
Sam Lantinga
593d20d9cc
Removed debug logging
2022-08-08 20:11:43 -07:00
Sam Lantinga
6204ae5002
Restart the IMU if the controller stops sending gyro/accel data
2022-08-08 20:10:12 -07:00
Ryan C. Gordon
56c1481cab
cocoa: Don't mark fullscreen-desktop windows as non-resizable.
...
Otherwise, we can't tile SDL apps in Spaces.
Fixes #4883 .
2022-08-08 20:35:11 -04:00
Sam Lantinga
d58bec72a0
Fixed Joy-Con gyro axes in mini-gamepad mode
2022-08-08 17:19:33 -07:00
Shawn Hoffman
5aa438e80a
WGI: fix interop with applications that have their own WGI code
...
QI for Added/Removed events need to handle IAgileObject
2022-08-08 15:53:57 -07:00
Sam Lantinga
ada55c690d
Fixed Joy-Con type detection for the Nintendo Joy-Con Charging Grip
2022-08-08 15:38:19 -07:00
Ryan C. Gordon
a35cff634b
Sync wiki -> headers.
...
(bridge got stuck, I'm just kicking it to get it working again, idk.)
2022-08-08 16:07:31 -04:00
Sam Lantinga
a547c185ce
Fixed crash if uevent info isn't available
2022-08-08 12:21:40 -07:00
Sam Lantinga
7530bd74b3
Fix right, bottom computation in `SDL_GetClosestPointOnRect` which should be exclusive, not inclusive
2022-08-08 11:26:55 -07:00
Sam Lantinga
98bac00dcc
Add `SDL_GetPointDisplayIndex` and `SDL_GetRectDisplayIndex` and re-implement `SDL_GetWindowDisplayIndex` in terms of `SDL_GetRectDisplayIndex`
...
- This allows looking up the display index for an arbitrary location rather than requiring an active window to do so.
- This change also reimplements the fallback display lookup that found the display with center closest to the window's center to instead find the display rect edge
closest to the window center (this was done in the almost identical display lookup used in SDL_windowsmodes.c, which now uses `SDL_GetPointDisplayIndex`). In
practice this should almost never be hit as it requires the window's center to not be enclosed by any display rect.
2022-08-08 11:26:52 -07:00
Francisco Javier Trujillo Mata
20f9a1b8a4
Implement SetTextureScaleMode
2022-08-08 09:34:08 -07:00
Sam Lantinga
47ebf0087a
Fixed shadow variable warning
2022-08-08 08:36:17 -07:00
Francisco Javier Trujillo Mata
d355ea9981
Add a way to avoid IOP reset
2022-08-08 08:32:38 -07:00
Francisco Javier Trujillo Mata
c5fe234d53
Improve SDL main adding usb drivers
2022-08-08 08:32:38 -07:00
Francisco Javier Trujillo Mata
0a307628e6
Fix wrong mapping in some ps2 controller keys
2022-08-08 08:32:11 -07:00
Aaron Barany
3f19e36d12
Disable declaration-after-statement warning on Android
...
External .c files are brought in that don't adhere to this requirement for
pre-C99 code and causes the build to break with the latest NDK.
Fixes #6019
2022-08-08 08:31:40 -07:00
Adam Butcher
0bcbdfe2bd
video: dummy: Support evdev psuedo-device with no video.
2022-08-08 08:31:04 -07:00
Sam Lantinga
8f05b4f833
Fixed iOS/tvOS build
2022-08-08 08:26:21 -07:00
Sam Lantinga
878259722f
Added SDL_GameControllerType enumeration for Nintendo Switch Joy-Con controllers
2022-08-08 08:22:20 -07:00
Sam Lantinga
4f19421ed8
Fixed build
2022-08-07 20:17:40 -07:00
Sam Lantinga
29265d0738
Use SDL_GetStringBoolean() to parse the hint value
2022-08-07 18:49:30 -07:00
Adam Butcher
8f5932dc2e
evdev: Support user-provided devices via SDL_EVDEV_DEVICES in non-udev mode.
2022-08-07 16:37:07 -07:00
Pierre Wendling
f790fc4fc0
Add contributing guidelines.
2022-08-07 16:34:52 -07:00
Sam Lantinga
198d62d813
joystick: remove unused Xbox Controller Keyboard VID/PID.
...
0x045e, 0x0b02 - is actually virtual keyboard that is generated by XboxGip drivers for Xbox One Controllers.
Closes https://github.com/libsdl-org/SDL/pull/5121
2022-08-06 23:53:18 -07:00
Sam Lantinga
2909f63743
Revert "Enable bitcode by default for iOS and tvOS builds"
...
This reverts commit 59963473ef
.
This fixes https://github.com/libsdl-org/SDL/issues/6015
Starting with Xcode 14, bitcode is no longer required for watchOS and tvOS applications, and the App Store no longer accepts bitcode submissions from Xcode 14.
Xcode no longer builds bitcode by default and generates a warning message if a project explicitly enables bitcode: “Building with bitcode is deprecated. Please update your project and/or target settings to disable bitcode.” The capability to build with bitcode will be removed in a future Xcode release. IPAs that contain bitcode will have the bitcode stripped before being submitted to the App Store. Debug symbols for past bitcode submissions remain available for download. (86118779)
2022-08-06 23:28:39 -07:00
Frank Praznik
dd2e318211
wayland: Use libdecor visibility toggle for hiding/showing the window
...
The current method of toggling the libdecor window visibility by destroying and recreating the frame results in a race where a use-after-free bug can manifest itself within libdecor when window visibility is toggled quickly. Instead, use the libdecor function for toggling visibility instead of destroying and recreating the frame every time.
2022-08-06 12:12:21 -07:00
Francisco Javier Trujillo Mata
fbb440d167
Invalidate texture in the UnlockTextureMethod
2022-08-06 12:11:34 -07:00
Sam Lantinga
52bf5b1de9
Added the hint SDL_HINT_JOYSTICK_HIDAPI_SWITCH_PLAYER_LED to control whether the player LED is set on Nintendo Switch controllers
2022-08-06 10:34:19 -07:00
Sam Lantinga
f810dede16
Fixed comment so script processing works correctly
2022-08-06 09:50:13 -07:00
SDL Wiki Bot
bdaf9a92a6
Sync SDL wiki -> header
2022-08-06 13:25:12 +00:00
Ryan C. Gordon
f600364b8a
wayland: Mark window as MOUSE_CAPTURE while a mouse button is down.
...
Wayland works like SDL's "auto capture" feature already, tracking the mouse
globally only while a drag is occuring, and this is the only way to get mouse
input outside the window.
Setting this flag ourselves lets SDL_CaptureMouse() work in the most common
use case without actually implementing CaptureMouse for the backend, including
SDL's auto capture feature.
Fixes #6010 .
2022-08-06 09:19:52 -04:00