m3sh.traits.
cotan_weight#
- cotan_weight(halfedge, boundary=nan, clamp=False)#
Cotangent weight.
Compute the cotangent of the angle opposite of halfedge.
- Parameters:
- halfedgeHalfedge
A halfedge instance of a triangle mesh.
- boundaryfloat, optional
Default value if halfedge is on the boundary. A
nanvalue typically signals missing data. For numerical computations the value 0.0 can be useful to skip missing data without raising an error.- clampbool, optional
Pass
Trueto set negative weights to zero.
- Returns: