PCL点云数据库——第一篇(开发环境的搭建)

概述
点云数据库(Point Cloud Libary,PCL)是一个专门用来处理三维点云的跨平台开源库,支持Windows,Linux,Android,Mac OS X等平台。涉及点云处理得大量通用算法,包括点云获取、滤波、分割、配准、检索、特征提取、识别、追踪、曲面重建、可视化等基础模块,以及人体骨骼识别提取、动作跟踪识别等应用。
安装
目前笔者只使用Windows平台上的PCL点云开发,所以,这里只简述在Windows上的安装过程。
系统为WIN7
Visual Studio版本为VS2015

首先准备好安装需要的各种资源
PCL点云数据库——第一篇(开发环境的搭建)_第1张图片
这里注意,你可以根据自己的电脑版本选择对应的软件包,选择与VS版本一致的安装包。

按照默认安装PCL-1.8.0-ALLInOne-msvc2015-win64.exe就好,安装过程中会提醒是否自动添加环境变量,可以直接选择自动添加即可。
D:\PCL 1.8.0\bin;
D:\PCL 1.8.0\3rdParty\FLANN\bin;
D:\PCL 1.8.0\3rdParty\Qhull\bin;
D:\PCL 1.8.0\3rdParty\OpenNI2\Tools;
D:\PCL 1.8.0\3rdParty\VTK\bin;
安装成功后,新建VS2015控制台项目。
PCL点云数据库——第一篇(开发环境的搭建)_第2张图片
这里注意将开发环境改为×64位。接下来配置VS2015的环境,在属性管理器中的DEBUG×64右键选择属性,然后更改到VC++目录,更改其中的包含目录和库目录。
PCL点云数据库——第一篇(开发环境的搭建)_第3张图片
PCL点云数据库——第一篇(开发环境的搭建)_第4张图片PCL点云数据库——第一篇(开发环境的搭建)_第5张图片
然后在
连接器的输入-附加依赖项中添加

pcl_common_debug.lib
pcl_features_debug.lib
pcl_filters_debug.lib
pcl_io_debug.lib
pcl_io_ply_debug.lib
pcl_kdtree_debug.lib
pcl_keypoints_debug.lib
pcl_ml_debug.lib
pcl_octree_debug.lib
pcl_outofcore_debug.lib
pcl_people_debug.lib
pcl_recognition_debug.lib
pcl_registration_debug.lib
pcl_sample_consensus_debug.lib
pcl_search_debug.lib
pcl_segmentation_debug.lib
pcl_stereo_debug.lib
pcl_surface_debug.lib
pcl_tracking_debug.lib
pcl_visualization_debug.lib
flann_cpp_s-gd.lib
flann_s-gd.lib
flann-gd.lib
libboost_atomic-vc140-mt-gd-1_61.lib
libboost_chrono-vc140-mt-gd-1_61.lib
libboost_container-vc140-mt-gd-1_61.lib
libboost_context-vc140-mt-gd-1_61.lib
libboost_coroutine-vc140-mt-gd-1_61.lib
libboost_date_time-vc140-mt-gd-1_61.lib
libboost_exception-vc140-mt-gd-1_61.lib
libboost_filesystem-vc140-mt-gd-1_61.lib
libboost_graph-vc140-mt-gd-1_61.lib
libboost_iostreams-vc140-mt-gd-1_61.lib
libboost_locale-vc140-mt-gd-1_61.lib
libboost_log-vc140-mt-gd-1_61.lib
libboost_log_setup-vc140-mt-gd-1_61.lib
libboost_math_c99-vc140-mt-gd-1_61.lib
libboost_math_c99f-vc140-mt-gd-1_61.lib
libboost_math_c99l-vc140-mt-gd-1_61.lib
libboost_math_tr1-vc140-mt-gd-1_61.lib
libboost_math_tr1f-vc140-mt-gd-1_61.lib
libboost_math_tr1l-vc140-mt-gd-1_61.lib
libboost_mpi-vc140-mt-gd-1_61.lib
libboost_prg_exec_monitor-vc140-mt-gd-1_61.lib
libboost_program_options-vc140-mt-gd-1_61.lib
libboost_random-vc140-mt-gd-1_61.lib
libboost_regex-vc140-mt-gd-1_61.lib
libboost_serialization-vc140-mt-gd-1_61.lib
libboost_signals-vc140-mt-gd-1_61.lib
libboost_system-vc140-mt-gd-1_61.lib
libboost_test_exec_monitor-vc140-mt-gd-1_61.lib
libboost_thread-vc140-mt-gd-1_61.lib
libboost_timer-vc140-mt-gd-1_61.lib
libboost_unit_test_framework-vc140-mt-gd-1_61.lib
libboost_wave-vc140-mt-gd-1_61.lib
libboost_wserialization-vc140-mt-gd-1_61.lib
qhull_d.lib
qhull_p_d.lib
qhull_r_d.lib
qhullcpp_d.lib
qhullstatic_d.lib
qhullstatic_r_d.lib
vtkalglib-7.0-gd.lib
vtkChartsCore-7.0-gd.lib
vtkCommonColor-7.0-gd.lib
vtkCommonComputationalGeometry-7.0-gd.lib
vtkCommonCore-7.0-gd.lib
vtkCommonDataModel-7.0-gd.lib
vtkCommonExecutionModel-7.0-gd.lib
vtkCommonMath-7.0-gd.lib
vtkCommonMisc-7.0-gd.lib
vtkCommonSystem-7.0-gd.lib
vtkCommonTransforms-7.0-gd.lib
vtkDICOMParser-7.0-gd.lib
vtkDomainsChemistry-7.0-gd.lib
vtkexoIIc-7.0-gd.lib
vtkexpat-7.0-gd.lib
vtkFiltersAMR-7.0-gd.lib
vtkFiltersCore-7.0-gd.lib
vtkFiltersExtraction-7.0-gd.lib
vtkFiltersFlowPaths-7.0-gd.lib
vtkFiltersGeneral-7.0-gd.lib
vtkFiltersGeneric-7.0-gd.lib
vtkFiltersGeometry-7.0-gd.lib
vtkFiltersHybrid-7.0-gd.lib
vtkFiltersHyperTree-7.0-gd.lib
vtkFiltersImaging-7.0-gd.lib
vtkFiltersModeling-7.0-gd.lib
vtkFiltersParallel-7.0-gd.lib
vtkFiltersParallelImaging-7.0-gd.lib
vtkFiltersProgrammable-7.0-gd.lib
vtkFiltersSelection-7.0-gd.lib
vtkFiltersSMP-7.0-gd.lib
vtkFiltersSources-7.0-gd.lib
vtkFiltersStatistics-7.0-gd.lib
vtkFiltersTexture-7.0-gd.lib
vtkFiltersVerdict-7.0-gd.lib
vtkfreetype-7.0-gd.lib
vtkGeovisCore-7.0-gd.lib
vtkhdf5-7.0-gd.lib
vtkhdf5_hl-7.0-gd.lib
vtkImagingColor-7.0-gd.lib
vtkImagingCore-7.0-gd.lib
vtkImagingFourier-7.0-gd.lib
vtkImagingGeneral-7.0-gd.lib
vtkImagingHybrid-7.0-gd.lib
vtkImagingMath-7.0-gd.lib
vtkImagingMorphological-7.0-gd.lib
vtkImagingSources-7.0-gd.lib
vtkImagingStatistics-7.0-gd.lib
vtkImagingStencil-7.0-gd.lib
vtkInfovisCore-7.0-gd.lib
vtkInfovisLayout-7.0-gd.lib
vtkInteractionImage-7.0-gd.lib
vtkInteractionStyle-7.0-gd.lib
vtkInteractionWidgets-7.0-gd.lib
vtkIOAMR-7.0-gd.lib
vtkIOCore-7.0-gd.lib
vtkIOEnSight-7.0-gd.lib
vtkIOExodus-7.0-gd.lib
vtkIOExport-7.0-gd.lib
vtkIOGeometry-7.0-gd.lib
vtkIOImage-7.0-gd.lib
vtkIOImport-7.0-gd.lib
vtkIOInfovis-7.0-gd.lib
vtkIOLegacy-7.0-gd.lib
vtkIOLSDyna-7.0-gd.lib
vtkIOMINC-7.0-gd.lib
vtkIOMovie-7.0-gd.lib
vtkIONetCDF-7.0-gd.lib
vtkIOParallel-7.0-gd.lib
vtkIOPLY-7.0-gd.lib
vtkIOSQL-7.0-gd.lib
vtkIOVideo-7.0-gd.lib
vtkIOXML-7.0-gd.lib
vtkIOXMLParser-7.0-gd.lib
vtkjpeg-7.0-gd.lib
vtkjsoncpp-7.0-gd.lib
vtklibxml2-7.0-gd.lib
vtkmetaio-7.0-gd.lib
vtkNetCDF-7.0-gd.lib
vtkNetCDF_cxx-7.0-gd.lib
vtkoggtheora-7.0-gd.lib
vtkParallelCore-7.0-gd.lib
vtkpng-7.0-gd.lib
vtkproj4-7.0-gd.lib
vtkRenderingAnnotation-7.0-gd.lib
vtkRenderingContext2D-7.0-gd.lib
vtkRenderingCore-7.0-gd.lib
vtkRenderingFreeType-7.0-gd.lib
vtkRenderingImage-7.0-gd.lib
vtkRenderingLabel-7.0-gd.lib
vtkRenderingLOD-7.0-gd.lib
vtkRenderingVolume-7.0-gd.lib
vtkRenderingOpenGL-7.0-gd.lib
vtksqlite-7.0-gd.lib
vtksys-7.0-gd.lib
vtktiff-7.0-gd.lib
vtkverdict-7.0-gd.lib
vtkViewsContext2D-7.0-gd.lib
vtkViewsCore-7.0-gd.lib
vtkViewsInfovis-7.0-gd.lib
vtkzlib-7.0-gd.lib
OpenNI2.lib

这就完成了配置过程,将一下程序导入项目中,运行显示结果

#include 
#include 
#include 
int
main(int argc,char**argv)
{
    pcl::PointCloud cloud;
    // 创建点云
    cloud.width=5;
    cloud.height=1;
    cloud.is_dense=false;
    cloud.points.resize(cloud.width*cloud.height);
    for(size_t i=0;i

显示如下结果即配置成功。
PCL点云数据库——第一篇(开发环境的搭建)_第6张图片

你可能感兴趣的:(PCL点云数据库)