pymeshfix.clean_from_arrays

pymeshfix.clean_from_arrays()

Performs default cleaning procedure on vertex and face arrays.

Returns cleaned vertex and face arrays

Parameters
  • v (numpy.ndarray) – Numpy n x 3 array of vertices

  • f (numpy.ndarray) – Numpy n x 3 array of faces.

  • verbose (bool, optional) – Prints progress to stdout. Default True.

  • joincomp (bool, optional) – Attempts to join nearby open components. Default False.

  • remove_smallest_components (bool, optional) – Remove all but the largest isolated component from the mesh before beginning the repair process. Default True.

Returns

  • numpy.ndarray – Points array.

  • numpy.ndarray – Faces array.

Examples

>>> import pymeshfix
>>> import numpy as np
>>> points = np.load('points.npy')
>>> faces = np.load('faces.npy')
>>> clean_points, clean_faces = pymeshfix.clean_from_arrays(points, faces)