Quaternion

クオータニオンを表すstructです.

Constructors

this
this(T x, T y, T z, T w)
this
this(T s, V3 v)
this
this(V3 v)
this
this(V4 v)

Members

Aliases

Q
alias Q = Quaternion!(T)
Undocumented in source.
V3
alias V3 = armos.math.Vector!(T, 3)
Undocumented in source.
V4
alias V4 = armos.math.Vector!(T, 4)
Undocumented in source.

Functions

conjugate
Q conjugate()

Quaternionの共役Quaternionを返します.

inverse
Q inverse()
matrix33
armos.math.Matrix!(T, 3, 3) matrix33()

自身の回転行列(3x3)を返します.

matrix44
armos.math.Matrix!(T, 4, 4) matrix44()

自身の回転行列(4x4)を返します.

norm
T norm()

Quaternionのノルムを返します.

normalized
Q normalized()
opAdd
Q opAdd(Q q)
opCast
CastedType opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opDiv
Q opDiv(T r)
opIndex
T opIndex(int index)
opIndex
T opIndex(int index)
opMul
Q opMul(Q r_quat)
opMul
Q opMul(T r)
opNeg
Q opNeg()
productAngle
Q productAngle(T gain)
Undocumented in source. Be warned that the author may not have intended to support it.
rotatedVector
V3 rotatedVector(V3 vec)

指定したベクトルを自身で回転させたベクトルを返します.

rotatedVectorInversely
V3 rotatedVectorInversely(V3 vec)

指定したベクトルを自身の逆方向に回転させたベクトルを返します.

Static functions

angleAxis
Q angleAxis(T ang, V3 axis)

指定した軸で自身を回転させます.

unit
Q unit()
zero
Q zero()

Variables

vec
V4 vec;

vec[0];x vec[1];y vec[2];z vec[3];w

Meta