Contents

CGRectIntersectsRect(_:_:)

Returns whether two rectangles intersect.

Declaration

func CGRectIntersectsRect(_ rect1: CGRect, _ rect2: CGRect) -> Bool

Parameters

  • rect1:

    The first rectangle to examine.

  • rect2:

    The second rectangle to examine.

Return Value

true if the two specified rectangles intersect; otherwise, false. The first rectangle intersects the second if the intersection of the rectangles is not equal to the null rectangle.

See Also

Comparing Values