- Home /
How can I use kinect for windows V2 with unity?
Hi guys, I've used unity for a few weeks now and now I'm trying to develop a kinect game. I tried searching for assets/plugins for using kinect V2 in unity however I haven't found much because kinect V2 is not backwards compatible with SDK 1.8 which is what many of the plugins use.
The only plugin that might work is https://www.assetstore.unity3d.com/en/#!/content/19873 however I get a bunch of errors trying to run it and they are in Japanese so I don't know what they mean.
And this tutorial which shows what I want to begin coding, but not how to link the API. http://channel9.msdn.com/coding4fun/kinect/Kinect-for-Windows-v2-SDK-and-Unity-3D.
I found that the kinect sdk 2 has unity support (http://msdn.microsoft.com/en-us/library/dn782041.aspx) but I only have the free version of unity. I am planning on buying unity pro however I would like to know how to actually link the two.
If someone can help me find a plugin that works, that would be much appreciated. I am also willing to learn how to create a plugin. All I am looking to get the (x,y,z) positions of the persons hands and I already see that kinect does most of that work for you with the API so it shouldn't be that hard to make a plugin I suppose.
Anyways I'm going to keep looking and I'll check back later to see if anyone has any updates. I'm just really surprised that there are so little kinect V2 game tutorials out.
Answer by BahuMan · Aug 26, 2015 at 10:14 AM
As of the Unity 5.x, you'll be able to import the MS kinect package into your free Unity. All of the C# code of the Kinect SDK is very easy to port to Unity C# code. The only thing you need to take care of is some name clashes; like "Joint" is also a class in Unity, so you need to specify "Windows.Kinect.Joint" instead.
I've made a simple Unity test scene where the position and rotation of 4 boxes is controlled by the Kinect (my head, torso and both hands). If anyone is interested, I could make a brief how-to for that, but there really isn't much to it.
have phun!
It would be awesome! If you still here, could you please make this how-to?
Answer by Landern · Oct 16, 2014 at 09:16 PM
You will have to have Pro, which i think you already realize. You will need to reference the v2 API assemblies that come from the SDK(put them in the plugin folder in your unity project). Once that is done, you will need to reference the namespace in your scripts. Finally, once that is complete, you will be able to use the classes to implement whatever is in your mind.
I'm just really surprised that there are so little kinect V2 game tutorials out.
It's in public preview, it's not released, so...
One of the examples from Armenia Unity - Diamonds - already has a github place holder, i'm sure they can't release it yet or just haven't. You can watch for it here: https://github.com/Armenia-Unity-Users-Group/Diamonds
Thanks for the response, I'll start with the trial of pro and see what happens from there.
@Landern Hi Landern, I am learning Unity and $$anonymous$$inect (the old one -- V1 with Win7) in order to implement nonverbal mimicry; i.e. animating a Unity character (through the $$anonymous$$echAnim system) to mirror the character animated by $$anonymous$$inect. I would greatly appreciate it if you would point me to a few good tutorials for this purpose. Thank you
Answer by kirillrybin · Nov 25, 2014 at 04:15 PM
Check new Unity3D packages for Kinect v2 http://go.microsoft.com/fwlink/?LinkId=513177
Answer by roumenf · Jan 07, 2015 at 12:57 PM
If you need more: https://www.assetstore.unity3d.com/en/#!/content/18708