perception_pcl icon indicating copy to clipboard operation
perception_pcl copied to clipboard

No header (frame_id) is set for the sensor_msgs::Image output of 'toROSMsg'

Open sayali-purdue opened this issue 4 years ago • 2 comments

There are three toROSMsg functions, converting input to sensor_msgs::Image output, in pcl_conversions.h

All these functions do not assign the header of the sensor_msgs::Image output variable unlike other conversion functions that convert to sensor_msgs::PointCloud2 in this file:

  1. toROSMsg at line #506: does conversion of the data, but does not assign the header of the output.
  2. toROSMsg at lines #486, #496: depend on pcl::toPCLPointCloud2 function of pcl library. This library function too does not set their output variable's header.

Would really appreciate if you can explain why the header (frame_id) of the image is not set? Should the frame of the output image be same as the input point cloud?

Thank you!

sayali-purdue avatar Aug 21 '20 21:08 sayali-purdue

Probably an oversight, a PR to fix would be appreciated.

SteveMacenski avatar Aug 21 '20 22:08 SteveMacenski

The linked pull request is a partial fix for the problem (more specifically, for the second point).

mvieth avatar Dec 06 '20 16:12 mvieth