Ubuntu16.04跑loam_velodyne


Ubuntu16.04,ros kinetic

其實按照github上的README.md來編譯就好

cd ~/catkin_ws/src

git clone https://github.com/laboshinl/loam_velodyne.git

cd ..

catkin_make -DCMAKE_BUILD_TYPE=Release

 

報錯:

/loam_velodyne-master/src/lib/LaserMapping.cpp:149:28: error: ‘downSizeFilterMap’ was not declared in this scope
downSizeFilterMap().setLeafSize(fParam, fParam, fParam);

在github的issue中查找報錯,找到loam_velodyne-master/src/lib/LaserMapping.cpp下的149行,將這幾行注釋掉

/*
/// unused code 
if (privateNode.getParam("mapFilterSize", fParam))
{
if (fParam < 0.001)
{
ROS_ERROR("Invalid mapFilterSize parameter: %f (expected >= 0.001)", fParam);
return false;
}
else
{
downSizeFilterMap().setLeafSize(fParam, fParam, fParam);
ROS_INFO("Set map down size filter leaf size: %g", fParam);
}
}
*/

 

再source一下就好了:

source ~/catkin_ws/devel/setup.bash

 

 

 

Reference:

https://github.com/laboshinl/loam_velodyne/tree/master

https://github.com/laboshinl/loam_velodyne/pull/84/commits/d7c9359f6c643a4b2d960ec14e3a303dcf102ccd

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM