File size: 350 Bytes
674e95d
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import open3d as o3d

def load_mesh_from_path(path):
    mesh = o3d.io.read_triangle_mesh(path)

    return mesh

def load_mesh_from_vertices_and_triangles(vertices, triangles):
    mesh = o3d.geometry.TriangleMesh()
    mesh.vertices = o3d.utility.Vector3dVector(vertices)
    mesh.triangles = o3d.utility.Vector3iVector(triangles)

    return mesh