Kinect Open Source Programming Secrets

Slides:



Advertisements
Similar presentations
Miroslav Hlaváč Martin Kozák Fish position determination in 3D space by stereo vision.
Advertisements

Davide Spano CNR-ISTI, HIIS Laboratory, Via G. Moruzzi Pisa, Italy.
KINECT REHABILITATION
-Praktikum- Cognitive Robots Dr. Claus Lenz Robotics and Embedded Systems Department of Informatics Technische Universität München
The Bioloid Robot Project Presenters: Michael Gouzenfeld Alexey Serafimov Supervisor: Ido Cohen Winter Department of Electrical Engineering.
Multi-scenario Gesture Recognition Using Kinect Student : Sin- Jhu YE Student Id : MA Computer Engineering & Computer Science University of Louisville.
 INTRODUCTION  STEPS OF GESTURE RECOGNITION  TRACKING TECHNOLOGIES  SPEECH WITH GESTURE  APPLICATIONS.
By shooting 2009/10/1. outline imTop overview imTop detection Finger Mobile Finger detection evaluation Mobile detection improvement.
Move With Me S.W Graduation Project An Najah National University Engineering Faculty Computer Engineering Department Supervisor : Dr. Raed Al-Qadi Ghada.
Game Development with Kinect
Introduce about sensor using in Robot NAO Department: FTI-FHO-FPT Presenter: Vu Hoang Dung.
1 References: 1. J.M. Hart, Windows System Programming, 4th Ed., Addison-Wesley, 2010, Ch.12 2.Microsoft Kinect SDK for Developers,
Page 1 | Microsoft Streams sync and coordinate mapping Kinect for Windows Video Courses.
Augmented Reality and 3D modelling Done by Stafford Joemat Supervised by Mr James Connan and Mr Mehrdad Ghaziasgar.
Knowledge Systems Lab JN 8/24/2015 A Method for Temporal Hand Gesture Recognition Joshua R. New Knowledge Systems Laboratory Jacksonville State University.
Yingcai Xiao Interactive Visualization with NUI and Game Engines.
A Brief Overview of Computer Vision Jinxiang Chai.
Kinect Part II Anna Loparev.
Professor : Yih-Ran Sheu Student’s name : Nguyen Van Binh Student ID: MA02B203 Kinect camera 1 Southern Taiwan University Department of Electrical Engineering.
Knowledge Systems Lab JN 9/10/2002 Computer Vision: Gesture Recognition from Images Joshua R. New Knowledge Systems Laboratory Jacksonville State University.
Zhengyou Zhang Microsoft Research Digital Object Identifier: /MMUL Publication Year: 2012, Page(s): Professor: Yih-Ran Sheu Student.
Presentation by: K.G.P.Srikanth. CONTENTS  Introduction  Components  Working  Applications.
INTRODUCTION Generally, after stroke, patient usually has cerebral cortex functional barrier, for example, the impairment in the following capabilities,
Page 1 | Microsoft Work With Skeleton Data Kinect for Windows Video Courses Jan 2013.
Page 1 | Microsoft Work With Color Data Kinect for Windows Video Courses Jan 2013.
A Method for Hand Gesture Recognition Jaya Shukla Department of Computer Science Shiv Nadar University Gautam Budh Nagar, India Ashutosh Dwivedi.
Hand Tracking for Virtual Object Manipulation
1 EEC-492/592 Kinect Application Development Lecture 2 Wenbing Zhao
GENESIS OF VIRTUAL REALITY  The term ‘Virtual reality’ (VR) was initially coined by Jaron Lanier, founder of VPL Research (1989)..
OpenNI-Reading and Processing Depth Data Author: 鄭暐達.
ECE 8443 – Pattern Recognition EE 3512 – Signals: Continuous and Discrete Objectives: Spectrograms Revisited Feature Extraction Filter Bank Analysis EEG.
Abstract matrix spaces and their generalisation Orawan Tripak Joint work with Martin Lindsay.
Professor : Tsung Fu Chien Student’s name : Nguyen Trong Tuyen Student ID: MA02B208 An application Kinect camera controls Vehicles by Gesture 1 Southern.
SciFest Overview Neil Gannon. Outline Demonstrations using a Microsoft Kinect sensor – Image Manipulation Real-time Invisibility Background removal (green.
CONTENT 1. Introduction to Kinect 2. Some Libraries for Kinect 3. Implement 4. Conclusion & Future works 1.
Interactive Computer Graphics
Electrical and Computer Engineer Large Portable Projected Peripheral Touchscreen Team Jackson Brian Gosselin Jr. Greg Langlois Nick Jacek Dmitry Kovalenkov.
Spring 2007 COMP TUI 1 Computer Vision for Tangible User Interfaces.
Knowledge Systems Lab JN 1/15/2016 Facilitating User Interaction with Complex Systems via Hand Gesture Recognition MCIS Department Knowledge Systems Laboratory.
CONTENT FOCUS FOCUS INTRODUCTION INTRODUCTION COMPONENTS COMPONENTS TYPES OF GESTURES TYPES OF GESTURES ADVANTAGES ADVANTAGES CHALLENGES CHALLENGES REFERENCE.
Introduction to Kinect For Windows SDK
Augmented Reality and 3D modelling Done by Stafford Joemat Supervised by Mr James Connan.
Product: Microsoft Kinect Team I Alex Styborski Brandon Sayre Brandon Rouhier Section 2B.
What is Multimedia Anyway? David Millard and Paul Lewis.
Che-An Wu Background substitution. Background Substitution AlphaMa p Trimap Depth Map Extract the foreground object and put into another background Objective.
Introduction TYWu. Applications Games –Microsoft Kinect Motion Sensor.
Over the recent years, computer vision has started to play a significant role in the Human Computer Interaction (HCI). With efficient object tracking.
Creative Coding & the New Kinect
Southern Taiwan University Department of Electrical Engineering
Paper – Stephen Se, David Lowe, Jim Little
Human Computer Interaction
EEC-693/793 Applied Computer Vision with Depth Cameras
EEC-693/793 Applied Computer Vision with Depth Cameras
Live Actor and Entity Representation in MAR
Xbox Kinect (Microsoft)
CAPTURING OF MOVEMENT DURING MUSIC PERFORMANCE
Programming HCI Yingcai Xiao Yingcai Xiao.
Atom-Based Embedded System Design at CUHK
EEC-693/793 Applied Computer Vision with Depth Cameras
EEC-693/793 Applied Computer Vision with Depth Cameras
EEC-693/793 Applied Computer Vision with Depth Cameras
Kinect for Creative Development with open source frameworks
Name xxx Research Center and Department of yyyy, Faculty of zzz
Name xxx Research Center and Department of yyyy, Faculty of zzz
Name xxx Research Center and Department of yyyy, Faculty of zzz
Name xxx Research Center and Department of yyyy, Faculty of zzz
EEC-693/793 Applied Computer Vision with Depth Cameras
Name xxx Research Center and Department of yyyy, Faculty of zzz
Name xxx Research Center and Department of yyyy, Faculty of zzz
PRELIMINARY DESIGN REVIEW
Presentation transcript:

Kinect Open Source Programming Secrets Hacking the Kinect with OpenNI, NITE, and Java Andrew Davison Prince of Songkla University Thailand ad@fivedots.coe.psu.ac.th

http://fivedots.coe.psu.ac.th/~ad/kinect Overview 1. The Kinect Sensor 2. Maps 3. Skeletons 4. Hand Points and Gestures 5. Computer Vision 6. Augmented Reality 7. Summary using OpenNI using NITE as an input source to other libraries Eight examples (if I have time) KOPS Talk (JavaOne 2012)

1. The Kinect Sensor CMOS color sensor (for RGB imaging) one microphone (downward facing) three-axis accelerometer status LED three microphones (downward facing) IR light source CMOS IR sensor motorized tilting base (up/down ~30) used for 3D depth sensing KOPS Talk (JavaOne 2012)

2. Depth, Image, IR Maps The IR light emits a fixed pattern of spots (randomly distributed) KOPS Talk (JavaOne 2012)

Map Generation camera image Depth Generator Image Generator IR initialize context and generator(s) OR OR Depth Map Image Map IR Map wait on context update read map camera image repaint KOPS Talk (JavaOne 2012)

Initialization Context context = new Context(); License license = new License("PrimeSense", "0KOIk2JeIBYClPWVnMoRKn5cdY4="); context.addLicense(license); DepthGenerator depthGen = DepthGenerator.create(context); MapOutputMode mapMode = new MapOutputMode(640, 480, 30); // xRes, yRes, FPS depthGen.setMapOutputMode(mapMode); context.setGlobalMirror(true); context.startGeneratingAll(); KOPS Talk (JavaOne 2012)

Wait, Read, Repaint Loop while (isRunning) { try { context.waitAnyUpdateAll(); } catch(StatusException e) { System.out.println(e); System.exit(1); updateDepthImage(); // my code repaint(); try { // close down context.stopGeneratingAll(); catch (StatusException e) {} context.release(); KOPS Talk (JavaOne 2012)

OpenNI Generators primarily used by middleware (e.g. NITE) KOPS Talk (JavaOne 2012)

2.1. Transforming the User later The transformation is applied to all of the camera image, but transparent parts of the changed image aren't visible. KOPS Talk (JavaOne 2012)

Center-of-mass (CoM) based changes Time-based changes cycle through blurring Center-of-mass (CoM) based changes change stays centered on user KOPS Talk (JavaOne 2012)

Building the Scene http://www.jhlabs.com/ip/filters/ set alternative viewpoint Depth Generator Image Generator User Generator for real world coordinates to 2D (projective) mapping Scene MetaData camera image remove background scene map (user ID map) Java 2D filterOp CoMs of user IDs (optional) http://www.jhlabs.com/ip/filters/ KOPS Talk (JavaOne 2012)

Panel Execution remove background of camera image; initialize context and generator(s) remove background of camera image; apply filterOp (optionally based on time and CoM of user) wait on context update update repaint draw background image draw camera image; KOPS Talk (JavaOne 2012)

3. OpenNI Skeleton There are 15 joints (and 9 more that are not currently initialized by the skeleton capability). On-screen view, with mirroring enabled KOPS Talk (JavaOne 2012)

3.1. Heads and Backgrounds switch heads and backgrounds (via keyboard or dialog selection) KOPS Talk (JavaOne 2012)

Generators (and Capabilities) : set alternative viewpoint Skeleton Capability Depth Generator Image Generator User Generator Pose Capability : for real world coordinates to 2D (projective) mapping Scene MetaData listeners for various user events camera image scene map (user ID map) KOPS Talk (JavaOne 2012)

Rotating the Head Image Calculated using the head and neck coordinates. KOPS Talk (JavaOne 2012)

3.2. Viewing Users in 3D rendered using Java 3D for each user joints and limbs KOPS Talk (JavaOne 2012)

Creating a Skeleton add a calibration Skeleton user has completed object to the 3D scene calibration completed user has reentered user has exited lost user new user Skeleton Capability calibration starting Depth Generator User Generator Pose Capability for real world coord to 2D (projective) mapping psi pose detected KOPS Talk (JavaOne 2012)

Overview 1. The Kinect Sensor 2. Maps 3. Skeletons 4. Hand Points and Gestures 5. Computer Vision 6. Augmented Reality 7. Summary using OpenNI using NITE as an input source to other libraries KOPS Talk (JavaOne 2012)

4. NITE Hand Points and Gestures NITE gestures are derived from a stream of hand points which record how a hand moves through space over time. Gesture detectors are sometimes called point listeners (or point controls) since they analyze the hand points stream looking for gestures. KOPS Talk (JavaOne 2012)

NITE Gesture Classes KOPS Talk (JavaOne 2012)

4.1. Gesture GUIs (GGUIs) KOPS Talk (JavaOne 2012)

Controlling the GGUIs Depth Generator Hands Generator Gesture for coords mapping Session Manager session ended (S) Image Generator for camera image Point Control new hand point (P1) hand point moved (P2) update GGUI no active hand points (P3) KOPS Talk (JavaOne 2012) deactivate GGUI

Overview 1. The Kinect Sensor 2. Maps 3. Skeletons 4. Hand Points and Gestures 5. Computer Vision 6. Augmented Reality 7. Summary using OpenNI using NITE as an input source to other libraries KOPS Talk (JavaOne 2012)

5. Computer Vision and the Kinect http://opencv.willowgarage.com 5. Computer Vision and the Kinect Use the Kinect sensor as input to JavaCV (a Java binding for OpenCV) input can be RGB and/or depth reading Current and past (student) projects: motion detection face detection & recognition eye tracking KOPS Talk (JavaOne 2012)

5.1. Hand Recognition KOPS Talk (JavaOne 2012)

From OpenNI to OpenCV threshold smooth largest contour Depth Generator Map smooth largest contour KOPS Talk (JavaOne 2012)

(start pt, end pt, depth pt, depth) largest contour convex hull convexity defects end pt depth start pt depth pt each defect is a tuple: (start pt, end pt, depth pt, depth) KOPS Talk (JavaOne 2012)

small angles between the start and end pts simplified convexity defects end pt depth start pt remove defects with: shallow depths small angles between the start and end pts depth pt KOPS Talk (JavaOne 2012)

Finger Labeling fragile, hacky index middle ring angle to the horizontal little thumb center of gravity (cog) rotate hand image to match predefined hand 'parameters' fragile, hacky KOPS Talk (JavaOne 2012)

Uses? move finger rotate zoom/pinch double tap multi slide wave hold pick & drop cluster & move zoom spot hold & tap rotate two cover hide KOPS Talk (JavaOne 2012)

6. Augmented Reality (AR) A combination of a real scene and virtual elements generated by the computer. Uses the Kinect camera as input to NyARToolkit http://nyatla.jp/nyartoolkit/wp/?page_id=198 KOPS Talk (JavaOne 2012)

Using NyARToolkit and Java 3D search for Hiro marker using NyARToolkit Image Generator calculate its position and orientation video stream from the Kinect render model in front of the video frame using Java 3D apply position and orientation to marker model KOPS Talk (JavaOne 2012)

The User's Viewpoint model background + Y + X + Z KOPS Talk (JavaOne 2012)

7. Summary OpenNI NITE 7 Examples RGB, depth, IR maps skeletal tracking, scene/user IDs NITE hand points, hand gestures 7 Examples aligned maps user transformation heads & backgrounds 3D users gesture GUIs hand recognition augmented reality (AR) KOPS Talk (JavaOne 2012)

Topics not Discussed θ Tilt motor, LED, accelerometer left right θ Tilt motor, LED, accelerometer easy to add using LibusbJava Audio source input, speech recognition, beamforming using MS Kinect audio driver, JSAPI, TalkingJava, Motion detection, face recognition, eye tracking Multiple-marker AR Games – Kinect breakout positive negative KOPS Talk (JavaOne 2012)

More Information http://fivedots.coe.psu.ac.th/ ~ad/kinect/ All the code, draft chapters, and extra examples, are available at my website: http://fivedots.coe.psu.ac.th/ ~ad/kinect/ KOPS Talk (JavaOne 2012)

One last example... KOPS Talk (JavaOne 2012)

8. Where I work... I'm an Ajarn (lecturer) in the Department of Computer Engineering (CoE), Faculty of Engineering, Prince of Songkla University (PSU) I'm based at the Hat Yai campus, Songkhla province, in the south of Thailand. KOPS Talk (JavaOne 2012)

PSU at a Glance... 1st university in Southern Thailand, est. 1967 5 campuses 39,000 students (2012) Surat Thani Hat Yai Phuket Trang Pattani

Prince of Songkla University (PSU), Hat Yai campus Department of Computer Engineering (CoE) Faculty of Engineering KOPS Talk (JavaOne 2012)

KOPS Talk (JavaOne 2012)

Department of Computer Engineering (CoE) KOPS Talk (JavaOne 2012)

PSU Academically... A National Research University (NRU) Ranked 4th in the Nation in terms of publications Research strong points include: Natural rubber Biodiesel and energy Sea food and Halal food Marine sciences Nanotechnology Peace studies KOPS Talk (JavaOne 2012)

CoE Research Groups and Interests Center for Network Research (CNR) Wireless Sensor Network (WSN) ANW Informatics Laboratory Intelligent System (iSys) Research Team Computer Control and Robotics Computer System Design and VLSI Design KOPS Talk (JavaOne 2012)