Description

A quaternion, used to represent rotation.

Constructors

  • Parameters

    • w: number
    • x: number
    • y: number
    • z: number

    Returns quat

    Description

    Creates a new quat.

Properties

w: number

Description

w component of the quat.

x: number

Description

x component of the quat.

y: number

Description

y component of the quat.

z: number

Description

z component of the quat.

Methods

  • Parameters

    Returns number

    Description

    Returns the dot product of the two quats.

  • Parameters

    Returns boolean

    Description

    Returns whether this quat and b are equal.

  • Returns number

    Description

    Returns the rotation angle of the quat.

  • Returns vec3

    Description

    Returns the rotation axis of the quat.

  • Returns quat

    Description

    Returns an inverted version of the quat.

  • Parameters

    Returns quat

    Description

    Returns the product of this quat and b.

  • Parameters

    Returns vec3

    Description

    Returns the result of rotating direction vector vec3 by this quat.

  • Returns void

    Description

    Normalizes the quat.

  • Returns vec3

    Description

    Returns an euler angle representation of the quat, in radians.

  • Returns string

    Description

    Returns a string representation of the quat.

Generated using TypeDoc