• Calculates whether or not r2 is completely enclosed by r1.

    Parameters

    • r1: BoundingBox

      First rectangle

    • r2: BoundingBox

      Second rectangle

    • Optional allowSharedEdges: boolean

      If true, the concept of enclosure allows for one or more edges to be shared by the two rectangles.

    Returns boolean

    True if r1 encloses r2, false otherwise.