Scroll to navigation

SDL_GetGamepadBindForButton(3) SDL3 FUNCTIONS SDL_GetGamepadBindForButton(3)

NAME

SDL_GetGamepadBindForButton - Get the SDL joystick layer binding for a gamepad button mapping.

SYNOPSIS

#include "SDL3/SDL.h"
SDL_GamepadBinding SDL_GetGamepadBindForButton(SDL_Gamepad *gamepad, SDL_GamepadButton button);

FUNCTION PARAMETERS

a gamepad
an button enum value (an SDL_GamepadButton
value)

RETURN VALUE

Returns a SDL_GamepadBinding
describing the bind. On failure (like the given Controller button doesn't exist on the device), its .bindType will be

SDL_GAMEPAD_BINDTYPE_NONE .

AVAILABILITY

This function is available since SDL 3.0.0.

SEE ALSO

SDL_GetGamepadBindForAxis(3)

SDL 3.0.0 SDL