libgenua
Basic Geometry, Numerical Algorithms and Interfaces
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Groups Pages
Public Member Functions | List of all members
Dop3d3< Type > Class Template Reference

Detailed Description

template<class Type>
class Dop3d3< Type >

Axis-aligned 3D bounding box expressed as a k-DOP.

Replaces BndBox.

See Also
DopBase

#include <kdop.h>

Inheritance diagram for Dop3d3< Type >:
[legend]
Collaboration diagram for Dop3d3< Type >:
[legend]

Public Member Functions

 Dop3d3 ()
 empty
 
 Dop3d3 (const Type pmin[], const Type pmax[])
 initialize using extreme points
 
Type pointDistance (const Type p[]) const
 axis-aligned, hence coordinates are coefficients
 
Type minDistance (const Dop3d3< Type > &a) const
 minmum distance from another box
 
- Public Member Functions inherited from DopBase< Type, 3 >
 DopBase ()
 initialize DOP
 
 DopBase (const Type pmin[], const Type pmax[])
 initialize DOP
 
force_inline const FloatType * pointer () const
 pointer to first coefficient (stored serially)
 
force_inline FloatType * pointer ()
 pointer to first coefficient (stored serially)
 
force_inline Type minCoef (int k) const
 minimum coefficient for plane k
 
force_inline Type maxCoef (int k) const
 maximum coefficient for plane k
 
void setCoef (const Type fmin[], const Type fmax[])
 set coefficients explicitely
 
force_inline bool inside (const Type p[]) const
 test whether point p is inside or on box boundary
 
force_inline Type minCoefDistance (const Type c[])
 (under-) estimate the distance of c(p) from bounding volume
 
force_inline Type eclDistance (const Type p[], Type ds[]) const
 determine euclidean distance of point from box, return squared norm
 
force_inline Type eclDistance (const Type c[]) const
 determine euclidean distance of point from box, return squared norm
 
force_inline void adapt (uint k, Type c)
 adapt min and max of axis k to enclose c
 
force_inline void adapt (const Type c[])
 adapt min and max for all axes
 
int longestAxis () const
 determine index of longest axis
 
force_inline void reset ()
 make box undefined
 
force_inline void expand (Type dx)
 expand box by a fixed amount in each direction
 
force_inline void center (Type ctr[]) const
 center coordinates
 
force_inline Type sqsize () const
 compute a box size (sum of squares of plane distances)
 
force_inline void invalidate ()
 set all coefficients to huge value
 
force_inline bool intersects (const DopBase< Type, N > &b) const
 test for intersection with another DOP
 
force_inline void enclose (const DopBase< Type, N > &b)
 enclose another DOP
 
bool operator== (const DopBase< Type, N > &b)
 equality
 

Additional Inherited Members

- Static Public Member Functions inherited from DopBase< Type, 3 >
static int naxes ()
 number of axes
 
static force_inline void fit (const Type c[], Type fmin[], Type fmax[])
 Helper method to be used/specialized by child classes. More...
 
- Protected Attributes inherited from DopBase< Type, 3 >
Type coef [2 *N]
 min/max coefficients for each plane
 

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