Struct BoundingBox2D

BoundingBox2D structure

The axis-aligned bounding box for Vector2

public struct BoundingBox2D

Constructors

NameDescription
BoundingBox2D(Vector2, Vector2)Initialize a finite bounding box with given minimum and maximum corner

Properties

NameDescription
Extent { get; }Gets the extent of the bounding box.
Maximum { get; }The maximum corner of the bounding box
Minimum { get; }The minimum corner of the bounding box

Methods

NameDescription
Merge(BoundingBox2D)Merges the new box into the current bounding box.
Merge(Vector2)Merges the new box into the current bounding box.
override ToString()Gets the string representation of the bounding box.

Fields

NameDescription
static readonly InfiniteThe infinite bounding box
static readonly NullThe null bounding box

See Also