ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

Check http://wiki.ros.org/hydro/Migration#PCL

sensor_msgs::PointCloud2 and pcl::PCLPontCloud2 are the message-transport forms of pointclouds, in the ROS and PCL variety. They contain the raw data.

pcl::PointCloud<> is the template form of point clouds that allows you to work with individual points in a more sane manner.

fromPCLPointCloud2 and toPCLPointCloud2 are PCL library functions for conversions. ROS has wrappers for those functions in pcl_conversions/pcl_conversions.h that you should use instead. These will call the right combinations of functions to convert between the message and templated format.

If you include pcl_ros/point_cloud.h, you can avoid doing conversions and subscribe/publish directly with the templated form.