math docs
    Preparing search index...

    Variable rotationToConst

    rotationTo: (
        out: quat.Quat,
        a: readonly [number, number, number],
        b: readonly [number, number, number],
    ) => quat.Quat = ...

    Sets a quaternion to represent the shortest rotation from one vector to another.

    Both vectors are assumed to be unit length.

    Type Declaration

      • (
            out: quat.Quat,
            a: readonly [number, number, number],
            b: readonly [number, number, number],
        ): quat.Quat
      • Parameters

        • out: quat.Quat

          the receiving quaternion.

        • a: readonly [number, number, number]

          the initial vector

        • b: readonly [number, number, number]

          the destination vector

        Returns quat.Quat

        out