DepthImageFrame Kinect V2

时间:2015-04-06 20:57:11

标签: c# wpf kinect-sdk

帮助!

我正在尝试从Kinect v2中的DeapthImageFrame访问Microsoft.Kinect类,但它一直在说我错过了一个引用。我不能做一些简单的事情:

int player = depthFrame[i16] & DepthImageFrame.PlayerIndexBitmask;
int realDepth = depthFrame[i16] >> DepthImageFrame.PlayerIndexBitmaskWidth;

我无法使用DepthImageFrameDeapthStream,我甚至无法启用它。我已经尝试了很多例子而没有工作因为缺少参考。

有什么想法吗? 我该如何解决这个问题? 我需要任何图书馆吗?如果是这样,哪些图书馆以及我在哪里可以找到它们?

非常感谢您的帮助,谢谢!

2 个答案:

答案 0 :(得分:1)

Kinect v2的api与以前的版本完全不同。 https://msdn.microsoft.com/en-us/library/windowspreview.kinect.aspx

深度看看

DepthFrameReaderDepthFrame

特别要获取最新的深度框架DepthFrameReader.AcquireLatestFrame()

答案 1 :(得分:0)

开发Kinect V2需要使用SDK2。 如果您已经安装了SDK2,则只需从Visual Studio中的引用中删除Microsoft.Kinect命名空间,然后浏览Microsoft.Kinect并将其定义为新引用