mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-06-04 19:07:40 +00:00
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.
This commit is contained in:
parent
3242265ff1
commit
6e712d2440
15 changed files with 499 additions and 3 deletions
|
@ -634,6 +634,10 @@ static ControllerMapping_t *SDL_CreateMappingForHIDAPIController(SDL_JoystickGUI
|
|||
/* The Google Stadia controller has a share button and a Google Assistant button */
|
||||
SDL_strlcat(mapping_string, "misc1:b15,", sizeof(mapping_string));
|
||||
break;
|
||||
case SDL_CONTROLLER_TYPE_NVIDIA_SHIELD:
|
||||
/* The NVIDIA SHIELD controller has a home button between back and start buttons */
|
||||
SDL_strlcat(mapping_string, "misc1:b15,", sizeof(mapping_string));
|
||||
break;
|
||||
default:
|
||||
if (vendor == 0 && product == 0) {
|
||||
/* This is a Bluetooth Nintendo Switch Pro controller */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue