Best way to add Triangles to Visualizer / Viewers

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Best way to add Triangles to Visualizer / Viewers

WoodMath
I'm trying to manually add triangles (either individually or in a group) to visualize various delaunay triangulation methods.


I was working under the assumption I could use either the pcl::visualization::CloudViewer class or pcl::visualization::PCLVisualizer class. I thought that might use the PCLVisualizer class ad it seems to have an AddPoloygonMesh method.

However, I don't know whether the pcl::PolygonMesh or pcl::geometry::TriangleMesh would be better to accomplish my task.

Any advice?

-Jeff
Reply | Threaded
Open this post in threaded view
|

Re: Best way to add Triangles to Visualizer / Viewers

VictorLamoine
Administrator
The only difference between TriangleMesh and PolygonMesh is that the latest allows you to store polygons with more than 3 vertices's.

This is rarely used with meshes, I've never seen any algorithm work with them. (I think it's mainly used in 3D "artistic" meshing).

Go with the PolygonMesh, it will be easier to load and save in various formats!
http://docs.pointclouds.org/trunk/group__io.html#ga7924eb86a2afb5ee752c7906545ad935