pymeshfix.PyTMesh#

class pymeshfix.PyTMesh(*args, **kwargs)#

Mesh repair and cleaning class.

Wraps the MeshFix Basic_TMesh functionality and exposes it to Python. Provides methods to inspect, repair, and extract mesh data.

Methods

PyTMesh.boundaries(-> None)

PyTMesh.clean(self[, max_iters, inner_loops])

Perform iterative mesh cleaning and repair.

PyTMesh.fill_small_boundaries(self[, nbe, ...])

Fill small boundary loops (holes) in the mesh.

PyTMesh.fix_connectivity(self)

Repair mesh connectivity issues.

PyTMesh.join_closest_components(self)

Join the closest disconnected mesh components.

PyTMesh.load_array(self, points_arr[, ...])

Load a surface mesh from vertex and face arrays.

PyTMesh.load_file(self, filename)

Load a surface mesh from a file.

PyTMesh.remove_smallest_components(self)

Remove all but the largest connected mesh component.

PyTMesh.return_arrays(self)

Return mesh data as vertex and face arrays.

PyTMesh.return_faces(self)

Return the face array.

PyTMesh.return_points(self)

Return the vertex array.

PyTMesh.save_file(self, filename[, back_approx])

Save the mesh to a file.

PyTMesh.select_intersecting_triangles(self, ...)

Select intersecting triangles in the mesh.

PyTMesh.set_quiet(self, arg, /)

Enable or disable console output.

PyTMesh.strong_degeneracy_removal(self, arg, /)

Iteratively removes degenerate triangles and closes holes.

PyTMesh.strong_intersection_removal(self, arg, /)

Iteratively removes self-intersecting triangles.

Attributes

PyTMesh.n_boundaries

Number of boundary loops in the mesh.

PyTMesh.n_faces

Number of faces in the mesh.

PyTMesh.n_points

Number of points in the mesh.