相关依赖的安装
sudo apt-get install libeigen3-dev
sudo apt-get install libflann1.9 libflann-dev
sudo apt-get install libboost-all-dev
sudo apt-get install libpcap-dev
sudo apt-get install libqhull* libgtest-dev
sudo apt-get install libusb-1.0-0-dev libusb-dev libudev-dev
sudo apt-get install freeglut3-dev pkg-config
sudo apt-get install libxmu-dev libxi-dev
sudo apt-get install mono-complete
sudo apt-get install libopenni-dev libopenni2-dev
安装步骤
如果你已经安装了VTK,那么安装pcl就比较简单
1、和安装VTK8.2一样,去官网下载pcl1.9.1的压缩包
2、解压后创建build文件夹并进入
3、输入cmake-gui命令,设置源码目录和输出目录,勾选Group和Adavanced,点击config后,进行如下设置
BUILD_surface_on_nurbs == ON
PCL_ENABLE_SSE==OFF
// 下面两个要手动添加
VTK_GROUP_QT==ON
VTK_QT_VERSION = 5
4、出现“Run “cmake --help-policy CMP0072” for policy details. Use the cmake_policy command to set the policy and suppress this warning.”问题,在/pcl-pcl-1.9.1/CMakeLists.txt文件中,添加以下代码
if (POLICY CMP0072)
set(OpenGL_GL_PREFERENCE LEGACY)
endif()
5、和VTK一样,进行编译安装。不过pcl的编译和安装很长,至少3小时
sudo make
sudo checkinstall --pkgname=pcl-1.9.1