FingerGestures
types
tap
swipe
long press
pinch/rotation
how to detect gesture
functions
library
diagram
core system
main chunk of the library and provides input detection through various gesture recognizers
comp
singleton
FingerGestures
Input
Mouse
mousePosition
=
Touches
stream
subscribe
function OnEnable(){FingerGestures.OnDragBegin += FingerGestures_OnDragBegin;}
DragAndDrop
.OnDragBegin
//pick dragObject with raycast
//disable sim and gravity
.OnDragMove
//convert finger position to world position
//center object on finger
.OnDragEnd
//resume sim
//dragObject = null; no longer dragging anything
...
unsubscribe
function OnDisable(){FingerGestures.OnDragBegin -= FingerGestures_OnDragBegin;}
...
interpreter
GestureRecognizer
trigger gesture event
OnFingersUpdated(Listener)
getfinger.position
toolbox
set of higher-level utility scripts
toolbox scripts include a drag & drop system, third person orbit and pinch-zoom camera script