点云三维凸包(附open3d python代码)

点云三维凸包(附open3d python代码)_第1张图片

 


# coding:utf-8

import open3d as o3d
import numpy as np

print("->正在加载点云... ")
pcd = o3d.io.read_point_cloud("gongjian1.pcd")
print(pcd)

print("->正在计算点云凸包...")
hull, _ = pcd.compute_convex_hull()
hull_ls = o3d.geometry.LineSet.create_from_triangle_mesh(hull)
hull_ls.paint_uniform_color((1, 0, 0))
o3d.visualization.draw_geometries([pcd, hull_ls])

你可能感兴趣的:(点云处理代码合集,numpy,python,算法)