Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

If you haven't figured it out already (or it's an omission in your code copying), it looks like the downsampled cloud pointer has not been initialized with a valid cloud. You pass the dereferenced shared pointer in the sor.filter(*downsampled) line...

At some point, you need: downsampled.reset(new sensor_msgs::PointCloud2)

In addition, the output cloud pointer has not been initialized, so the call to pcl::toROSMsg(*output_p, *output) will also generate an error.

If that is not the problem, you'll probably have to provide some more information (like a backtrace from gdb or something)...

Hope this helps.