Euler
Core.Euler exported from @manycore/aholo-viewer.
Constructors
constructor
Parameters
- x: number
- y: number
- z: number
- order: string
Returns Euler
Properties
_ x
_ y
The angle of the y axis in radians.
_ z
The angle of the z axis in radians.
_ order
A string representing the order that the rotations are applied.
is Euler
Check the type whether it belongs to Euler. This value should not be changed by user.
on Change Callback
StaticRotation Orders
All possible value for order.
StaticDefault Order
The default of order.
Accessors
x
- get x(): number
Returns number
- set x(value: number): void
Parameters
- value: number
Returns void
y
- get y(): number
Returns number
- set y(value: number): void
Parameters
- value: number
Returns void
z
- get z(): number
Returns number
- set z(value: number): void
Parameters
- value: number
Returns void
order
- get order(): string
Returns string
- set order(value: string): void
Parameters
- value: string
Returns void
Methods
set
clone
Returns a new Euler with the same parameters as this one.
Returns Euler
copy
set From Rotation Matrix
Sets the angles of this euler transform from a pure rotation matrix based on the orientation specified by order.
Parameters
- m: Matrix4
a Matrix4 of which the upper 3x3 of matrix is a pure rotation matrix (i.e. unscaled).
- order: string
(optional) a string representing the order that the rotations are applied.
- update: boolean
Returns Euler
- m: Matrix4
set From Quaternion
Sets the angles of this euler transform from a normalized quaternion based on the orientation specified by order.
Parameters
- q: Quaternion
a normalized quaternion.
- order: string
(optional) a string representing the order that the rotations are applied.
- update: boolean
Returns Euler
- q: Quaternion
set From Vector3
reorder
Resets the euler angle with a new order by creating a quaternion from this euler angle and then setting this euler angle with the quaternion and the new order.
Parameters
- newOrder: string
Returns Euler
equals
from Array
Array of length 3 or 4. The optional 4th argument corresponds from the order. Assigns this euler's x angle from array[0]. Assigns this euler's y angle from array[1]. Assigns this euler's z angle from array[2]. Optionally assigns this euler's order from array[3].
Parameters
- array: ArrayLike<number>
Returns Euler
The angle of the x axis in radians.