Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

You could do this in ROS Hydro PCL 1.7 if your mesh was a pcl::PolygonMesh:

const std::string meshFileName = "test.stl";

pcl::PolygonMesh testMesh;

pcl::io::loadPolygonFileSTL( meshFileName, testMesh );

pcl_conversions::fromPCL( testMesh.cloud, output );

You could do this in ROS Hydro PCL 1.7 if your mesh was a pcl::PolygonMesh:

#include <pcl/io/vtk_io.h>

const std::string meshFileName = "test.stl";

"test.stl"; pcl::PolygonMesh testMesh;

pcl::PolygonMesh testMesh;

pcl::io::loadPolygonFileSTL( meshFileName, testMesh );

);

pcl_conversions::fromPCL( testMesh.cloud, output );

);

You could do this in ROS Hydro PCL 1.7 if your mesh was a pcl::PolygonMesh:

#include <pcl io="" vtk_lib_io.h="">

#include <pcl/io/vtk_io.h>

const std::string meshFileName = "test.stl";

pcl::PolygonMesh testMesh;
 pcl::io::loadPolygonFileSTL( meshFileName, testMesh );
);    
pcl_conversions::fromPCL( testMesh.cloud, output );