Constructors

  • Create one instance of this class

    Parameters

    • Optionalx: number

      (optional) the angle of the x axis in radians. Default is 0.

    • Optionaly: number

      (optional) the angle of the y axis in radians. Default is 0.

    • Optionalz: number

      (optional) the angle of the z axis in radians. Default is 0.

    • Optionalorder: string

      (optional) a string representing the order that the rotations are applied, defaults to 'XYZ' (must be upper case).

    Returns AcGeEuler

Properties

DEFAULT_ORDER: string

Accessors

  • get order(): string
  • The order in which to apply rotations. Default is 'XYZ', which means that the object will first be rotated around its X axis, then its Y axis and finally its Z axis. Other possibilities are: 'YZX', 'ZXY', 'XZY', 'YXZ' and 'ZYX'. These must be in upper case.

    It uses intrinsic Tait-Bryan angles. This means that rotations are performed with respect to the local coordinate system. That is, for order 'XYZ', the rotation is first around the local-X axis (which is the same as the world-X axis), then around local-Y (which may now be different from the world Y-axis), then local-Z (which may be different from the world Z-axis).

    Returns string

  • set order(value: string): void
  • Parameters

    • value: string

    Returns void

  • get x(): number
  • The current value of the x component.

    Returns number

  • set x(value: number): void
  • Parameters

    • value: number

    Returns void

  • get y(): number
  • The current value of the y component.

    Returns number

  • set y(value: number): void
  • Parameters

    • value: number

    Returns void

  • get z(): number
  • The current value of the z component.

    Returns number

  • set z(value: number): void
  • Parameters

    • value: number

    Returns void

Methods

  • Trigger the specified callback function once this euler changes

    Parameters

    • callback: () => void

    Returns this

  • Returns void

  • Returns Generator<string | number, void, unknown>

  • Return a new Euler with the same parameters as this one.

    Returns AcGeEuler

    Return a new Euler with the same parameters as this one.

  • Copy value of euler to this euler.

    Parameters

    • euler: AcGeEuler

      Input the eurler copied from

    Returns this

    Return this euler

  • Check for strict equality of this euler and euler.

    Parameters

    Returns boolean

    Return true if the specified euler and this euler represent the same rotation.

  • Set this euler from the specified array.

    Parameters

    • array: (string | number)[]

      Input an array of length 3 or 4. The optional 4th argument corresponds to the order.

      • Assign this euler's x angle to array[0].
      • Assign this euler's y angle to array[1].
      • Assign this euler's z angle to array[2].
      • Optionally assign this euler's order to array[3].

    Returns this

  • 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

      Input the new order that the rotations are applied.

    Returns this

    Return this euler

  • Set the angles of this euler transform and optionally the order.

    Parameters

    • x: number

      (optional) the angle of the x axis in radians. Default is 0.

    • y: number

      (optional) the angle of the y axis in radians. Default is 0.

    • z: number

      (optional) the angle of the z axis in radians. Default is 0.

    • Optionalorder: string

      (optional) a string representing the order that the rotations are applied, defaults to 'XYZ' (must be upper case).

    Returns this

    Return this euler

  • Set this urler from the specified quaternion.

    Parameters

    • q: AcGeQuaternion

      Input a normalized quaternion.

    • order: string

      (optional) a string representing the order that the rotations are applied. Sets the angles of this euler transform from a pure rotation matrix based on the orientation specified by order.

    • Optionalupdate: boolean

      Input one flag to indicate whether to trigger change callback function

    Returns this

    Return this euler

  • Set this euler by exatracting rotation information from the specified matrix.

    Parameters

    • m: AcGeMatrix3d

      Input a Matrix4 of which the upper 3x3 of matrix is a pure rotation matrix (i.e. unscaled).

    • Optionalorder: string

      (optional) a string representing the order that the rotations are applied. Sets the angles of this euler transform from a pure rotation matrix based on the orientation specified by order.

    • Optionalupdate: boolean

      Input one flag to indicate whether to trigger change callback function

    Returns this

    Return this euler

  • Set the x, y and z, and optionally update the order.

    Parameters

    • v: AcGeVector3d

      Input one 3d vector

    • Optionalorder: string

      Input a optional string representing the order that the rotations are applied.

    Returns this

    Return this euler

  • Return an array of the form [x, y, z, order ].

    Parameters

    • Optionalarray: (string | number)[]

      Input an optional array to store the euler in.

    • Optionaloffset: number

      Input an optional offset in the array.

    Returns (string | number)[]

    Return an array of the form [x, y, z, order].