t3d. Euler

Euler class.

Constructor

new Euler(xopt, yopt, zopt, orderopt)

Parameters:
NameTypeAttributesDefaultDescription
xNumber<optional>
0
yNumber<optional>
0
zNumber<optional>
0
orderString<optional>
t3d.Euler.DefaultOrder

Members

order :String

Type:
  • String

order :String

Type:
  • String

x :Number

Type:
  • Number

x :Number

Type:
  • Number

y :Number

Type:
  • Number

y :Number

Type:
  • Number

z :Number

Type:
  • Number

z :Number

Type:
  • Number

(static, readonly) DefaultOrder

The default order in which to apply rotations.

(static, readonly) RotationOrders

The order in which to apply rotations.

Methods

clone() → {t3d.Euler}

Returns a new Euler with the same parameters as this one.
Returns:
Type: 
t3d.Euler

copy(euler) → {t3d.Euler}

Copies value of euler to this euler.
Parameters:
NameTypeDescription
eulert3d.Euler
Returns:
Type: 
t3d.Euler

onChange(callback) → {t3d.Euler}

Parameters:
NameTypeDescription
callbackfunctionWhen the Euler angle value changes, the callback method is triggered
Returns:
Type: 
t3d.Euler

set(x, y, z, order) → {t3d.Euler}

Parameters:
NameTypeDefaultDescription
xNumber0the angle of the x axis in radians.
yNumber0the angle of the y axis in radians.
zNumber0the angle of the z axis in radians.
orderString(optional) a string representing the order that the rotations are applied.
Returns:
Type: 
t3d.Euler

setFromQuaternion(q, order, updateopt) → {t3d.Euler}

Sets the angles of this euler transform from a normalized quaternion based on the orientation specified by order.
Parameters:
NameTypeAttributesDefaultDescription
qt3d.Quaterniona normalized quaternion.
orderString(optional) a string representing the order that the rotations are applied.
updateBoolean<optional>
trueWhether to notify Euler angle has changed
Returns:
Type: 
t3d.Euler

setFromRotationMatrix(m, order, updateopt) → {t3d.Euler}

Sets the angles of this euler transform from a pure rotation matrix based on the orientation specified by order.
Parameters:
NameTypeAttributesDefaultDescription
mt3d.Matrix4a Matrix4 of which the upper 3x3 of matrix is a pure rotation matrix
orderString(optional) a string representing the order that the rotations are applied.
updateBoolean<optional>
trueWhether to notify Euler angle has changed
Returns:
Type: 
t3d.Euler