Sep
29
2016

Using XBox One Kinect with Unity

 

kinect_unity_greenscreen
*main image: Kinect GreenScreen example scene

Setting up Kinect with Windows 10
– connect to pc (using adapter)
– Driver installs automatically and you are Done 🙂
– You can test it with these apps:
3d scan: https://www.microsoft.com/en-us/store/p/3d-scan/9nblggh68pmc
3d builder: https://www.microsoft.com/en-us/store/p/3d-builder/9wzdncrfj3t6

 

Using Kinect XBox One with Unity 5 (I tested with Unity v5.50b5)
– Download & install Kinect SDK https://www.microsoft.com/en-us/download/details.aspx?id=44561  (i’m using v2.0_1409)
– UnityPackage is here https://msdn.microsoft.com/en-us/library/dn782041.aspx (package download)
– Import Kinect.2.0.1410.19000.unitypackage into your project
– Also Copy GreenScreen/ and KinectView/ folders from the zip to your project (they contain the sample scenes)
– One shader is giving this error message: “‘Shader error in ‘DX11/GreenScreenShader’: Fragment program ‘frag’: sampler ‘SampleType’ has no matching texture and will be undefined”

Fix is in the unity forums by @Michal

//sampler SampleType;
sampler sampler_MainTex;
//o = _MainTex.Sample(SampleType, i.tex);
o = _MainTex.Sample(sampler_MainTex, i.tex);

https://forum.unity3d.com/threads/official-ms-kinect-unity-package-green-screen-shader-error.382295/#post-2484117

– To fix rest of the errors, run Unity Api Updater if it didn’t run automatically (from menu: Assets / Run Api Updater..)
– Open sample scene: GreenScreen/MainScene or KinectView/MainScene
– Hit play and it should work!

More Resources:
– Kinect experiments: http://www.kinecthacks.com/


1 Comment + Add Comment

  • Nice one, I hope to see more of your posts! If some of you are looking for even more tips about creating a game, I recommend this blog too: blog.theknightsofunity.com

Leave a comment to Jan

Connect

Twitter View LinkedIn profile Youtube Youtube Join Discord Twitch

UnityLauncherPro

Get UnityLauncherPRO and work faster with Unity Projects!
*free unity hub alternative

@unitycoder_com

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.