SDL 3.0
SDL_PinchFingerEvent Struct Reference

#include <SDL_events.h>

Data Fields

SDL_EventType type
Uint32 reserved
Uint64 timestamp
float scale
SDL_WindowID windowID
float span_x
float span_y
float focus_x
float focus_y

Detailed Description

Pinch event structure (event.pinch.*)

span_(x/y) and focus_(x/y) are only available for pinch gestures on mobile devices

Definition at line 878 of file SDL_events.h.

Field Documentation

◆ focus_x

float SDL_PinchFingerEvent::focus_x

On mobile devices for BEGIN and UPDATE events, the X coordinate of the current gesture's focal point in window coordinates. Otherwise, -1.

Definition at line 887 of file SDL_events.h.

◆ focus_y

float SDL_PinchFingerEvent::focus_y

On mobile devices for BEGIN and UPDATE events, the Y coordinate of the current gesture's focal point in window coordinates. Otherwise, -1.

Definition at line 888 of file SDL_events.h.

◆ reserved

Uint32 SDL_PinchFingerEvent::reserved

Definition at line 881 of file SDL_events.h.

◆ scale

float SDL_PinchFingerEvent::scale

The scale change since the last SDL_EVENT_PINCH_UPDATE. Scale < 1 is "zoom out". Scale > 1 is "zoom in".

Definition at line 883 of file SDL_events.h.

◆ span_x

float SDL_PinchFingerEvent::span_x

On mobile devices for BEGIN and UPDATE events, the average X distance between each of the pointers forming the pinch in window coordinates. Otherwise, -1.

Definition at line 885 of file SDL_events.h.

◆ span_y

float SDL_PinchFingerEvent::span_y

On mobile devices for BEGIN and UPDATE events, the average Y distance between each of the pointers forming the pinch in window coordinates. Otherwise, -1.

Definition at line 886 of file SDL_events.h.

◆ timestamp

Uint64 SDL_PinchFingerEvent::timestamp

In nanoseconds, populated using SDL_GetTicksNS()

Definition at line 882 of file SDL_events.h.

◆ type

SDL_EventType SDL_PinchFingerEvent::type

◆ windowID

SDL_WindowID SDL_PinchFingerEvent::windowID

The window underneath the finger, if any

Definition at line 884 of file SDL_events.h.


The documentation for this struct was generated from the following file: