kinect2相机在ubuntu16.04下运行orbslam2时出现的问题及解决方法
问题1:在运行./build_ros.sh时报以下错误
/usr/bin/ld: CMakeFiles/RGBD.dir/src/ros_rgbd.cc.o: undefined reference to symbol ‘_ZN5boost6system15system_categoryEv’
/usr/lib/x86_64-linux-gnu/libboost_system.so: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
CMakeFiles/RGBD.dir/build.make:220: recipe for target ‘…/RGBD’ failed
make[2]: *** […/RGBD] Error 1
CMakeFiles/Makefile2:67: recipe for target ‘CMakeFiles/RGBD.dir/all’ failed
make[1]: *** [CMakeFiles/RGBD.dir/all] Error 2
Makefile:127: recipe for target ‘all’ failed
make: *** [all] Error 2解决方法:在ORBSLAM2/Examples/ROS/ORBSLAM2下的Cmakelists.txt中添加一行,-lboost_system
问题2:
运行rosrun ORB_SLAM2 RGBD /home/liu/ORB_SLAM2/Vocabulary/ORBvoc.txt /home/liu/ORB_SLAM2/Examples/RGB-D/kinect2_qhd.yaml时找不到kinect2_qhd.yaml这个文件
解决方法:在Example/RGB-D目录下,重新写一个类似TUM.yaml的文件,命名为kinect2_qhd.yaml,kinect2_qhd.yaml为自己的kinect2的参数的文件夹,所以在运行这个程序之前最好做好kinect2的标定工作。