meshio_read.py 398 B

12345678910111213
  1. """Read and show meshio objects"""
  2. import meshio
  3. from vedo import download, show, Mesh
  4. fpath = download('https://vedo.embl.es/examples/data/shuttle.obj')
  5. mesh = meshio.read(fpath)
  6. # vedo understands meshio format for polygonal data:
  7. # show(mesh, __doc__, axes=7)
  8. # explicitly convert it to a vedo.Mesh object:
  9. m = Mesh(mesh).linewidth(1).color('tomato').print()
  10. show(m, __doc__, axes=7).close()