math docs
    Preparing search index...

    Variable fromVec2Const

    fromVec2: (out: polar.Polar, v: readonly [number, number]) => polar.Polar = setFromVec2

    Type Declaration

      • (out: polar.Polar, v: readonly [number, number]): polar.Polar
      • Sets a Polar from Cartesian Vec2 coordinates: r = sqrt(x^2 + y^2) theta = atan2(y, x)

        Parameters

        • out: polar.Polar

          the receiving Polar

        • v: readonly [number, number]

          the source Vec2

        Returns polar.Polar

        out

    setFromVec2