m3sh.hds.Mesh.

delete_halfedge#

Mesh.delete_halfedge(halfedge, del_isolated_verts=True)#

Merge adjacent faces.

Merges the incident faces of an edge. Merging across a boundary edge will delete the incident non-boundary face. Vertices of halfedge rendered isolated by the change in mesh combinatorics can be kept as isolated vertices or be marked as deleted.

Parameters:
halfedgeHalfedge

The halfedge that spans the edge to be deleted.

del_isolated_vertsbool, optional

Mark isolated vertices for deletion.

Returns:
Face

The merged face or None when merging across the boundary. For interior halfedge, this is equal to the face to its right.

Raises:
NonManifoldError

If the operation leads to invalid combinatorics.

Notes

This operation may create dangling (half)edges, i.e., halfedges where h.pair equals h.next.