Xfo.kl¶
Types¶
Xfo (struct)¶
The Xfo type represents a 3D transform. It uses a Vec3 for translation as scaling as well as a Quat for its rotation. The Xfo can also be expressed as a Mat44, and provides conversion methods for that type.
/*
** Example: Xfo
*/
// create a transform
Xfo xfo;
// change the transform
xfo.tr.x = 3.0;
xfo.ori.setFromAxisAndAngle(Vec3(1.0, 0.0, 0.0), 0.65);
xfo.sc *= Vec3(1, 2, 3);
// project a vector
Vec3 pos = xfo.transformVector(Vec3(0, 10, 0));
Methods¶
Xfo ( in Mat44 mat ) | |
Xfo ( in Quat ori ) | |
Xfo ( in Quat ori, in Vec3 tr, in Vec3 sc ) | |
Xfo ( in Scalar scX, in Scalar scY, in Scalar scZ, in Scalar eulerX, in Scalar eulerY, in Scalar eulerZ, in Scalar trX, in Scalar trY, in Scalar trZ ) | |
Xfo ( in Vec3 tr ) | |
Xfo ( in Vec3 tr, in Quat ori ) | |
Xfo ( in Vec3 tr, in Quat ori, in Vec3 sc ) | |
Xfo ( in Xfo other ) | |
Xfo () | |
XfoFromScalars ! ( in Scalar scX, in Scalar scY, in Scalar scZ, in Scalar degreeX, in Scalar degreeY, in Scalar degreeZ, in Scalar trX, in Scalar trY, in Scalar trZ ) | |
XfoFromVec3s ! ( in Vec3 sc, in Vec3 rotInDeg, in Vec3 tr ) | |
Xfo | clone ? () |
Scalar | distanceTo ? ( in Xfo other ) |
get ? ( io Float32 v<> ) | |
get ? ( io Float32 v<>, in UInt32 o ) | |
get ? ( io Float32 v[] ) | |
get ? ( io Float32 v[], in UInt32 o ) | |
get ? ( io Float64 v<> ) | |
get ? ( io Float64 v<>, in UInt32 o ) | |
get ? ( io Float64 v[] ) | |
get ? ( io Float64 v[], in UInt32 o ) | |
UInt32 | hash ? () |
Xfo | inverse ? () |
Vec3 | inverseTransformVector ? ( in Vec3 vec ) |
Xfo | linearInterpolate ? ( in Xfo other, in Scalar t ) |
Xfo | multiply ? ( in Xfo global ) |
set ! ( in Float32 v<> ) | |
set ! ( in Float32 v<>, in UInt32 o ) | |
set ! ( in Float64 v<> ) | |
set ! ( in Float64 v<>, in UInt32 o ) | |
set ! ( in Mat33 mat ) | |
set ! ( in Quat ori ) | |
set ! ( in Quat ori, in Vec3 tr, in Vec3 sc ) | |
set ! ( in Vec3 tr ) | |
set ! ( in Vec3 tr, in Quat ori ) | |
set ! ( in Vec3 tr, in Quat ori, in Vec3 sc ) | |
setFromMat44 ! ( in Mat44 m ) | |
setIdentity ! () | |
Xfo | sphericalLinearInterpolate ? ( in Xfo other, in Scalar t ) |
Vec3 | subtractTranslation ? ( in Xfo other ) |
Mat44 | toMat44 ? () |
Ray | transformRay ? ( in Ray ray ) |
Vec3 | transformVector ? ( in Vec3 v ) |