trimesh_principal_curvature
- trimesh_principal_curvature(M)[source]
Compute the principal curvatures and directions of a triangle mesh.
Calculates both the principal curvature values and their corresponding directions at each vertex of the mesh.
- Parameters:
- Mtuple[list[list[float]], list[list[int]]]
A mesh represented by a tuple of (vertices, faces) where vertices are 3D points and faces are triangles
- Returns:
- tuple[list[list[float]], list[list[float]], list[float], list[float]]
A tuple containing: * PD1: Principal direction 1 per vertex (normalized vectors) * PD2: Principal direction 2 per vertex (normalized vectors) * PV1: Principal curvature value 1 per vertex (maximum curvature) * PV2: Principal curvature value 2 per vertex (minimum curvature)