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

Revision history [back]

Hi everybody,

even though I get the output "Failed to find match for field", the PC is actually filled via the pcl::fromROSMsg command.

In order to do so, I added the points to the Point type with that:

//define velocity point
#define PCL_ADD_UNION_POINTV \
   union EIGEN_ALIGN16 { \
     struct { \
       float v_x; \
       float v_y; \
       float v_z; \
         }; \
     };


struct PointOdometry
{
    PCL_ADD_POINT4D;                  // preferred way of adding a XYZ+padding
    PCL_ADD_UNION_POINTV;
...
    PCL_ADD_INTENSITY;

Then I set up the pointcloud message by always adding a padding around those upper blocks and the intensity block.

Strangely, for the intensity and xyz I do not get the warning msg but only for my own added data. But with that solution any workarounds become obsolete.