CFx SDK Documentation  2022 SP0
Public Types | Public Member Functions | Static Public Attributes | Protected Attributes | List of all members
OdGeExtents2d Class Reference

#include <GeExtents2d.h>

Public Types

enum  IntersectionStatus {
  kIntersectUnknown , kIntersectNot , kIntersectOpIn , kIntersectOpOut ,
  kIntersectOk
}
 

Public Member Functions

 OdGeExtents2d ()
 
 OdGeExtents2d (const OdGePoint2d &min, const OdGePoint2d &max)
 
const OdGePoint2dminPoint () const
 
const OdGePoint2dmaxPoint () const
 
void set (const OdGePoint2d &min, const OdGePoint2d &max)
 
void comparingSet (const OdGePoint2d &pt1, const OdGePoint2d &pt2)
 
void addPoint (const OdGePoint2d &point)
 
void addExt (const OdGeExtents2d &extents)
 
bool isValidExtents () const
 
void expandBy (const OdGeVector2d &vect)
 
void transformBy (const OdGeMatrix2d &xfm)
 
bool contains (const OdGePoint2d &point) const
 
bool contains (const OdGeExtents2d &extents) const
 
bool isDisjoint (const OdGeExtents2d &extents) const
 
IntersectionStatus intersectWith (const OdGeExtents2d &extents, OdGeExtents2d *pResult=0) const
 
OdGePoint2d center () const
 
bool isEqualTo (const OdGeExtents2d &extents, const OdGeTol &tol=OdGeContext::gTol) const
 
bool operator== (const OdGeExtents2d &extents) const
 
bool operator!= (const OdGeExtents2d &extents) const
 

Static Public Attributes

static GE_STATIC_EXPORT const OdGeExtents2d kInvalid
 

Protected Attributes

OdGePoint2d m_min
 
OdGePoint2d m_max
 

Detailed Description

This class represents 2D bounding boxes as minimum and maximum 2d points.

Corresponding C++ library: TD_Ge

<group OdGe_Classes>

Definition at line 42 of file GeExtents2d.h.

Member Enumeration Documentation

◆ IntersectionStatus

Enumerator
kIntersectUnknown 
kIntersectNot 
kIntersectOpIn 
kIntersectOpOut 
kIntersectOk 

Definition at line 220 of file GeExtents2d.h.

Constructor & Destructor Documentation

◆ OdGeExtents2d() [1/2]

OdGeExtents2d::OdGeExtents2d ( )
inline
Parameters
min[in] Minimum point.
max[in] Maximum point.

Definition at line 49 of file GeExtents2d.h.

◆ OdGeExtents2d() [2/2]

OdGeExtents2d::OdGeExtents2d ( const OdGePoint2d min,
const OdGePoint2d max 
)
inline

Definition at line 54 of file GeExtents2d.h.

Member Function Documentation

◆ addExt()

void OdGeExtents2d::addExt ( const OdGeExtents2d extents)
inline

Updates the extents of this Extents object with the specified Extents object.

Parameters
extents[in] Any 2D Extents object.

Definition at line 128 of file GeExtents2d.h.

◆ addPoint()

void OdGeExtents2d::addPoint ( const OdGePoint2d point)
inline

Updates the extents of this Extents object with the specified point.

Parameters
point[in] Any 2D point.

Definition at line 107 of file GeExtents2d.h.

◆ center()

OdGePoint2d OdGeExtents2d::center ( ) const
inline

Definition at line 251 of file GeExtents2d.h.

◆ comparingSet()

void OdGeExtents2d::comparingSet ( const OdGePoint2d pt1,
const OdGePoint2d pt2 
)
inline

Sets the minimum and maximum points for this Extents object to that of the box defined by pt1 and pt2.

Parameters
pt1[in] First point.
pt2[in] Second point.
Remarks
pt1 and pt2 need only define a box. They need not be the minimum and maximum points of the box.

Definition at line 274 of file GeExtents2d.h.

◆ contains() [1/2]

bool OdGeExtents2d::contains ( const OdGeExtents2d extents) const
inline

Definition at line 199 of file GeExtents2d.h.

◆ contains() [2/2]

bool OdGeExtents2d::contains ( const OdGePoint2d point) const
inline

Returns true if and only if this Extents object contains the specified object.

Parameters
point[in] Any 2D point.
extents[in] Any 2D Extents object.

Definition at line 192 of file GeExtents2d.h.

◆ expandBy()

void OdGeExtents2d::expandBy ( const OdGeVector2d vect)
inline

Updates the extents of this Extents object by the specified vector.

Parameters
vect[in] Any 2D vector.

Definition at line 154 of file GeExtents2d.h.

◆ intersectWith()

IntersectionStatus OdGeExtents2d::intersectWith ( const OdGeExtents2d extents,
OdGeExtents2d pResult = 0 
) const

Determines the intersection of the specified Extents object with this one, and returns the resulting intersection box.

Parameters
extents[in] Any 2D Extents object.
pResult[out] Receives extents of the intersection.
Remarks
pResult object should be created by the caller. Possible return values are as follows.

@untitled table kIntersectUnknown Either or both Extents objects are invalid kIntersectNot The Extents objects are NOT intersecting kIntersectOpIn The specified Extents object is completely within this one kIntersectOpOut This Extents object is completely within the specified one kIntersectOk The Extents objectes are intersecting, and a result is returned

◆ isDisjoint()

bool OdGeExtents2d::isDisjoint ( const OdGeExtents2d extents) const
inline

Returns true if and only if specified Extents object does not intersect this one.

Parameters
extents[in] Any 2D Extents object.

Definition at line 213 of file GeExtents2d.h.

◆ isEqualTo()

bool OdGeExtents2d::isEqualTo ( const OdGeExtents2d extents,
const OdGeTol tol = OdGeContext::gTol 
) const
inline

Definition at line 298 of file GeExtents2d.h.

◆ isValidExtents()

bool OdGeExtents2d::isValidExtents ( ) const
inline

Returns true if and only if this Extents object contains valid extents.

Remarks
Extents are valid if and only if each member of the minimum extents is less than or equal to the corresponding member of maximum extents.

Definition at line 145 of file GeExtents2d.h.

◆ maxPoint()

const OdGePoint2d& OdGeExtents2d::maxPoint ( ) const
inline

Returns the maximum point of this Extents object.

Definition at line 73 of file GeExtents2d.h.

◆ minPoint()

const OdGePoint2d& OdGeExtents2d::minPoint ( ) const
inline

Returns the minimum point of this Extents object.

Definition at line 67 of file GeExtents2d.h.

◆ operator!=()

bool OdGeExtents2d::operator!= ( const OdGeExtents2d extents) const
inline

Definition at line 262 of file GeExtents2d.h.

◆ operator==()

bool OdGeExtents2d::operator== ( const OdGeExtents2d extents) const
inline

Definition at line 258 of file GeExtents2d.h.

◆ set()

void OdGeExtents2d::set ( const OdGePoint2d min,
const OdGePoint2d max 
)
inline

Sets the minimum and maximum points for this Extents object.

Parameters
min[in] Minimum point.
max[in] Maximum point.

Definition at line 82 of file GeExtents2d.h.

◆ transformBy()

void OdGeExtents2d::transformBy ( const OdGeMatrix2d xfm)
inline

Applies the 2D transformation matrix to the extents.

Parameters
xfm[in] 2D transformation matrix.

Definition at line 172 of file GeExtents2d.h.

Member Data Documentation

◆ kInvalid

GE_STATIC_EXPORT const OdGeExtents2d OdGeExtents2d::kInvalid
static

The invalid extents.

Definition at line 62 of file GeExtents2d.h.

◆ m_max

OdGePoint2d OdGeExtents2d::m_max
protected

Definition at line 269 of file GeExtents2d.h.

◆ m_min

OdGePoint2d OdGeExtents2d::m_min
protected

Definition at line 268 of file GeExtents2d.h.


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