Function sdl2_sys::SDL_IsGameController
source · pub unsafe extern "C" fn SDL_IsGameController(
joystick_index: c_int,
) -> SDL_bool
Expand description
Check if the given joystick is supported by the game controller interface.
joystick_index
is the same as the device_index
passed to
SDL_JoystickOpen().
\param joystick_index the device_index of a device, up to SDL_NumJoysticks() \returns SDL_TRUE if the given joystick is supported by the game controller interface, SDL_FALSE if it isn’t or it’s an invalid index.
\since This function is available since SDL 2.0.0.
\sa SDL_GameControllerNameForIndex \sa SDL_GameControllerOpen