Three.js - 做什么矩阵在3D对象重新present [英] Three.js - what do the matrices in a 3D object represent

查看:211
本文介绍了Three.js - 做什么矩阵在3D对象重新present的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

看着THREE.Object3D的来源,有三个属性:基质 matrixWorld matrixRotationWorld

Looking at the source of THREE.Object3D, there are three properties: matrix, matrixWorld and matrixRotationWorld.

我看到物体的位置,比例和旋转可以从基质提取。我也看到,对象上的一点世界上的地位可以从 matrixWorld 被提取出来。

I see that the object's position, scale and rotation can be extracted from matrix. I also see that the world position of a point on the object can be extracted from matrixWorld.

我的问题:

  • 不要基质 matrixWorld 重present相同的信息,即可以矩阵转换到matrixWorld,反之亦然?

  • Do matrix and matrixWorld represent the same information, i.e. can matrix be converted to matrixWorld, and vice versa?

这是什么matrixRotationWorld重新present?它曾经是什么?并且可以将其转换成基质和/或 matrixWorld

What does matrixRotationWorld represent? What is it used for? And can it be converted to matrix and/or matrixWorld?

感谢

推荐答案

object.matrix 是矩阵变换的对象。

object.matrixWorld 是矩阵变换的对象,考虑到矩阵变换对象的父。 (对象的父母可能也有父母,所以计算 object.matrixWorld 是递归的。)

object.matrixWorld is the matrix transform of the object, taking into consideration the matrix transform of the object's parent. (The object's parent may also have a parent, so the calculation of object.matrixWorld is recursive.)

object.matrix object.matrixWorld 是相同的,当对象没有父,比场景中的其他。

object.matrix and object.matrixWorld are identical when the object has no parent, other than the scene.

object.matrixRotationWorld 已不存在。

three.js r.69

three.js r.69

这篇关于Three.js - 做什么矩阵在3D对象重新present的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆