UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FGestureRecognizer Class Reference

#include <GestureRecognizer.h>

Public Member Functions

 FGestureRecognizer ()
 
void DetectGestures (const FVector(&Touches)[EKeys::NUM_TOUCH_KEYS], class UPlayerInput *PlayerInput, float DeltaTime)
 
void SetAnchorDistanceSquared (const FVector2D FirstPoint, const FVector2D SecontPoint)
 

Protected Member Functions

void HandleGesture (class UPlayerInput *PlayerInput, FKey Gesture, bool bStarted, bool bEnded)
 

Protected Attributes

TMap< FKey, floatCurrentGestureValues
 
FVector2D AnchorPoints [EKeys::NUM_TOUCH_KEYS]
 
FVector2D LastPinchPoint_Start
 
FVector2D LastPinchPoint_End
 
bool bIsReadyForPinch
 
float AnchorDistanceSq
 
float StartAngle
 
bool bIsReadyForFlick
 
FVector2D FlickCurrent
 
float FlickTime
 
int32 PreviousTouchCount
 

Constructor & Destructor Documentation

◆ FGestureRecognizer()

FGestureRecognizer::FGestureRecognizer ( )
inline

Constructor

Member Function Documentation

◆ DetectGestures()

void FGestureRecognizer::DetectGestures ( const FVector(&)  Touches[EKeys::NUM_TOUCH_KEYS],
class UPlayerInput PlayerInput,
float  DeltaTime 
)

Attempt to detect touch gestures

◆ HandleGesture()

void FGestureRecognizer::HandleGesture ( class UPlayerInput PlayerInput,
FKey  Gesture,
bool  bStarted,
bool  bEnded 
)
protected

Internal processing of gestures

◆ SetAnchorDistanceSquared()

void FGestureRecognizer::SetAnchorDistanceSquared ( const FVector2D  FirstPoint,
const FVector2D  SecontPoint 
)

Save the distance between the anchor points

Member Data Documentation

◆ AnchorDistanceSq

float FGestureRecognizer::AnchorDistanceSq
protected

◆ AnchorPoints

FVector2D FGestureRecognizer::AnchorPoints[EKeys::NUM_TOUCH_KEYS]
protected

Special gesture tracking values

◆ bIsReadyForFlick

bool FGestureRecognizer::bIsReadyForFlick
protected

◆ bIsReadyForPinch

bool FGestureRecognizer::bIsReadyForPinch
protected

◆ CurrentGestureValues

TMap<FKey, float> FGestureRecognizer::CurrentGestureValues
protected

A mapping of a gesture to it's current value (how far swiped, pinch amount, etc)

◆ FlickCurrent

FVector2D FGestureRecognizer::FlickCurrent
protected

◆ FlickTime

float FGestureRecognizer::FlickTime
protected

◆ LastPinchPoint_End

FVector2D FGestureRecognizer::LastPinchPoint_End
protected

◆ LastPinchPoint_Start

FVector2D FGestureRecognizer::LastPinchPoint_Start
protected

Special pinch tracking values

◆ PreviousTouchCount

int32 FGestureRecognizer::PreviousTouchCount
protected

◆ StartAngle

float FGestureRecognizer::StartAngle
protected

The documentation for this class was generated from the following files: