gpt4 book ai didi

ios - 如何在 ArKit iOS 中将 3D 点转换为 2D 点

转载 作者:行者123 更新时间:2023-11-28 20:59:02 26 4
gpt4 key购买 nike

如何从 3d SCNNode 获取 2d 点以绘制到 uiview。

假设我有以下 SCNNodes

pos(1.002163 -0.524722 -0.770023)
pos(1.174463 -0.765098 -0.607172)
pos(0.668790 -0.744061 -0.696863)
pos(0.781208 -0.744061 -1.228943)

我需要上面的二维点。我是 Arkit 的新手。

最佳答案

您正在寻找projectPoint

let projectedPoint = sceneView.projectPoint(pos)

关于ios - 如何在 ArKit iOS 中将 3D 点转换为 2D 点,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50741286/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com