update app.py for GLB output

#2
by AP123 - opened
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -388,7 +388,7 @@ def stage2_run(models, device, tmp_dir,
388
  mesh.vertices[:, 0] = -mesh.vertices[:, 0]
389
  mesh.faces = np.fliplr(mesh.faces)
390
  # Export the mesh as .obj file with colors
391
- mesh.export(mesh_path, file_type='obj', include_color=True)
392
  torch.cuda.empty_cache()
393
 
394
  if not is_rerun:
 
388
  mesh.vertices[:, 0] = -mesh.vertices[:, 0]
389
  mesh.faces = np.fliplr(mesh.faces)
390
  # Export the mesh as .obj file with colors
391
+ mesh.export(mesh_path.replace('.obj', '.glb'), file_type='glb', include_color=True)
392
  torch.cuda.empty_cache()
393
 
394
  if not is_rerun: