Ryujinx-SDL/src/joystick
Sam Lantinga d97387ccff Fixed bug 4600 - Dualshock 4 touchpad press is not detectable with SDL_JoystickGetButton
Dexter Friedman

When using a Dualshock 4 controller (model numbers CUH-ZCT1U and CUH-ZCT2U), pressing anywhere on the center touchpad does not send an SDL_JOYBUTTONDOWN event. I have verified this with testjoystick:

Repro steps:
1. Plug in a DS4 over USB
2. Compile testjoystick and run: testjoystick.exe 0
3. Press and hold the touchpad. Observe that no lime green box appears

Expected behavior:
A lime green box appears while the touchpad is pressed.

Notes:
I've attached a patch here that works on my PC and produces the expected behavior in testjoystick, for both DS4 model numbers I listed earlier.

If I understand correctly, by exposing this as a joystick button, the gamecontroller API mapping can be modified with a change to gamecontrollerdb.txt in the future.
2019-06-08 14:32:19 -07:00
..
android Updated copyright for 2019 2019-01-04 22:01:14 -08:00
bsd Fixed bug 4436 - [OpenBSD] fix D-pad 2019-05-19 11:56:26 -07:00
darwin Updated copyright for 2019 2019-01-04 22:01:14 -08:00
dummy Updated copyright for 2019 2019-01-04 22:01:14 -08:00
emscripten Emscripten: call emscripten_sample_gamepad_data 2019-01-29 12:19:00 +00:00
haiku Updated copyright for 2019 2019-01-04 22:01:14 -08:00
hidapi Fixed bug 4600 - Dualshock 4 touchpad press is not detectable with SDL_JoystickGetButton 2019-06-08 14:32:19 -07:00
iphoneos Added support for the Rotor Riot gamepad, and upcoming Xbox and PS4 controller support on iOS and tvOS 2019-06-06 08:20:53 -07:00
linux Updated copyright for 2019 2019-01-04 22:01:14 -08:00
psp Updated copyright for 2019 2019-01-04 22:01:14 -08:00
steam Updated copyright for 2019 2019-01-04 22:01:14 -08:00
windows Updated copyright for 2019 2019-01-04 22:01:14 -08:00
controller_type.h hidapi: Add support for Wii U/Switch USB GameCube controller adapter. 2019-03-12 20:27:54 -04:00
SDL_gamecontroller.c Fix polling left trigger reporting right trigger's values. 2019-03-16 18:12:26 -07:00
SDL_gamecontrollerdb.h Added support for the Rotor Riot gamepad, and upcoming Xbox and PS4 controller support on iOS and tvOS 2019-06-06 08:20:53 -07:00
SDL_joystick_c.h hidapi: Add support for Wii U/Switch USB GameCube controller adapter. 2019-03-12 20:27:54 -04:00
SDL_joystick.c Potential fix for a crash we're seeing on Android that should in theory never happen. 2019-06-07 09:00:24 -07:00
SDL_sysjoystick.h hidapi: Add support for Wii U/Switch USB GameCube controller adapter. 2019-03-12 20:27:54 -04:00
sort_controllers.py Revert SDL_gamecontrollerdb.h and sort_controllers.py from bug 4024 2019-01-21 20:49:08 +01:00