我想首先围绕对象的 x 轴旋转 90 度,然后围绕对象的 y 轴旋转 90 度。我怎样才能在 Three.js 中做到这一点?
我试过了
mesh.rotation.x = Math.PI * 0.5;
mesh.rotation.y = Math.PI * 0.5;
但它没有按照我想要的方式旋转。
最佳答案
我们可以这样实现,
mesh.rotateX(Math.PI * 0.5);
mesh.rotateY(Math.PI * 0.5);
关于javascript - 如何使用四元数绕x轴然后y轴旋转,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55913126/