mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-11-15 06:48:49 +00:00
Add vertical mode for Nintendo Joy-Con (#6303)
* Added support for vertical mode for Joy-Con controllers * Added the hint SDL_HINT_JOYSTICK_HIDAPI_VERTICAL_JOY_CONS for switching to this mode * Added support for SL/SR buttons in combined/vertical mode and L/ZL/R/ZR buttons in mini-gamepad mode
This commit is contained in:
@@ -672,6 +672,17 @@ extern "C" {
|
||||
*/
|
||||
#define SDL_HINT_JOYSTICK_HIDAPI_COMBINE_JOY_CONS "SDL_JOYSTICK_HIDAPI_COMBINE_JOY_CONS"
|
||||
|
||||
/**
|
||||
* \brief A variable controlling whether Nintendo Switch Joy-Con controllers will be in vertical mode when using the HIDAPI driver
|
||||
*
|
||||
* This variable can be set to the following values:
|
||||
* "0" - Left and right Joy-Con controllers will not be in vertical mode (the default)
|
||||
* "1" - Left and right Joy-Con controllers will be in vertical mode
|
||||
*
|
||||
* This hint must be set before calling SDL_Init(SDL_INIT_GAMECONTROLLER)
|
||||
*/
|
||||
#define SDL_HINT_JOYSTICK_HIDAPI_VERTICAL_JOY_CONS "SDL_JOYSTICK_HIDAPI_VERTICAL_JOY_CONS"
|
||||
|
||||
/**
|
||||
* \brief A variable controlling whether the HIDAPI driver for Amazon Luna controllers connected via Bluetooth should be used.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user