GlobalTransform

GlobalTransform

Metódusok

Methods GlobalTransform class csak olvasható nézetet biztosít egy csomópont világkoordináta-transzformációs mátrixáról. A mátrix a gyökértől a jelenlegi csomópontig terjedő összes ős csomópont helyi transzformációinak összetételével kerül kiszámításra.

Elérés a node.GlobalTransform. Az egyetlen tulajdonság Matrix (típus Matrix4), amely a komponált világkoordináta-transzformációt tartalmazza.

using Aspose.ThreeD;

var scene = new Scene();
var parent = scene.RootNode.CreateChildNode("Parent");
parent.Transform.Translation = new FVector3(10, 0, 0);

var child = parent.CreateChildNode("Child");
child.Transform.Translation = new FVector3(5, 0, 0);

// Access the composed world-space matrix
Matrix4 worldMatrix = child.GlobalTransform.Matrix;

Metódusok

NameTypeAccessDescription
TranslationVector3ReadGets the translation
ScaleVector3ReadGets the scale
EulerAnglesVector3ReadGets the rotation represented in Euler angles, measured in degree
RotationQuaternionReadGets the rotation represented in quaternion.
TransformMatrixMatrix4ReadGets the transform matrix.

Lásd még:

 Magyar