In the previous article we got a 3D lidar point cloud image, there is a. bag file, and then we use the end of the previous procedure to run the Loam_velodyne algorithm, the results shown in Rviz are as follows:
Pcd->octomap ">
Then we can see with rqt_graph:
Pcd->octomap ">
Pcd->octomap ">
Pcd->octomap ">
The above three images are the relationship of all, active and nodes only node and topic. After testing in Rviz, we found that the topic is the whole point cloud of the/laser_cloud_surround, and we use the following instructions to convert the bag data into a PCD format:
Rosrun Pcl_ros BAG_TO_PCD input.bag/laser_cloud_surround PCD
The converted PCD file will be stored in the specified PCD directory, because this is not each frame real-time point cloud, but gradually accumulate a matching synthesis of the overall point cloud, so we choose the last one PCD file, that is the complete set of point cloud. At this point we can show the effect with Pcl_viewer:
Pcd->octomap ">
The next step is to convert the PCD file to Octomap, and we use an open source code (link), compiled with the g++ of the c++11 rule:
./pcd2octomap 1.PCD 1.BT
The obtained BT file is the Octomap file, then we download the Octomap and then use the Octovis to display:
The following effects:
Pcd->octomap ">
Let's zoom in to see:
Pcd->octomap ">
Next, do the reconstruction of the map.
Reprint Please specify: Transfer from http://blog.csdn.net/littlethunder/article/details/51955849