How to iterate over the vertices of a poly face and alter the humber

Pretty much the title. I am trying to clip a mesh against a plane, to that effect i need to check each face against the plane and either delete the face or modify it introducing new vertices. I am trying this to access the vertices: ```cpp MyMesh::FaceIter f_it, v_end(mesh.faces_end()); uint count = 0; for (f_it=mesh.faces_begin(); f_it!=v_end;) { auto old_it = f_it; MyMesh::FaceVertexCCWIter fv_iter = mesh.fv_ccwiter(old_it); std::vector< MyMesh::VertexIter > new_face_verts; for (; fv_iter.is_valid(); ++fv_iter) { mesh.point(fv_iter); } ++f_it; mesh.delete_face(*old_it, true); } mesh.garbage_collection(); ``` But this is apparently invalid. As no method in the mesh accepts that iterator.

It looks like you're not dereferencing the iterator correctly. Can you try mesh.point(*fv_iter);
participants (2)
-
Alexander Schier
-
camilotalero96@hotmail.com