From 960c07f5b5a359530ea189231f8b8472413b356d Mon Sep 17 00:00:00 2001 From: Jim Miller Date: Mon, 23 Sep 2019 07:30:14 -0400 Subject: [PATCH] Avoid creating degenerate geometry Instruct trimesh to NOT merge vertices when loading PLY file. Trimesh's attempt to "clean up" a mesh results in meshes with degenerate geometry. --- FullTextureMapper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FullTextureMapper.py b/FullTextureMapper.py index cc6be9d..eeb825e 100644 --- a/FullTextureMapper.py +++ b/FullTextureMapper.py @@ -222,7 +222,7 @@ def __init__(self, ply_path, aoi_filename, recon_path, self.reconstruction = Reconstruction(aoi_filename, recon_path, use_skewed_images) - self.tmesh = trimesh.load(ply_path) + self.tmesh = trimesh.load(ply_path, process=False) # don't merge vertices on load print('num_vertices: {}'.format(np.shape(self.tmesh.vertices)[0])) print('number of facets (excluding singletons): {}'.format( np.shape(self.tmesh.facets)[0]))