Public Member Functions | Public Attributes

ANNorthRect Class Reference

#include <ANNx.h>

List of all members.

Public Member Functions

 ANNorthRect (int dd, ANNcoord l=0, ANNcoord h=0)
 ANNorthRect (int dd, const ANNorthRect &r)
 ANNorthRect (int dd, ANNpoint l, ANNpoint h)
 ~ANNorthRect ()
ANNbool inside (int dim, ANNpoint p)

Public Attributes

ANNpoint lo
ANNpoint hi

Detailed Description

Definition at line 92 of file ANNx.h.


Constructor & Destructor Documentation

ANNorthRect::ANNorthRect ( int  dd,
ANNcoord  l = 0,
ANNcoord  h = 0 
) [inline]

Definition at line 97 of file ANNx.h.

References annAllocPt(), hi, and lo.

        {  lo = annAllocPt(dd, l);  hi = annAllocPt(dd, h); }
ANNorthRect::ANNorthRect ( int  dd,
const ANNorthRect r 
) [inline]

Definition at line 103 of file ANNx.h.

References annCopyPt(), hi, and lo.

        {  lo = annCopyPt(dd, r.lo);  hi = annCopyPt(dd, r.hi);  }
ANNorthRect::ANNorthRect ( int  dd,
ANNpoint  l,
ANNpoint  h 
) [inline]

Definition at line 108 of file ANNx.h.

References annCopyPt(), hi, and lo.

        {  lo = annCopyPt(dd, l);  hi = annCopyPt(dd, h);  }
ANNorthRect::~ANNorthRect (  ) [inline]

Definition at line 114 of file ANNx.h.

References annDeallocPt(), hi, and lo.


Member Function Documentation

ANNbool ANNorthRect::inside ( int  dim,
ANNpoint  p 
)

Definition at line 155 of file ANN.cpp.

References ANNfalse, and ANNtrue.

Referenced by annBoxSplit().

{
        for (int i = 0; i < dim; i++) {
                if (p[i] < lo[i] || p[i] > hi[i]) return ANNfalse;
        }
        return ANNtrue;
}

Member Data Documentation


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines