gpt4 book ai didi

ios - 详细解释 ScnVector4 方法

转载 作者:塔克拉玛干 更新时间:2023-11-02 09:06:46 27 4
gpt4 key购买 nike

我长期使用 3ds max,我知道 xyz 轴。我在 xcode 中看到的旋转 scnnode 让我大吃一惊的是 scnvector4 的 w 组件。

谁能详细解释一下如何使用这个方法,因为我搜索了很多时间,但我不能让我的物体按照我的意愿旋转。任何人都可以帮助他以 180 度向后旋转,但如果有人解释更多以进一步旋转,我将不胜感激,我知道我看到了这个链接,但我不明白。

http://www.cprogramming.com/tutorial/3d/rotationMatrices.html

最佳答案

我相信您正在尝试旋转节点(rotation 属性)。

来自文档:

The four-component rotation vector specifies the direction of the rotation axis in the first three components and the angle of rotation (in radians) in the fourth.

您可能会发现使用 eulerAngles 更容易:

The node’s orientation, expressed as pitch, yaw, and roll angles, each in radians

关于ios - 详细解释 ScnVector4 方法,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29019306/

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