math docs
    Preparing search index...

    Function signedAngle

    • Get the signed angle from a to b, in the range (-PI, PI].

      Positive is counter-clockwise. Returns 0 if either vector is zero length.

      Unlike angle, this distinguishes the two directions of rotation, which is what joint limits and turn directions need.

      Parameters

      • a: readonly [number, number]

        the first operand

      • b: readonly [number, number]

        the second operand

      Returns number

      the signed angle in radians