trimesh_split_edge

compas.datastructures.trimesh_split_edge(mesh, edge, t=0.5, allow_boundary=False)[source]

Split an edge of a triangle mesh.

Parameters:
meshcompas.datastructures.Mesh

Instance of a mesh.

edgetuple[int, int]

The identifier of the edge to split.

tfloat, optional

The location of the split point along the original edge. The value should be between 0.0 and 1.0

allow_boundarybool, optional

If True, allow splits on boundary edges.

Returns:
int | None

The identifier of the split vertex, if the split was successful.

Notes

This operation only works as expected for triangle meshes.