the not so short introduction to kinect

111
The Not So Short Introduction to Kinect 份份份份份份 Kinect 份份 Hang xie [email protected] http://Xhbang.com

Upload: seeed-studio

Post on 15-May-2015

1.362 views

Category:

Technology


3 download

DESCRIPTION

重庆LUG8期聚会KINECT主题PPT

TRANSCRIPT

Page 1: The not so short introduction to Kinect

The Not So ShortIntroduction to Kinect一份不太简短的 Kinect 介绍

Hang [email protected]://Xhbang.com

Page 2: The not so short introduction to Kinect

About Me

Chongqing University bachelor (单身汉)A boy couldn't stop dreamingBike travelling

Page 3: The not so short introduction to Kinect

About Him

•Dr.•Sensor related•Poet (魔幻现实主义)

Page 4: The not so short introduction to Kinect

About the Lab

•50% Idle•25% Computer•20% Programmer•5% Student/Paper

Page 5: The not so short introduction to Kinect

About You?

Programming dummy?Linux || Windows?Understand 3D?Work with the Kinect?

Page 6: The not so short introduction to Kinect

The Contentswhat u will learn today

体感操作, Kinect , OPENNI 介绍基本程序设计Working with Depth ImageWorking with Point Clouds ( * )Working with Skeleton Data & TrackingKinect Hacks

Page 7: The not so short introduction to Kinect

昨夜西风凋碧树 , 独上高楼 , 望尽天涯路

Page 8: The not so short introduction to Kinect
Page 9: The not so short introduction to Kinect
Page 10: The not so short introduction to Kinect

Buy it!

Page 11: The not so short introduction to Kinect

Inside Kinect

TeardownPrincipleHardwarePerformace

Page 12: The not so short introduction to Kinect

Hardware & teardown

Page 13: The not so short introduction to Kinect

http://www.ifixit.com/Teardown/Microsoft-Kinect-Teardown

Page 14: The not so short introduction to Kinect
Page 15: The not so short introduction to Kinect
Page 16: The not so short introduction to Kinect

Kinect Hardware

•RGB camera•IR depth sensor•IR projector•Audio device

Page 17: The not so short introduction to Kinect
Page 18: The not so short introduction to Kinect
Page 19: The not so short introduction to Kinect
Page 20: The not so short introduction to Kinect
Page 21: The not so short introduction to Kinect
Page 22: The not so short introduction to Kinect

Take a closer look

Noise at edges(shoulders)Depth shadowsMisalignment between the color and depth imagesFrame rate(30 vs 60)

Page 23: The not so short introduction to Kinect

Behind Kinect

Page 24: The not so short introduction to Kinect

TOF

•Time of Flight•以色列公司 3DV ( 09 年微软收购)•光飞行时间,飞秒 (1e−15) 级快门•砷化镓,使其时钟频率提高到上百•高成本,难以适应消费电子品•Natal 并不是基于 ToF 的原理

Page 25: The not so short introduction to Kinect

Light Coding (光编码)

•连续的照明(而非脉冲)•普通的 CMOS 感光芯片(低成本)•结构光技术(三维纵深的“体编码” )•激光散斑( laser speckle )

http://www.javaforge.com/wiki/103639 http://www.wipo.int/pctdb/en/wo.jsp?WO=2007043036 http://www.freepatentsonline.com/7433024.pdf

Page 26: The not so short introduction to Kinect
Page 27: The not so short introduction to Kinect

Exemplar

•机器学习系统•TB 计的数据训练集

1.寻找移动部位(背景分离,分割遮罩)2.辨认身体部位可能性3.模型匹配:生成骨架系统

Page 28: The not so short introduction to Kinect
Page 29: The not so short introduction to Kinect

Audio

•Something we forget•Supported by OpenNI, not by SensorKinect

Page 30: The not so short introduction to Kinect

More About Audio (题外话)•“Sound Wave”•微软研究院和华盛顿大学•利用多普勒效应,使用笔记本内置的扬声器和麦克风开发出类似 Kinect 的姿势感知系统•低成本•识别精度能达到 90% 以上•用手势玩俄罗斯方块游戏(视频)

Page 31: The not so short introduction to Kinect

Concepts

Page 32: The not so short introduction to Kinect
Page 33: The not so short introduction to Kinect

http://en.wikipedia.org/wiki/Natural_user_interface

Page 34: The not so short introduction to Kinect

Next generation interface

Page 35: The not so short introduction to Kinect

Wii Remote

Page 36: The not so short introduction to Kinect

ASUS Xtion

Page 37: The not so short introduction to Kinect

Kinect

Page 38: The not so short introduction to Kinect

Project Glass

Page 39: The not so short introduction to Kinect

Development

Page 40: The not so short introduction to Kinect
Page 41: The not so short introduction to Kinect

http://www.openni.org/

Page 42: The not so short introduction to Kinect

http://code.google.com/p/simple-openni/

Page 43: The not so short introduction to Kinect

http://openkinect.org/wiki/Main_Page

https://github.com/OpenKinect/libfreenect

Page 44: The not so short introduction to Kinect

Architecture

Quick view(*)

Page 45: The not so short introduction to Kinect

OpenNI

•Short for “Open Natural Interface”•Multi-langue•Cross-platform•Standard & Infrastructure

Page 46: The not so short introduction to Kinect

向后兼容

使用 openNI 开发的程序在以后的版本中都可以继续使用 , 因为开发人员可以毫无顾虑的更新 openNI到最新的版本。

Page 47: The not so short introduction to Kinect

OpenNI Framework(1)

Page 48: The not so short introduction to Kinect

抽象分层视图

•Top: 代表软件,在 OpenNI 顶部,实现了自然交互的应用程序。•Middle: 代表 OpenNI ,提供通信接口,同时连接传感器和中间件组件,后者分析来自传感器的数据。•Bottom: 硬件设备,捕捉现场的视频和音频内容。

Page 49: The not so short introduction to Kinect

OpenNI Framework(2)

Page 50: The not so short introduction to Kinect

通用的框架工具集

•一个 USB 抽象访问层•一些基本数据类型的实现(包括列表,哈希,等等)•系统日志和转储•内存和性能分析•活动(授权要注册的回调函数到一个特定的事件)•任务调度•不是标准 OpenNI 的一部分( * )

Page 51: The not so short introduction to Kinect

Callback func

•函数指针•注册•事件响应

Page 52: The not so short introduction to Kinect

OpenNIの构成

Generator Metadata Capability

Page 53: The not so short introduction to Kinect

Generator

注:绿色已经有,红色计划中,后略

Page 54: The not so short introduction to Kinect

生产节点

•单位集•生产性角色•使用较低水平的生产节点•“有意义的三位数据”

Page 55: The not so short introduction to Kinect

Sensor Related

•Device•Depth Generator•Image Generator•IR Generator•Audio Generator

Page 56: The not so short introduction to Kinect

Middleware Related

•Gesture Generator•Scene Analyzer•Hands Generator•User Generator•//provided by NITE

Page 57: The not so short introduction to Kinect

Record & Play

•Recoder•Player•Codec

Page 58: The not so short introduction to Kinect

Matadata

Page 59: The not so short introduction to Kinect

Capability

Page 60: The not so short introduction to Kinect

NITEの构成

SessionDetector

Page 61: The not so short introduction to Kinect

Middleware

•Full body analysis•Hand point analysis•Gesture detection•Scene Analyzer

Page 62: The not so short introduction to Kinect

Session

Page 63: The not so short introduction to Kinect

Detector

Page 64: The not so short introduction to Kinect
Page 65: The not so short introduction to Kinect
Page 66: The not so short introduction to Kinect

衣带渐宽终不悔,为伊消得人憔悴。

Page 67: The not so short introduction to Kinect

Hello world!

•Preparation•The program

Page 68: The not so short introduction to Kinect

Software Preparation

•OpenNI+NITE•Avin’s SensorKinect•Processing(*)•SimpleOpenNI(*)

https://github.com/avin2/SensorKinect

Page 69: The not so short introduction to Kinect

Here’s the code,too young too simple

Page 70: The not so short introduction to Kinect

import SimpleOpenNI.*;SimpleOpenNI kinect;

void setup(){ size(640*2, 480); kinect = new SimpleOpenNI(this);

kinect.enableDepth(); kinect.enableRGB();}

void draw(){ kinect.update();

image(kinect.depthImage(), 0, 0); image(kinect.rgbImage(), 640, 0);}

Page 71: The not so short introduction to Kinect

Understand the code

Page 72: The not so short introduction to Kinect

import SimpleOpenNI.*;SimpleOpenNI kinect;

•Import the library•Declare the SimpleOpenNI object

Page 73: The not so short introduction to Kinect

void setup(){ size(640*2, 480); kinect = new SimpleOpenNI(this);

kinect.enableDepth(); kinect.enableRGB();}

•Declare the size of app•Instantiate the object•Call two method

Page 74: The not so short introduction to Kinect

void draw(){ kinect.update();

image(kinect.depthImage(), 0, 0); image(kinect.rgbImage(), 640, 0);}

•Get fresh data from kinect•Place the image

Page 75: The not so short introduction to Kinect

Working with depth map

•R G B•纯黑代表无穷远,纯白代表无穷近•Demo:ex03_basic_depth_plus_rgb

Page 76: The not so short introduction to Kinect

More about depth map

•Projective•Realworld•Z值相同,代表深度,单位 mm•ConvertProjectiveToRealWorld()

Page 77: The not so short introduction to Kinect

The Kinect coordinate system

Page 78: The not so short introduction to Kinect

Demo

chPC_ex12_obj_in_point_cloud

Page 79: The not so short introduction to Kinect

范围以及精确性

•最近距离: about 0.5(?)•最远距离:  10m•GetDeviceMaxDepth()•官方建议: 1.2 – 3.6米•近远精确性比较

Page 80: The not so short introduction to Kinect
Page 81: The not so short introduction to Kinect

Working with Point Clouds(*)

Welcome to the Third Dimension3d reconstructionE.g:KinectFusion PCL

http://pointclouds.org/

Page 82: The not so short introduction to Kinect

DEMO

chPC_ex05_rotating_point_cloud

Page 83: The not so short introduction to Kinect

Working with Skeleton Data

•User Detection•Joints & Skeleton•Distance in 3D•Scene Map, Com•Tracking

Page 84: The not so short introduction to Kinect

User Detection

•Calibration or not•Stages in Process

Page 85: The not so short introduction to Kinect
Page 86: The not so short introduction to Kinect

Joints & Skeleton

•Joints•Distance between two joints in 3D

Page 87: The not so short introduction to Kinect

WindowsSDK: 20 joints(all)

Page 88: The not so short introduction to Kinect

OpenNI: 24 joints

Page 89: The not so short introduction to Kinect

DEMO

chSK_ex02_skel_anatomy

Page 90: The not so short introduction to Kinect

Scene Map

•Background remove•User pixels•Center of Mass

Page 91: The not so short introduction to Kinect

Demo

•chSK_scene_map•chSK_scene_image•chSK_center_of_mass

Page 92: The not so short introduction to Kinect

How

•kinect.enableScene();•sceneMap = kinect.sceneMap();•if(sceneMap[i] == n)

Page 93: The not so short introduction to Kinect

Tracking

Demo:PointViewer

Page 94: The not so short introduction to Kinect

众里寻他千百度,蓦然回首,那人却在,灯火阑珊处。

Page 95: The not so short introduction to Kinect

Kinect Hacks

Apps out of boxCreate your own cool stuffsLiving coding with VS & Cpp

Page 96: The not so short introduction to Kinect

Media Art

Demo: chDE_face_changing

Page 97: The not so short introduction to Kinect

How

•Collision detection•kinect.getJointPositionSkeleton()•kinect.convertRealWorldToProjective()•Picture scala

Page 98: The not so short introduction to Kinect

Computer Interface

Demo:Minority Report(*)Demo:2D TrackPadDemo:Hotpoint 3D

Page 99: The not so short introduction to Kinect

FAAST

•Key event mapping•Game playing

http://projects.ict.usc.edu/mxr/faast/

Page 100: The not so short introduction to Kinect

Sex Game Controller

•DEMO: 宅男妄想地带•Microsoft: NO!!

Page 101: The not so short introduction to Kinect

Sorry, Bill

Page 102: The not so short introduction to Kinect

Control emacs(*)

•Map(Joint position + gesture, key event)

Page 103: The not so short introduction to Kinect

Kinect Visual Camera(*)

http://www.kinectdevs.com/forums/kinect-virtual-camera-kinect-webcam-f17

Page 104: The not so short introduction to Kinect

The following demo need a better computer for higher GPU

support

Page 105: The not so short introduction to Kinect

kinect-ultra(*)

一秒钟凹凸曼合体!完成你童年时候的梦想Video

http://code.google.com/p/kinect-ultra/

Page 106: The not so short introduction to Kinect

kinect-kamehameha(*)

Page 107: The not so short introduction to Kinect

MikuMikuDance(*)

初音妹子Video

Page 108: The not so short introduction to Kinect

http://www.kinect-hacks.com/openni

What do you want to make?

Page 109: The not so short introduction to Kinect

reference•http://viml.nchc.org.tw•Visualization and Interactive Media Laboratory of NCHC•国家科學視算與互動媒體實驗室

•http://www.javaforge.com/wiki/103532•Kinect for PC Wiki•中文

Page 110: The not so short introduction to Kinect

Thanks!You are the controller.Q & AHang [email protected]://www.xhbang.com

Page 111: The not so short introduction to Kinect

This is basic template

Do not delete this page