|
d59caffe
|
2022-12-13T14:03:40
|
|
Added support for clang thread-safety analysis
The annotations have been added to SDL_mutex.h and have been made public so applications can enable this for their own code.
Clang assumes that locking and unlocking can't fail, but SDL has the concept of a NULL mutex, so the mutex functions have been changed not to report errors if a mutex hasn't been initialized. We do have mutexes that might be accessed when they are NULL, notably in the event system, so this is an important change.
This commit cleans up a bunch of rare race conditions in the joystick and game controller code so now everything should be completely protected by the joystick lock.
To test this, change the compiler to "clang -Wthread-safety -Werror=thread-safety -DSDL_THREAD_SAFETY_ANALYSIS"
|
|
b8d85c69
|
2022-11-30T12:51:59
|
|
Update for SDL3 coding style (#6717)
I updated .clang-format and ran clang-format 14 over the src and test directories to standardize the code base.
In general I let clang-format have it's way, and added markup to prevent formatting of code that would break or be completely unreadable if formatted.
The script I ran for the src directory is added as build-scripts/clang-format-src.sh
This fixes:
#6592
#6593
#6594
(cherry picked from commit 5750bcb174300011b91d1de20edb288fcca70f8c)
|
|
fb0ce375
|
2022-11-27T17:38:43
|
|
Cleanup add brace (#6545)
* Add braces after if conditions
* More add braces after if conditions
* Add braces after while() conditions
* Fix compilation because of macro being modified
* Add braces to for loop
* Add braces after if/goto
* Move comments up
* Remove extra () in the 'return ...;' statements
* More remove extra () in the 'return ...;' statements
* More remove extra () in the 'return ...;' statements after merge
* Fix inconsistent patterns are xxx == NULL vs !xxx
* More "{}" for "if() break;" and "if() continue;"
* More "{}" after if() short statement
* More "{}" after "if () return;" statement
* More fix inconsistent patterns are xxx == NULL vs !xxx
* Revert some modificaion on SDL_RLEaccel.c
* SDL_RLEaccel: no short statement
* Cleanup 'if' where the bracket is in a new line
* Cleanup 'while' where the bracket is in a new line
* Cleanup 'for' where the bracket is in a new line
* Cleanup 'else' where the bracket is in a new line
(cherry picked from commit 6a2200823c66e53bd3cda4a25f0206b834392652 to reduce conflicts merging between SDL2 and SDL3)
|
|
efdb390c
|
2022-10-09T09:11:33
|
|
Disable the HIDAPI Wii driver by default as it doesn't work with the dolphinbar
|
|
2c518747
|
2022-09-27T09:56:02
|
|
Added microsecond timestamp to sensor values for PS4 and PS5 controllers using the HIDAPI driver
|
|
1d34a524
|
2022-09-23T00:38:23
|
|
Fixed shadowed variable warning
|
|
aa2e2f48
|
2022-09-22T18:22:17
|
|
Make sure HID devices can be opened before making them available to the application
This prevents a number of issues where devices are enumerated but not actually able to be opened, like https://github.com/libsdl-org/SDL/issues/5781.
We currently leave the devices open, allowing us to more easily do controller feature detection, protocol negotiation, detect dropped Bluetooth connections, etc. with the expectation that the application is likely to open the controllers shortly.
|
|
7f415ce5
|
2022-09-12T20:09:00
|
|
android: fix some compiler warnings
|
|
d93f9a77
|
2022-09-07T12:33:43
|
|
The new Wii Remote shares the same VID/PID as the Wii U Pro controller
|
|
87f8b6ff
|
2022-09-07T01:21:01
|
|
Don't mess with the state of the Motion Plus extension on Linux
|
|
c28da489
|
2022-09-07T00:52:40
|
|
Fixed build
|
|
638452ec
|
2022-09-07T00:44:13
|
|
Assert that continuous reporting is enabled, so input timeout is a reliable way of detecting Bluetooth connection problems.
|
|
8dfe0e4b
|
2022-09-07T00:41:29
|
|
Removed checks not needed for the Wii U Pro Controller
|
|
4018f35e
|
2022-09-07T00:00:27
|
|
Added left and right sensors for Nintendo Joy-Con and Wii controllers
|
|
30f55a5d
|
2022-09-06T23:33:55
|
|
Added initial support for the Wii Motion Plus extension
This adds a gyro sensor to the Wii controller, and is enabled in standalone and nunchuk mode
|
|
d1fea10c
|
2022-09-05T16:08:15
|
|
Added support for the accelerometer in the Wii Remote
|
|
a61b823d
|
2022-09-05T14:31:25
|
|
Added support for the Wii Remote with the Classic Controller Pro extension
Also changed event order to: buttons, triggers, axes, for consistency with other drivers
|
|
253f6a91
|
2022-09-02T11:49:06
|
|
Variable renaming for consistency
|
|
5002624e
|
2022-09-02T11:41:19
|
|
Fixed crash when extension controllers are hotplugged
|
|
b6d23d21
|
2022-09-02T11:21:51
|
|
Fixed interactions with the Linux Wiimote driver
|
|
0c984360
|
2022-09-02T20:02:56
|
|
SDL_hidapi_wii.c: fix a -Wshadow warning
|
|
b6b3fb00
|
2022-09-02T09:59:32
|
|
This was intended to be Uint8
|
|
5be157b3
|
2022-09-02T19:33:40
|
|
SDL_hidapi_wii.c: fix -Wpointer-sign warnings
|
|
54356f41
|
2022-09-02T09:03:44
|
|
Wii: fixed trigger axis reporting for the Wii U Pro Controller
|
|
a35642fa
|
2022-09-02T08:58:21
|
|
Wii: don't bother reading the extension type for the Wii U Pro controller, we already know what it is
|
|
c3ecb9d0
|
2022-09-02T08:48:36
|
|
Wii: re-request the status if we get a communication error
|
|
0c24b46e
|
2022-09-02T18:55:00
|
|
SDL_hidapi_wii.c: fix build in c89 mode.
|
|
9874fc4e
|
2022-09-02T08:47:15
|
|
Reconnect as a different controller if the Wii extension hardware changes
|
|
5f3cb549
|
2022-09-02T08:28:28
|
|
Updated Wii support with @tellowkrinkle's changes in https://github.com/tellowkrinkle/SDL/commit/2f288e9d5bf596756f92b6c3c983b79dc783eac6
|
|
785d784a
|
2022-09-01T22:30:05
|
|
Set the output value for ParseExtensionResponse() in all return cases
|
|
046aaa2d
|
2022-09-01T21:37:26
|
|
Use auto calibration for the Wii Nunchuk thumbstick axis values
|
|
8381e008
|
2022-09-01T21:13:16
|
|
Handle hotplugging of Wii controller extensions
|
|
396411c0
|
2022-09-01T20:27:34
|
|
Added mapping for the Wii Nunchuk extension
|
|
e19b36d8
|
2022-09-01T19:29:20
|
|
Initial support for the Wii Remote with Nunchuk extension
|
|
c887cb02
|
2022-09-01T16:23:32
|
|
Added the hint SDL_HINT_JOYSTICK_HIDAPI_WII_PLAYER_LED to control whether the player LED should be lit on the Nintendo Wii controllers
Also fixed the Y axes on the Wii U Pro controller, and various formatting cleanup
|
|
0ffaf5b8
|
2022-09-02T02:04:20
|
|
SDL_hidapi_wii.c: fix build in c89 mode and builds using watcom compiler
|
|
c72e14e8
|
2022-09-01T15:29:01
|
|
Added initial support for Wii controllers (thanks @tellowkrinkle!)
|