I work with PCL and the Mesh editor (MeshLab). I am interested in importing my grids in PCL for 3D processing.
I have a grid model in Ply format. When I load the model with code:
PointCloud<PointXYZRGBA>::Ptr cloud (new PointCloud<PointXYZRGBA> ()); pcl::io::loadPLYFile<pcl::PointXYZRGBA>(argv[1], *cloud);
and I present it as a point cloud:
visualization::PCLVisualizer viewer ("Model"); viewer.addPointCloud (cloud,"model");
geometry differs from loading and rendering the mesh directly:
viewer.addModelFromPLYFile(argv[1], "model");
In the second case, I visualize the model in the same way as in the Mesh editor, but in the first case I visualize its deformed version, i.e. sphere and ellipsoid are similar. What's going on here? Maybe I should manually sample the mesh?
If I add two models to the viewer, the difference will become very obvious, the point cloud will be smaller than the grid, and it will get some strange deformation (see the attached image)
Thank you very much

(source: pcl-users.org )
source share