我有一台 Kinect v2,我正尝试使用libfreenect2。
以下是我目前所做的:
拿到了
libfreenect2
项目git clone https://github.com/OpenKinect/libfreenect2.git
安装所需的依赖项
sudo apt-get install build-essential libturbojpeg libjpeg-turbo8-dev libtool autoconf libudev-dev cmake mesa-common-dev freeglut3-dev libxrandr-dev doxygen libxi-dev automake cd libfreenect2/depends sh install_ubuntu.sh sudo apt-get install libglfw3-dev
我有一个 Intel GPU,安装
beignet-dev
了 OpenCLsudo apt-get install beignet-dev
构建可执行文件
mkdir build && cd build cmake .. make sudo make install
一切都成功安装并且构建也成功。
启动程序
sudo ./bin/Protonect
输出没有显示任何错误,但Viewer
窗口保持黑色:
[Info] [Freenect2Impl] enumerating devices...
[Info] [Freenect2Impl] 8 usb devices connected
[Info] [Freenect2Impl] found valid Kinect v2 @2:5 with serial 501696141942
[Info] [Freenect2Impl] found 1 devices
[Info] [Freenect2DeviceImpl] opening...
[Info] [Freenect2DeviceImpl] opened
[Info] [Freenect2DeviceImpl] starting...
[Debug] [Freenect2DeviceImpl] ReadData0x14 response
[Debug] [Freenect2DeviceImpl] 92 bytes of raw data
0x0000: 00 00 12 00 00 00 00 00 01 00 00 00 43 c1 1f 41 2e2e2e2e2e2e2e2e2e2e2e2e432e2e41
0x0010: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e
0x0020: 0a 21 33 55 c2 00 17 20 00 08 00 00 10 00 00 00 2e2133552e2e2e202e2e2e2e2e2e2e2e
0x0030: 00 01 00 00 00 10 00 00 00 00 80 00 01 00 00 00 2e2e2e2e2e2e2e2e2e2e802e2e2e2e2e
0x0040: 31 33 00 00 00 04 0f 0d 47 4d 48 38 34 36 2e 31 31332e2e2e2e2e2e474d483834362e31
0x0050: 58 00 00 00 00 00 00 00 00 00 00 00 582e2e2e2e2e2e2e2e2e2e2e
[Debug] [Freenect2DeviceImpl] ReadStatus0x090000 response
[Debug] [Freenect2DeviceImpl] 4 bytes of raw data
0x0000: 00 22 00 00 2e222e2e
[Debug] [Freenect2DeviceImpl] ReadStatus0x090000 response
[Debug] [Freenect2DeviceImpl] 4 bytes of raw data
0x0000: 00 22 00 00 2e222e2e
[Info] [Freenect2DeviceImpl] enabling usb transfer submission...
[Info] [Freenect2DeviceImpl] submitting usb transfers...
[Info] [Freenect2DeviceImpl] started
device serial: 50**************
device firmware: 4.3.3912.0.7
[Info] [TurboJpegRgbPacketProcessor] avg. time: 18.4934ms -> ~54.0734Hz
[Info] [TurboJpegRgbPacketProcessor] avg. time: 19.4946ms -> ~51.2961Hz
...
Viewer
:
附加信息:
kinect 连接在 USB 3.0(必需)端口上,我使用的是 Ubuntu 15.04。
我在这里遗漏了什么?
答案1
最好在 GitHub 上报告此问题,以便我们可以跟踪您的进度。
Protonect 默认使用 OpenGL。您的 OpenGL 版本是什么glxinfo | grep OpenGL
?深度处理器是否真的在运行?要查看深度处理器是否真的在运行,请查看[XXXDepthRgbPacketProcessor] avg. time
日志消息。
由于您已经安装了 OpenCL 驱动程序,您也可以运行./Protonect cl
。
如果可以,请在 GitHub 上跟踪该问题。