Open3d 点云投影到 xoy yoz 平面最简单的方式(附python 代码)

最简单的方式,就是直接把原有的点云的数据的 z or x 赋值为0, 然后生成一个新的点云。

复制代码
filename_model1 = r"1.pcd"

down = 10

point_cloud = o3d.io.read_point_cloud(filename_model1)
point_cloud = point_cloud.uniform_down_sample(int(down))
print('降采样后点云:', point_cloud)



# asarray 会影响原有的数据!!!
point_cloud_xoy = np.array(point_cloud.points)
point_cloud_xoy[:, 2] = 0
pcdxoy = o3d.geometry.PointCloud()  # 使用numpy生成点云
pcdxoy.points = o3d.utility.Vector3dVector(point_cloud_xoy)  # points numpy数组
o3d.visualization.draw_geometries([pcdxoy])

point_cloud_yoz = np.array(point_cloud.points)
point_cloud_yoz[:, 1] = 0
pcdyoz = o3d.geometry.PointCloud()  # 使用numpy生成点云
pcdyoz.points = o3d.utility.Vector3dVector(point_cloud_yoz)  # points numpy数组
o3d.visualization.draw_geometries([pcdyoz])
相关推荐
伊玛目的门徒4 小时前
试用leetcode之典中典 二数之和问题
java·算法·leetcode
Jerry4 小时前
LeetCode 226. 翻转二叉树
算法
想做小南娘,发现自己是女生喵5 小时前
【无标题】
数据结构·算法
向日的葵0066 小时前
langchain的Tools教程(三)
python·langchain·tools
言乐67 小时前
Python实现可运行解密游戏游戏框架
python·游戏·小程序·游戏程序·关卡设计
Kx_Triumphs7 小时前
HDU4348 To the moon(主席树区间修改模板)
算法·题解
YUS云生7 小时前
Python学习笔记·第31天:FastAPI入门——路由、路径参数、查询参数与请求体
笔记·python·学习
旖-旎7 小时前
《LeetCode647 回文子串 || LeetCode 5 最长回文子串》
c++·算法·leetcode·动态规划·哈希算法
智写-AI8 小时前
真实有效的免费降英文AI工具服务商
人工智能·python