Dungeon Architect  17.0.0
SharpNav.Geometry.BBox3 Struct Reference

A 3d axis-aligned bounding box. More...

Inheritance diagram for SharpNav.Geometry.BBox3:

Public Member Functions

 BBox3 (Vector3 min, Vector3 max)
 Initializes a new instance of the BBox3 struct. More...
 
 BBox3 (float minX, float minY, float minZ, float maxX, float maxY, float maxZ)
 Initializes a new instance of the BBox3 struct. More...
 
bool Equals (BBox3 other)
 Compares this instance with another bounding box for equality. More...
 
override bool Equals (object obj)
 Compares this instance with another object for equality. More...
 
override int GetHashCode ()
 Generates a unique hashcode for this bouding box instance. More...
 
override string ToString ()
 Returns a string containing the important information for this instance of BBox3. More...
 

Static Public Member Functions

static bool Overlapping (ref BBox3 a, ref BBox3 b)
 Checks whether two boudning boxes are intersecting. More...
 
static bool IsValid (ref BBox3 b)
 Determines whether a bounding box is valid. Validity consists of having no NaN values and the Min vector to be less than the Max vector on all axes. More...
 
static bool operator== (BBox3 left, BBox3 right)
 Compares two bounding boxes for equality. More...
 
static bool operator!= (BBox3 left, BBox3 right)
 Compares two bounding boxes for inequality. More...
 

Public Attributes

Vector3 Min
 The minimum bounds. More...
 
Vector3 Max
 The maximum bounds. More...
 

Properties

Vector3 Center [get]
 Gets the center of the box. More...
 
Vector3 Size [get]
 Gets the size of the box. More...
 

Detailed Description

A 3d axis-aligned bounding box.

Definition at line 20 of file BBox3.cs.

Constructor & Destructor Documentation

◆ BBox3() [1/2]

SharpNav.Geometry.BBox3.BBox3 ( Vector3  min,
Vector3  max 
)

Initializes a new instance of the BBox3 struct.

Parameters
minThe minimum bounds.
maxThe maximum bounds.

Definition at line 37 of file BBox3.cs.

◆ BBox3() [2/2]

SharpNav.Geometry.BBox3.BBox3 ( float  minX,
float  minY,
float  minZ,
float  maxX,
float  maxY,
float  maxZ 
)

Initializes a new instance of the BBox3 struct.

Parameters
minXThe minimum on the X axis.
minYThe minimum on the Y axis.
minZThe minimum on the Z axis.
maxXThe maximum on the X axis.
maxYThe maximum on the Y axis.
maxZThe maximum on the Z axis.

Definition at line 52 of file BBox3.cs.

Member Function Documentation

◆ Equals() [1/2]

bool SharpNav.Geometry.BBox3.Equals ( BBox3  other)

Compares this instance with another bounding box for equality.

Parameters
otherAnother bounding box.
Returns
A value indicating the equality of the two boxes.

Definition at line 151 of file BBox3.cs.

◆ Equals() [2/2]

override bool SharpNav.Geometry.BBox3.Equals ( object  obj)

Compares this instance with another object for equality.

Parameters
objAn object.
Returns
A value indicating equality between the two objects.

Definition at line 161 of file BBox3.cs.

◆ GetHashCode()

override int SharpNav.Geometry.BBox3.GetHashCode ( )

Generates a unique hashcode for this bouding box instance.

Returns
A hash code.

Definition at line 173 of file BBox3.cs.

◆ IsValid()

static bool SharpNav.Geometry.BBox3.IsValid ( ref BBox3  b)
static

Determines whether a bounding box is valid. Validity consists of having no NaN values and the Min vector to be less than the Max vector on all axes.

Parameters
bThe bounding box to validate.
Returns
A value indicating whether the bounding box is valid.

Definition at line 104 of file BBox3.cs.

◆ operator!=()

static bool SharpNav.Geometry.BBox3.operator!= ( BBox3  left,
BBox3  right 
)
static

Compares two bounding boxes for inequality.

Parameters
leftThe first bounding box.
rightThe second bounding box.
Returns
A value indicating the inequality of the two boxes.

Definition at line 141 of file BBox3.cs.

◆ operator==()

static bool SharpNav.Geometry.BBox3.operator== ( BBox3  left,
BBox3  right 
)
static

Compares two bounding boxes for equality.

Parameters
leftThe first bounding box.
rightThe second bounding box.
Returns
A value indicating the equality of the two boxes.

Definition at line 130 of file BBox3.cs.

◆ Overlapping()

static bool SharpNav.Geometry.BBox3.Overlapping ( ref BBox3  a,
ref BBox3  b 
)
static

Checks whether two boudning boxes are intersecting.

Parameters
aThe first bounding box.
bThe second bounding box.
Returns
A value indicating whether the two bounding boxes are overlapping.

Definition at line 91 of file BBox3.cs.

◆ ToString()

override string SharpNav.Geometry.BBox3.ToString ( )

Returns a string containing the important information for this instance of BBox3.

Returns
A human-readable string representation of this instance.

Definition at line 183 of file BBox3.cs.

Member Data Documentation

◆ Max

Vector3 SharpNav.Geometry.BBox3.Max

The maximum bounds.

Definition at line 30 of file BBox3.cs.

◆ Min

Vector3 SharpNav.Geometry.BBox3.Min

The minimum bounds.

Definition at line 25 of file BBox3.cs.

Property Documentation

◆ Center

Vector3 SharpNav.Geometry.BBox3.Center
get

Gets the center of the box.

Definition at line 66 of file BBox3.cs.

◆ Size

Vector3 SharpNav.Geometry.BBox3.Size
get

Gets the size of the box.

Definition at line 77 of file BBox3.cs.


The documentation for this struct was generated from the following file: