Rectangle.Contains Method
Definition
Namespace: Brine2D.Core
| Overloads | |
|---|---|
| Contains\(Rectangle\) | Checks if this rectangle contains another rectangle entirely. |
| Contains\(float, float\) | Checks if this rectangle contains a point. |
| Contains\(Vector2\) | Checks if this rectangle contains a point. |
Rectangle.Contains\(Rectangle\) Method
Checks if this rectangle contains another rectangle entirely.
Parameters
other Rectangle
Returns
Rectangle.Contains\(float, float\) Method
Checks if this rectangle contains a point.
Parameters
The X coordinate of the point.
The Y coordinate of the point.
Returns
Remarks
Points exactly on the right or bottom edges are NOT considered inside. This follows standard rect collision rules to avoid edge case issues.
Rectangle.Contains\(Vector2\) Method
Checks if this rectangle contains a point.
Parameters
point System.Numerics.Vector2
Returns
Remarks
Points exactly on the right or bottom edges are NOT considered inside. This follows standard rect collision rules to avoid edge case issues.