mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-10-03 16:36:25 +00:00
Added support for the Steam Virtual Gamepad on macOS Sequoia
This commit is contained in:
@@ -3090,6 +3090,15 @@ bool SDL_IsJoystickNVIDIASHIELDController(Uint16 vendor_id, Uint16 product_id)
|
||||
product_id == USB_PRODUCT_NVIDIA_SHIELD_CONTROLLER_V104));
|
||||
}
|
||||
|
||||
bool SDL_IsJoystickSteamVirtualGamepad(Uint16 vendor_id, Uint16 product_id, Uint16 version)
|
||||
{
|
||||
#ifdef SDL_PLATFORM_MACOS
|
||||
return (vendor_id == USB_VENDOR_MICROSOFT && product_id == USB_PRODUCT_XBOX360_WIRED_CONTROLLER && version == 0);
|
||||
#else
|
||||
return (vendor_id == USB_VENDOR_VALVE && product_id == USB_PRODUCT_STEAM_VIRTUAL_GAMEPAD);
|
||||
#endif
|
||||
}
|
||||
|
||||
bool SDL_IsJoystickSteamController(Uint16 vendor_id, Uint16 product_id)
|
||||
{
|
||||
EControllerType eType = GuessControllerType(vendor_id, product_id);
|
||||
|
Reference in New Issue
Block a user