PCL数据类型和ROS数据类型的转换

时间:2023-03-10 08:02:11
PCL数据类型和ROS数据类型的转换

参考网址 http://wiki.ros.org/pcl/Overview ,重点参看第2和第3节。

1. Data types

介绍了三种点云数据类型:sensor_msgs::PointCloud(不常用),sensor_msgs::PointCloud2pcl::PointCloud<T>

2. Point Cloud conversion

两种情形下需要进行数据转换

2.1. Converting between sensor_msgs::PointCloud2 and pcl::PointCloud<T> objects

2.2. Converting between the `sensor_msgs::PointCloud` and `sensor_msgs::PointCloud2` format

3. Publishing and subscribing to point cloud messages

代码演示,订阅和发布不同数据类型的点云。