vcg_count_edge_defects: Count boundary and non-manifold edges of a triangular mesh
Description
Detects topology defects that prevent a mesh from being a closed,
manifold, genus-0 surface, a hard precondition of algorithms such as
mris_inflate. An edge is a boundary edge when it is
referenced by exactly one face (i.e. it bounds a hole), and
non-manifold when it is referenced by more than two faces.
Usage
vcg_count_edge_defects(mesh)
Value
A named list with elements boundary_edges (number of
boundary edges), nonmanifold_edges (number of non-manifold edges),
and is_closed_manifold (TRUE when both counts are zero,
i.e. the mesh is closed and manifold and ready for
mris_inflate).