Skip to content
This repository has been archived by the owner on Oct 22, 2024. It is now read-only.

VRageMath.BoundingBox2

Morten Aune Lyrstad edited this page Apr 16, 2022 · 52 revisions

IndexNamespace Index

BoundingBox2 Struct

public struct BoundingBox2: IEquatable<BoundingBox2>

Defines an axis-aligned box-shaped 3D volume.

Namespace: VRageMath
Assembly: VRage.Math.dll

Implements:

Fields

Vector2 Max

The maximum point the BoundingBox2 contains.

Vector2 Min

The minimum point the BoundingBox2 contains.

Properties

Vector2 Center { get; }

Calculates center

Vector2 Extents { get; }

Vector2 HalfExtents { get; }

float Height { get; }

Vector2 Size { get; }

Size

float Width { get; }

Constructors

BoundingBox2(Vector2, Vector2)

Methods

static BoundingBox2 CreateFromHalfExtent(Vector2, float)

static BoundingBox2 CreateFromHalfExtent(Vector2, Vector2)

static BoundingBox2 CreateFromPoints(IEnumerable<Vector2>)

Creates the smallest BoundingBox2 that will contain a group of points.

static BoundingBox2 CreateInvalid()

static BoundingBox2 CreateMerged(BoundingBox2, BoundingBox2)

Creates the smallest BoundingBox2 that contains the two specified BoundingBox2 instances.

static void CreateMerged(ref BoundingBox2, ref BoundingBox2, out BoundingBox2)

Creates the smallest BoundingBox2 that contains the two specified BoundingBox2 instances.

float Area()

ContainmentType Contains(BoundingBox2)

Tests whether the BoundingBox2 contains another BoundingBox2.

void Contains(ref BoundingBox2, out ContainmentType)

Tests whether the BoundingBox2 contains a BoundingBox2.

ContainmentType Contains(Vector2)

Tests whether the BoundingBox2 contains a point.

void Contains(ref Vector2, out ContainmentType)

Tests whether the BoundingBox2 contains a point.

float Distance(Vector2)

bool Equals(BoundingBox2)

Determines whether two instances of BoundingBox2 are equal.

bool Equals(object)

Determines whether two instances of BoundingBox2 are equal.

Vector2&#91] GetCorners()

Gets an array of points that make up the corners of the BoundingBox2.

void GetCorners(Vector2&#91])

Gets the array of points that make up the corners of the BoundingBox2.

void GetCornersUnsafe(*Vector2)

int GetHashCode()

Gets the hash code for this instance.

BoundingBox2 GetIncluded(Vector2)

BoundingBox2 Include(ref Vector2)

return expanded aabb (abb include point)

BoundingBox2 Include(Vector2)

BoundingBox2 Include(Vector2, Vector2, Vector2)

BoundingBox2 Include(ref Vector2, ref Vector2, ref Vector2)

BoundingBox2 Include(ref BoundingBox2)

return expanded aabb (abb include point)

BoundingBox2 Include(BoundingBox2)

void Inflate(float)

void InflateToMinimum(Vector2)

BoundingBox2 Intersect(BoundingBox2)

Returns bounding box which is intersection of this and box Result is invalid box when there's no intersection (Min > Max)

bool Intersects(BoundingBox2)

Checks whether the current BoundingBox2 intersects another BoundingBox2.

bool Intersects(ref BoundingBox2)

void Intersects(ref BoundingBox2, out bool)

Checks whether the current BoundingBox2 intersects another BoundingBox2.

float Perimeter()

void Scale(Vector2)

string ToString()

Returns a String that represents the current BoundingBox2.

BoundingBox2 Translate(Vector2)

Translate

Clone this wiki locally