clamped(to:)
Returns the entity with coordinates clamped to the specified rectangle.
Declaration
func clamped(to rect: Self.Rect) -> SelfParameters
- rect:
The rectangle that defines the clamp volume.
Discussion
Returns An entity that’s clamped to the specified rectangle.