splitmesh.py 316 B

12345678910
  1. """Split a mesh by connectivity and
  2. order the pieces by increasing surface area"""
  3. from vedo import dataurl, Volume, show
  4. em = Volume(dataurl+"embryo.tif").isosurface(80)
  5. # return the list of the largest 10 connected meshes:
  6. splitem = em.split(maxdepth=40)[0:9]
  7. show(splitem, __doc__, axes=1, viewup='z').close()