菜单

TK1初学软件教程-安装iai_kinect2(二十一)

2018年5月18日 - TK1初学软件教程

TK1初学软件教程-安装iai_kinect2

说明:

步骤:

1) 安装Opencv2.4.8

$ cd ~
$ wget https://github.com/opencv/opencv/archive/2.4.8.tar.gz 
$ tar -zxvf 2.4.8.tar.gz 
$ cd ~/opencv-2.4.8
$ mkdir build
$ cd build
$ cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D CUDA_GENERATION=Kepler ..
$ make -j4
$ sudo make install 

2)安装iai_kinect2

$ mkdir -p kinect2_ws/src
$ cd kinect2_ws/src
$ git clone https://github.com/code-iai/iai_kinect2
$ rosdep install --from-paths . --ignore-src -r 
$ catkin_make -DCMAKE_BUILD_TYPE="Release"
No rule to make target `/usr/lib/arm-linux-gnueabihf/libopencv_videostab.so.2.4.8'
vim changeLib.sh
sudo ln -s /usr/lib/libopencv_calib3d.so /usr/lib/arm-linux-gnueabihf/libopencv_calib3d.so.2.4.8
sudo ln -s /usr/lib/libopencv_contrib.so /usr/lib/arm-linux-gnueabihf/libopencv_contrib.so.2.4.8
sudo ln -s /usr/lib/libopencv_core.so /usr/lib/arm-linux-gnueabihf/libopencv_core.so.2.4.8
sudo ln -s /usr/lib/libopencv_detection_based_tracker.so /usr/lib/arm-linux-gnueabihf/libopencv_detection_based_tracker.so.2.4.8
sudo ln -s /usr/lib/libopencv_esm_panorama.so /usr/lib/arm-linux-gnueabihf/libopencv_esm_panorama.so.2.4.8
sudo ln -s /usr/lib/libopencv_facedetect.so /usr/lib/arm-linux-gnueabihf/libopencv_facedetect.so.2.4.8
sudo ln -s /usr/lib/libopencv_features2d.so /usr/lib/arm-linux-gnueabihf/libopencv_features2d.so.2.4.8
sudo ln -s /usr/lib/libopencv_flann.so /usr/lib/arm-linux-gnueabihf/libopencv_flann.so.2.4.8
sudo ln -s /usr/lib/libopencv_gpu.so /usr/lib/arm-linux-gnueabihf/libopencv_gpu.so.2.4.8
sudo ln -s /usr/lib/libopencv_highgui.so /usr/lib/arm-linux-gnueabihf/libopencv_highgui.so.2.4.8
sudo ln -s /usr/lib/libopencv_imgproc.so /usr/lib/arm-linux-gnueabihf/libopencv_imgproc.so.2.4.8
sudo ln -s /usr/lib/libopencv_imuvstab.so /usr/lib/arm-linux-gnueabihf/libopencv_imuvstab.so.2.4.8
sudo ln -s /usr/lib/libopencv_legacy.so /usr/lib/arm-linux-gnueabihf/libopencv_legacy.so.2.4.8
sudo ln -s /usr/lib/libopencv_ml.so /usr/lib/arm-linux-gnueabihf/libopencv_ml.so.2.4.8
sudo ln -s /usr/lib/libopencv_objdetect.so /usr/lib/arm-linux-gnueabihf/libopencv_objdetect.so.2.4.8
sudo ln -s /usr/lib/libopencv_photo.so /usr/lib/arm-linux-gnueabihf/libopencv_photo.so.2.4.8
sudo ln -s /usr/lib/libopencv_stitching.so /usr/lib/arm-linux-gnueabihf/libopencv_stitching.so.2.4.8
sudo ln -s /usr/lib/libopencv_superres.so /usr/lib/arm-linux-gnueabihf/libopencv_superres.so.2.4.8
sudo ln -s /usr/lib/libopencv_tegra.so /usr/lib/arm-linux-gnueabihf/libopencv_tegra.so.2.4.8
sudo ln -s /usr/lib/libopencv_video.so /usr/lib/arm-linux-gnueabihf/libopencv_video.so.2.4.8
sudo ln -s /usr/lib/libopencv_videostab.so /usr/lib/arm-linux-gnueabihf/libopencv_videostab.so.2.4.8
sudo ln -s /usr/lib/libopencv_vstab.so /usr/lib/arm-linux-gnueabihf/libopencv_vstab.so.2.4.8

sudo ln -s /usr/lib/libopencv_ts.a /usr/lib/arm-linux-gnueabihf/libopencv_ts.so.2.4.8
sudo ln -s /usr/local/lib/libopencv_ocl.so.2.4.8 /usr/lib/arm-linux-gnueabihf/libopencv_ocl.so.2.4.8

3)测试iai_kinect2

roslaunch kinect2_bridge kinect2_bridge.launch

请输入图片描述

rosrun kinect2_viewer kinect2_viewer kinect2 sd cloud

请输入图片描述

问题汇总:

ln链接libopencv_ts.a

ln链接编译的版本

直接修改kinect2_bridge.cpp,更改为libfreenect2::CudaPacketPipeline(device)

http://blog.csdn.net/sysuwuhongpeng/article/details/45485719

通过最大CPU性能解决
bin/Protenect cuda -noviewer

http://blog.csdn.net/windtalkersm/article/details/20067847
https://github.com/OpenPTrack/open_ptrack/wiki/Jetson-TK1-Installation
https://devtalk.nvidia.com/default/topic/811034/jetson-tk1/kinect-2-libfreenect2-hw-acceleration-full-performance-obtained/1

参考:

标签:

发表评论