| 58 | constexpr char kMapFrameId[] = "/map"; |
| 59 | |
| 60 | void pointcloud_callback(const sensor_msgs::PointCloud2::ConstPtr& msg) { |
| 61 | pcl::PCLPointCloud2 pcl_pc2; |
| 62 | pcl_conversions::toPCL(*msg, pcl_pc2); |
| 63 | MapBuilder::PointCloudPtr incoming_cloud(new MapBuilder::PointCloudType); |
| 64 | pcl::fromPCLPointCloud2(pcl_pc2, *incoming_cloud); |
| 65 | |
| 66 | std::vector<int> inliers; // no use, just for the function |
| 67 | pcl::removeNaNFromPointCloud(*incoming_cloud, *incoming_cloud, inliers); |
| 68 | map_builder->InsertPointcloudMsg(incoming_cloud); |
| 69 | } |
| 70 | |
| 71 | void imu_callback(const sensor_msgs::Imu& imu_msg) { |
| 72 | ImuMsg::Ptr incomming_imu(new ImuMsg); |
no test coverage detected