SlideShare a Scribd company logo
1
INTRODUCTION
● About Me?
– Besjan Xhika
– My Background
● What this Presentation il About?
– Gesture Recognition Devices
– My Experiments with Leap Motion
2
GESTURE RECOGNITION DEVICES
● BODY
– Kinect (Microsoft)
– Asus Xtion
– Carmine (PrimeSense)
– DS311 (SoftKinetic)
● HANDS
– Leap Motion
– Creative* Interactive Gesture
Camera (Intel)
– Capri (Embedded Solution,
PrimeSense)
– DS325 (SoftKinetic)
– MYO
3
LEAP MOTION
4
LEAP MOTION
● Detects and Tracks Hands, Fingers and Finger-Like Tools
● Reports Discrete Positions, Gestures and Motion
● The FOV is an Inverted Pyramid Centered on the Device
● The Effective Range Extends From 25 to 600 mm
● Employs a Right-Handed Cartesian Coordinate System
● Provides Updates as a Set or Frame of Data
● Leap Motion Visualizer
5
LEAP MOTION IN A
MEDICAL APPLICATION
● InVesalius is a Medical Software Used to Reconstruct
Structures of the Human Body
● The Leap Device Simulates the Mouse
● Python was Used
● Example Integration of Leap Motion with InVesalius
6
API OVERVIEW
The Applications can use the Leap API to Access the Data of Hands
and Fingers that the Device Captures One Frame at a Time
– Leap.Controller: The interface between the Leap and the application
– Leap.Listener: Used to handle events dispatched by the Leap
– Leap.Frame: Contains a set of hand and finger tracking data
– Leap.Hand: Contains tracking data for a detected hand
– Leap.Finger: Contains tracking data for a detected finger
– Leap.Vector: Represents a 3D position or directional vector
– Leap.Gesture: Represents a recognized gesture.
7
def main():
# Implements callback functions to handle events dispatched by the Leap
listener = Listener()
# The Controller class provides the main interface between the Leap and the application
controller = Leap.Controller()
# Allows the application to run in the background
controller.set_policy_flags(Leap.Controller.POLICY_BACKGROUND_FRAMES)
# Have the sample listener receive events from the controller
controller.add_listener(listener)
# Keep this process running until Enter is pressed
sys.stdin.readline()
# Remove the sample listener when done
controller.remove_listener(listener)
CREATING A CONTROLLER OBJECT
8
class Listener(Leap.Listener):
def on_init(self, controller):
# Dispatched once when the controller to which the listener is registered is initialized
print "Initialized"
def on_connect(self, controller):
# Dispatched when the controller connects to the Leap and is ready to begin sending
frames of motion tracking data
print "Connected"
# Enable gestures
controller.enable_gesture(Leap.Gesture.TYPE_CIRCLE)
def on_disconnect(self, controller):
# Dispatched if the controller disconnects from the Leap
print "Disconnected"
def on_exit(self, controller):
# Dispatched to a listener when it is removed from a controller
print "Exited"
def on_frame(self, controller):
# Dispatched when a new frame of motion tracking data is available
...
SUBCLASSING THE LISTENER CLASS
9
def on_frame(self, controller):
# Get the most recent frame
frame = controller.frame()
if not frame.hands.empty:
# MOUSE CURSOR
firstHand = frame.hands[0]
if not firstHand.fingers.empty:
xPos = 5*firstHand.palm_position.x + self.screenWidth/2
yPos = 1500 - (4*firstHand.palm_position.y - 300 + self.screenHeight/2)
ctypes.windll.user32.SetCursorPos(int(xPos), int(yPos))
GETTING A FRAME OF DATA (Part I)
10
# MOUSE CLICKS
secondHand = frame.hands[1]
if not secondHand.fingers.empty and len(secondHand.fingers) == 1:
for gesture in frame.gestures():
if gesture.type == Leap.Gesture.TYPE_CIRCLE:
circle = Leap.CircleGesture(gesture)
if circle.pointable.direction.angle_to(circle.normal) <= Leap.PI/4: clockwiseness = "clockwise"
else: clockwiseness = "counterclockwise"
if circle.state == Leap.Gesture.STATE_STOP:
# MOUSE CLICK
if clockwiseness == "clockwise":
print "MOUSE CLICK"
ctypes.windll.user32.mouse_event(0x0002, 0, 0, 0, 0)
ctypes.windll.user32.mouse_event(0x0004, 0, 0, 0, 0)
# MOUSE CLICK + HOLD
else:
if not self.leftclickHold:
print "CLICK + HOLD"
ctypes.windll.user32.mouse_event(0x0002, 0, 0, 0, 0)
else:
print "CLICK + RELEASE"
ctypes.windll.user32.mouse_event(0x0004, 0, 0, 0, 0)
self.leftclickHold = not self.leftclickHold
GETTING A FRAME OF DATA (Part II)
11
OTHER EXAMPLE
APPLICATIONS
12
VIDEO GAMES
13
ART
14
USER INTERFACES
15
GOOGLE EARTH
16
KEYBOARD
17
Q & A
18
THANK YOU
● Blog
– bxhika.wordpress.com
● Twitter
– @BesjanXhika
● E-Mail
– xhikab@gmail.com

More Related Content

PPT
Quantify self
PPTX
Android Training (Sensors)
PDF
Review: Wellness technology in the workplace
PDF
Input (touch v.s in air gesture)
PPTX
Gesture recognition techniques
PPTX
Movement Tracking in Real-time Hand Gesture Recognition
PPT
Bionic eye soft copy (2)
PPTX
ARTIFICIAL RETINA/EYE (ASR,BIONIC EYE)
Quantify self
Android Training (Sensors)
Review: Wellness technology in the workplace
Input (touch v.s in air gesture)
Gesture recognition techniques
Movement Tracking in Real-time Hand Gesture Recognition
Bionic eye soft copy (2)
ARTIFICIAL RETINA/EYE (ASR,BIONIC EYE)

Viewers also liked (10)

PPTX
Euclid powerpoint
PPTX
Leap motion
PPTX
Artificial eye
PPT
Radar Application
PPTX
artificial eye
PPT
radar technology
PPTX
Gesture recognition
PPTX
Internet of Things and Big Data: Vision and Concrete Use Cases
PPTX
Gesture recognition technology
PDF
Gesture recognition using artificial neural network,a technology for identify...
Euclid powerpoint
Leap motion
Artificial eye
Radar Application
artificial eye
radar technology
Gesture recognition
Internet of Things and Big Data: Vision and Concrete Use Cases
Gesture recognition technology
Gesture recognition using artificial neural network,a technology for identify...
Ad

Similar to Gesture recognition (20)

PPTX
Leap Motion - Aydin Akcasu
PDF
Control Buggy using Leap Sensor Camera in Data Mining Domain
PDF
A SOFTWARE TOOL FOR EXPERIMENTAL STUDY LEAP MOTION
PDF
The Death of a Mouse
PPTX
Developing for Leap Motion
PPTX
Leap Motion seminar presentation ppt
PDF
Web Motion: Motion Detection on the Web
PPTX
Leap motion controller
PPTX
QuantumLeap, a Framework for Engineering Gestural User Interfaces based on th...
PPTX
motion controller
PDF
Research on Detecting Hand Gesture
PPTX
Natural User Interfaces
PDF
HAND GESTURE CONTROLLED MOUSE
PPTX
Leap motion
PDF
Controlling Mouse Movements Using hand Gesture And X box 360
PPTX
Gesture Recognition
PDF
Virtual Mouse Control Using Hand Gestures
PPTX
Leap Motion
PDF
Prototyping GNOME UI for Gestural Input
PDF
Virtual Mouse Using Hand Gesture Recognition
Leap Motion - Aydin Akcasu
Control Buggy using Leap Sensor Camera in Data Mining Domain
A SOFTWARE TOOL FOR EXPERIMENTAL STUDY LEAP MOTION
The Death of a Mouse
Developing for Leap Motion
Leap Motion seminar presentation ppt
Web Motion: Motion Detection on the Web
Leap motion controller
QuantumLeap, a Framework for Engineering Gestural User Interfaces based on th...
motion controller
Research on Detecting Hand Gesture
Natural User Interfaces
HAND GESTURE CONTROLLED MOUSE
Leap motion
Controlling Mouse Movements Using hand Gesture And X box 360
Gesture Recognition
Virtual Mouse Control Using Hand Gestures
Leap Motion
Prototyping GNOME UI for Gestural Input
Virtual Mouse Using Hand Gesture Recognition
Ad

Recently uploaded (20)

PPTX
ELETRONIC-PRODUCTS-ASSEMBLY-AND-SERVICING-NC-II-WEEK-1-Copy.pptx
PDF
PakistanCoinageAct-906.pdfdbnsshsjjsbsbb
PPT
System Unit Components and its Functions
PPTX
Chapter no 8 output devices dpart 2.pptx
PDF
ISS2022 present sdabhsa hsdhdfahasda ssdsd
PPTX
Unit-1.pptxgeyeuueueu7r7r7r77r7r7r7uriruru
PPTX
Prograce_Present.....ggation_Simple.pptx
PDF
ICT grade for 8. MATATAG curriculum .P2.pdf
PPTX
New professional education PROF-ED-7_103359.pptx
PPTX
RTS MASTER DECK_Household Convergence Scorecards. Use this file copy.pptx
PPTX
Presentation 1.pptxnshshdhhdhdhdhdhhdhdhdhd
PPTX
unit1d-communitypharmacy-240815170017-d032dce8.pptx
PDF
Topic-1-Main-Features-of-Data-Processing.pdf
PPTX
A Clear View_ Interpreting Scope Numbers and Features
PDF
Tcl Scripting for EDA.pdf
PPTX
AI_ML_Internship_WReport_Template_v2.pptx
PDF
Maxon CINEMA 4D 2025 Crack Free Download Latest Version
DOCX
fsdffdghjjgfxfdghjvhjvgfdfcbchghgghgcbjghf
PPTX
Group 4 [BSIT-1C] Computer Network (1).pptx
PDF
SAHIL PROdhdjejss yo yo pdf TOCOL PPT.pdf
ELETRONIC-PRODUCTS-ASSEMBLY-AND-SERVICING-NC-II-WEEK-1-Copy.pptx
PakistanCoinageAct-906.pdfdbnsshsjjsbsbb
System Unit Components and its Functions
Chapter no 8 output devices dpart 2.pptx
ISS2022 present sdabhsa hsdhdfahasda ssdsd
Unit-1.pptxgeyeuueueu7r7r7r77r7r7r7uriruru
Prograce_Present.....ggation_Simple.pptx
ICT grade for 8. MATATAG curriculum .P2.pdf
New professional education PROF-ED-7_103359.pptx
RTS MASTER DECK_Household Convergence Scorecards. Use this file copy.pptx
Presentation 1.pptxnshshdhhdhdhdhdhhdhdhdhd
unit1d-communitypharmacy-240815170017-d032dce8.pptx
Topic-1-Main-Features-of-Data-Processing.pdf
A Clear View_ Interpreting Scope Numbers and Features
Tcl Scripting for EDA.pdf
AI_ML_Internship_WReport_Template_v2.pptx
Maxon CINEMA 4D 2025 Crack Free Download Latest Version
fsdffdghjjgfxfdghjvhjvgfdfcbchghgghgcbjghf
Group 4 [BSIT-1C] Computer Network (1).pptx
SAHIL PROdhdjejss yo yo pdf TOCOL PPT.pdf

Gesture recognition

  • 1. 1 INTRODUCTION ● About Me? – Besjan Xhika – My Background ● What this Presentation il About? – Gesture Recognition Devices – My Experiments with Leap Motion
  • 2. 2 GESTURE RECOGNITION DEVICES ● BODY – Kinect (Microsoft) – Asus Xtion – Carmine (PrimeSense) – DS311 (SoftKinetic) ● HANDS – Leap Motion – Creative* Interactive Gesture Camera (Intel) – Capri (Embedded Solution, PrimeSense) – DS325 (SoftKinetic) – MYO
  • 4. 4 LEAP MOTION ● Detects and Tracks Hands, Fingers and Finger-Like Tools ● Reports Discrete Positions, Gestures and Motion ● The FOV is an Inverted Pyramid Centered on the Device ● The Effective Range Extends From 25 to 600 mm ● Employs a Right-Handed Cartesian Coordinate System ● Provides Updates as a Set or Frame of Data ● Leap Motion Visualizer
  • 5. 5 LEAP MOTION IN A MEDICAL APPLICATION ● InVesalius is a Medical Software Used to Reconstruct Structures of the Human Body ● The Leap Device Simulates the Mouse ● Python was Used ● Example Integration of Leap Motion with InVesalius
  • 6. 6 API OVERVIEW The Applications can use the Leap API to Access the Data of Hands and Fingers that the Device Captures One Frame at a Time – Leap.Controller: The interface between the Leap and the application – Leap.Listener: Used to handle events dispatched by the Leap – Leap.Frame: Contains a set of hand and finger tracking data – Leap.Hand: Contains tracking data for a detected hand – Leap.Finger: Contains tracking data for a detected finger – Leap.Vector: Represents a 3D position or directional vector – Leap.Gesture: Represents a recognized gesture.
  • 7. 7 def main(): # Implements callback functions to handle events dispatched by the Leap listener = Listener() # The Controller class provides the main interface between the Leap and the application controller = Leap.Controller() # Allows the application to run in the background controller.set_policy_flags(Leap.Controller.POLICY_BACKGROUND_FRAMES) # Have the sample listener receive events from the controller controller.add_listener(listener) # Keep this process running until Enter is pressed sys.stdin.readline() # Remove the sample listener when done controller.remove_listener(listener) CREATING A CONTROLLER OBJECT
  • 8. 8 class Listener(Leap.Listener): def on_init(self, controller): # Dispatched once when the controller to which the listener is registered is initialized print "Initialized" def on_connect(self, controller): # Dispatched when the controller connects to the Leap and is ready to begin sending frames of motion tracking data print "Connected" # Enable gestures controller.enable_gesture(Leap.Gesture.TYPE_CIRCLE) def on_disconnect(self, controller): # Dispatched if the controller disconnects from the Leap print "Disconnected" def on_exit(self, controller): # Dispatched to a listener when it is removed from a controller print "Exited" def on_frame(self, controller): # Dispatched when a new frame of motion tracking data is available ... SUBCLASSING THE LISTENER CLASS
  • 9. 9 def on_frame(self, controller): # Get the most recent frame frame = controller.frame() if not frame.hands.empty: # MOUSE CURSOR firstHand = frame.hands[0] if not firstHand.fingers.empty: xPos = 5*firstHand.palm_position.x + self.screenWidth/2 yPos = 1500 - (4*firstHand.palm_position.y - 300 + self.screenHeight/2) ctypes.windll.user32.SetCursorPos(int(xPos), int(yPos)) GETTING A FRAME OF DATA (Part I)
  • 10. 10 # MOUSE CLICKS secondHand = frame.hands[1] if not secondHand.fingers.empty and len(secondHand.fingers) == 1: for gesture in frame.gestures(): if gesture.type == Leap.Gesture.TYPE_CIRCLE: circle = Leap.CircleGesture(gesture) if circle.pointable.direction.angle_to(circle.normal) <= Leap.PI/4: clockwiseness = "clockwise" else: clockwiseness = "counterclockwise" if circle.state == Leap.Gesture.STATE_STOP: # MOUSE CLICK if clockwiseness == "clockwise": print "MOUSE CLICK" ctypes.windll.user32.mouse_event(0x0002, 0, 0, 0, 0) ctypes.windll.user32.mouse_event(0x0004, 0, 0, 0, 0) # MOUSE CLICK + HOLD else: if not self.leftclickHold: print "CLICK + HOLD" ctypes.windll.user32.mouse_event(0x0002, 0, 0, 0, 0) else: print "CLICK + RELEASE" ctypes.windll.user32.mouse_event(0x0004, 0, 0, 0, 0) self.leftclickHold = not self.leftclickHold GETTING A FRAME OF DATA (Part II)
  • 18. 18 THANK YOU ● Blog – bxhika.wordpress.com ● Twitter – @BesjanXhika ● E-Mail – xhikab@gmail.com