Function SDL_GetGamepadTouchpadFinger

pub unsafe extern "C" fn SDL_GetGamepadTouchpadFinger(
    gamepad: *mut SDL_Gamepad,
    touchpad: i32,
    finger: i32,
    down: *mut bool,
    x: *mut f32,
    y: *mut f32,
    pressure: *mut f32,
) -> bool
Available on crate feature dep_sdl3 only.
Expand description

Get the current state of a finger on a touchpad on a gamepad.

§Parameters

  • gamepad: a gamepad.
  • touchpad: a touchpad.
  • finger: a finger.
  • down: a pointer filled with true if the finger is down, false otherwise, may be NULL.
  • x: a pointer filled with the x position, normalized 0 to 1, with the origin in the upper left, may be NULL.
  • y: a pointer filled with the y position, normalized 0 to 1, with the origin in the upper left, may be NULL.
  • pressure: a pointer filled with pressure value, may be NULL.

§Return value

Returns true on success or false on failure; call SDL_GetError() for more information.

§Availability

This function is available since SDL 3.2.0.

§See also