Synced
- Represents an axis-aligned rectangle with float coordinates. Coordinates assume Y-axis points upwards (top smaller than bottom).
Required contracts
Section titled “Required contracts”API: engine
Implements: System.IEquatable<Inno.Core.Mathematics.Rect>
Inherits: System.ValueType
Project: Inno.Core.Mathematics
Declaration
Section titled “Declaration”public struct Inno.Core.Mathematics.Rect : System.IEquatable<Inno.Core.Mathematics.Rect>Members
Section titled “Members”| Kind | Element | Description |
|---|---|---|
| Constructors | Rect.Constructor | Creates a validated rect instance. |
| Fields | Rect.height | The horizontal or first component. |
| Fields | Rect.width | The horizontal or first component. |
| Fields | Rect.x | The horizontal or first component. |
| Fields | Rect.y | The horizontal or first component. |
| Methods | Rect.Contains(Inno.Core.Mathematics.Rect) | Checks if this rectangle fully contains another rectangle. |
| Methods | Rect.Contains(Inno.Core.Mathematics.Vector2) | Determines whether current state contains the requested value value. |
| Methods | Rect.Contains(System.Single,System.Single) | Checks if this rectangle contains a point. |
| Methods | Rect.Equals(Inno.Core.Mathematics.Rect) | Determines whether this value and the supplied value represent the same logical state. |
| Methods | Rect.Equals(System.Object) | Determines whether this value and the supplied value represent the same logical state. |
| Methods | Rect.FromMinMax | Creates a rectangle from minimum and maximum boundaries; point containment excludes the maximum boundary. |
| Methods | Rect.GetHashCode | Computes a hash code consistent with the implemented equality contract. |
| Methods | Rect.op_Addition | Adds the supplied values component by component. |
| Methods | Rect.op_Equality | Determines whether the supplied values are equal under the type’s equality tolerance. |
| Methods | Rect.op_Implicit(Inno.Core.Mathematics.Rect)~System.Numerics.Vector4 | Converts the supplied value to T:System.Numerics.Vector4. |
| Methods | Rect.op_Implicit(System.Numerics.Vector4)~Inno.Core.Mathematics.Rect | Converts the supplied value to T:Inno.Core.Mathematics.Rect. |
| Methods | Rect.op_Inequality | Determines whether the supplied values differ under the type’s equality tolerance. |
| Methods | Rect.op_Subtraction | Subtracts or negates the supplied value component by component. |
| Methods | Rect.Overlaps | Checks if this rectangle overlaps another rectangle. |
| Methods | Rect.ToString | Formats this value as a human-readable component list. |
| Methods | Rect.TryIntersect | Attempts to intersect without changing state when the operation cannot complete. |
| Methods | Rect.Union | Returns the smallest axis-aligned rectangle containing both supplied rectangles. |
| Properties | Rect.bottom | Gets the scalar measurement or identity associated with the current state. |
| Properties | Rect.center | Gets the midpoint derived from the rectangle bounds. |
| Properties | Rect.left | Gets the scalar measurement or identity associated with the current state. |
| Properties | Rect.max | Gets the maximum corner of this axis-aligned rectangle. |
| Properties | Rect.min | Gets the minimum corner of this axis-aligned rectangle. |
| Properties | Rect.right | Gets the scalar measurement or identity associated with the current state. |
| Properties | Rect.size | Gets the width and height derived from the rectangle bounds. |
| Properties | Rect.top | Gets the scalar measurement or identity associated with the current state. |