CGPoint

extension CGPoint

Important

This is a Public Preview API. It may be changed or removed at any time.
  • Calculates angle between self and the point using 0.0 as an anchor point.

    Declaration

    Swift

    public func angle(to point: CGPoint) -> CGFloat
  • Rotates point by given angle.

    Declaration

    Swift

    public func rotate(_ byDegrees: CGFloat) -> CGPoint