Get the faces out of a mesh created by ofDelaunay

Hi,

I’m using the Delauney addon to create a mesh from a pointcloud. I can add colors or get the vertices out of that mesh no problem but the faces seem inaccessible. ofMesh doesn’t seem to have that feature am I correct? Is there a away around this? Can I get the polygon definitions somehow maybe? Any ideas?

Thanks.

ofMesh does have. You can get an index of a vertex by int ofMesh::getIndex(int). Since ofxDelaunay uses primitive triangles, the first 3 indices (getIndex(0), getIndex(1), getIndex(2)) form the first triangle, and getIndex(3n), getIndex(3n+1), getIndex(3n+2) form the n-th triangle. Note that as I PRed, the current implementation does not preserve vertex orders after triangulation: https://github.com/obviousjim/ofxDelaunay/pull/4

Thanks so much, I got it working!