open_iA 2025.6
Loading...
Searching...
No Matches
iAAABB Class Reference

An axis-aligned bounding box. More...

#include <iAAABB.h>

Public Member Functions

 iAAABB ()
 construct an "empty" bounding box, ready to be adjusted to new points via addPointToBox All 3 maximum coordinates are set to the minimum possible double value, all 3 minimum coordinates are set to the maximum possible double value.
 
 iAAABB (double const b[6])
 construct bounding box from 6 double values (xmin, xmax, ymin, ymax, zmin, zmax)
 
 iAAABB (double xmin, double xmax, double ymin, double ymax, double zmin, double zmax)
 construct bounding box from 6 double values
 
void addPointToBox (iAVec3d const &pt)
 add a point that should fit into the bounding box; if the current box does not contain this point, it is enlarged
 
bool contains (iAVec3d const &pt) const
 return true if the given point is contained within the bounding box
 
bool intersects (iAAABB const &other) const
 return true if the given other bounding box has intersecting space with this
 
iAVec3d const & maxCorner () const
 Retrieve the maximum of each of the 3 coordinates as point vector.
 
void merge (iAAABB const &other)
 merge another bounding box to this one, enlarging it if necessary
 
iAVec3d const & minCorner () const
 Retrieve the minimum of each of the 3 coordinates as point vector.
 

Detailed Description

An axis-aligned bounding box.

Provides convenience functions for creating a bounding box (adding a single point, merging boxes), as well as for testing containment/intersection.

Constructor & Destructor Documentation

◆ iAAABB() [1/3]

iAAABB::iAAABB ( )

construct an "empty" bounding box, ready to be adjusted to new points via addPointToBox All 3 maximum coordinates are set to the minimum possible double value, all 3 minimum coordinates are set to the maximum possible double value.

◆ iAAABB() [2/3]

iAAABB::iAAABB ( double const b[6])
explicit

construct bounding box from 6 double values (xmin, xmax, ymin, ymax, zmin, zmax)

◆ iAAABB() [3/3]

iAAABB::iAAABB ( double xmin,
double xmax,
double ymin,
double ymax,
double zmin,
double zmax )
explicit

construct bounding box from 6 double values

Member Function Documentation

◆ addPointToBox()

void iAAABB::addPointToBox ( iAVec3d const & pt)

add a point that should fit into the bounding box; if the current box does not contain this point, it is enlarged

◆ contains()

bool iAAABB::contains ( iAVec3d const & pt) const

return true if the given point is contained within the bounding box

◆ intersects()

bool iAAABB::intersects ( iAAABB const & other) const

return true if the given other bounding box has intersecting space with this

◆ maxCorner()

iAVec3d const & iAAABB::maxCorner ( ) const

Retrieve the maximum of each of the 3 coordinates as point vector.

◆ merge()

void iAAABB::merge ( iAAABB const & other)

merge another bounding box to this one, enlarging it if necessary

◆ minCorner()

iAVec3d const & iAAABB::minCorner ( ) const

Retrieve the minimum of each of the 3 coordinates as point vector.


The documentation for this class was generated from the following files: