flyinggod

为了进一步便于分析或者分割点云数据,时常需要将稀疏点云激光数据,例如velodyne-16,转化为RangeImge,此处为一个例程,方便查看转化是如何完成的

mkdir -p ~/dev/pointcloud_to_rangeimage_ws/src
cd ~/dev/pointcloud_to_rangeimage_ws/src
git clone https://github.com/artivis/pointcloud_to_rangeimage
cd ..
catkin_make 

此例子生成两个结点,pointcloud_to_rangeimage_node和rangeimage_to_pointcloud_node,此博客只使用pointcloud_to_rangeimage_node节点如何利用16线激光数据生成RangeImage的测试。首先,我的激光数据的Topic与源文件内声明的Topic不一致,做如下修改,将 pointcloud_to_rangeimage_node.cpp

 sub_ = nh.subscribe<PointCloud>("point_cloud_in", 1, &RangeImageConverter::callback, this);

修改为自己的数据topic

 sub_ = nh.subscribe<PointCloud>("/velodyne_points", 1, &RangeImageConverter::callback, this);

1. 启动roscore 和 rviz 

#terminal 1
roscore
#termenal 2
rosrun rviz rviz

2. rosbag回放velodyne数据

rosbag play out.bag

out.bag记录的是topics: /velodyne_points的点云数据

3. rviz中配置Fixed Frame 和 添加对 LaserScan和Image的观测

结果如下

 

分类:

技术点:

相关文章:

  • 2021-09-16
  • 2021-08-18
  • 2021-11-19
  • 2021-11-07
  • 2021-10-19
  • 2021-05-26
  • 2022-01-17
  • 2021-12-04
猜你喜欢
  • 2021-11-19
  • 2021-09-15
  • 2021-12-10
  • 2021-08-18
  • 2021-09-20
  • 2021-12-28
相关资源
相似解决方案