Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members

C2DHoledPolygon Class Reference

class which represents a polygon with holes. More...

#include <2DHoledPolygon.h>

Inheritance diagram for C2DHoledPolygon:

C2DHoledPolyBase C2DBase List of all members.

Public Member Functions

 C2DHoledPolygon (void)
 Constructor.
 C2DHoledPolygon (const C2DHoledPolygon &Other)
 Constructor with assignment.
 C2DHoledPolygon (const C2DHoledPolyBase &Other)
 Constructor with assignment.
 ~C2DHoledPolygon (void)
 Destructor.
void SetRim (const C2DPolygon &Polygon)
 Sets the rim to a copy of the polygon given.
void AddHole (const C2DPolygon &Polygon)
 Adds a copy of the polygon given.
void SetHole (const C2DPolygon &Polygon, unsigned short usIndex)
 Sets the holes to be a copy of the polygon given.
void SetRimDirect (C2DPolygon *Polygon)
 Sets the rim to be the polygon provided. Will delete on destruction.
void AddHoleDirect (C2DPolygon *Polygon)
 Adds the hole provided. Will delete on destruction.
void SetHoleDirect (C2DPolygon *Polygon, unsigned short usIndex)
 Sets the hole to be the polygon provided. Will delete on destruction. Deletes old one.
void RemoveHole (unsigned short usIndex)
 Removes the hole at the index given.
C2DPolygon * GetRim (void)
 Returns the rim.
const C2DPolygon * GetRim (void) const
 Returns the rim.
C2DPolygon * ExtractRim (void)
 Extracts the rim. Deletion of the rim needs to be managed elsewhere.
C2DPolygon * GetHole (unsigned short usIndex)
 Returns a pointer to the hole specified.
const C2DPolygon * GetHole (unsigned short usIndex) const
 Returns a pointer to the hole specified.
C2DPolygon * ExtractHole (unsigned short usIndex)
 Extracts the hole. Deletion of the hole needs to be managed elsewhere.
const C2DHoledPolygon & operator= (C2DHoledPolygon &Other)
 Assignement to another.
void Grow (double dFactor)
 Grows the polygon by the amount.
void Grow (double dFactor, const C2DPoint &Origin)
 Grows the polygon by the amount.
void RotateToRight (double dAng)
 Rotates to the right by the angle around the centroid.
void RotateToRight (double dAng, const C2DPoint &Origin)
 Rotates to the right by the angle around the centroid.
C2DPoint GetCentroid (void)
 Returns the centroid.
double GetArea () const
 Area.
bool Overlaps (const C2DHoledPolygon &Other) const
 True if this overlaps the other.
void GetOverlaps (const C2DHoledPolygon &Other, C2DHoledPolygonSet &HoledPolys, CGrid::eDegenerateHandling eDegen=CGrid::None) const
 Returns the overlaps between this and the other complex polygon.
void GetOverlaps (const C2DHoledPolygon &Other, C2DHoledPolyBaseSet &HoledPolys, CGrid::eDegenerateHandling eDegen=CGrid::None) const
 Returns the overlaps between this and the other complex polygon.
void GetNonOverlaps (const C2DHoledPolygon &Other, C2DHoledPolygonSet &HoledPolys, CGrid::eDegenerateHandling eDegen=CGrid::None) const
 Returns the difference between this and the other polygon.
void GetNonOverlaps (const C2DHoledPolygon &Other, C2DHoledPolyBaseSet &HoledPolys, CGrid::eDegenerateHandling eDegen=CGrid::None) const
 Returns the difference between this and the other polygon.
void GetUnion (const C2DHoledPolygon &Other, C2DHoledPolygonSet &HoledPolys, CGrid::eDegenerateHandling eDegen=CGrid::None) const
 Returns the union of this and the other.
void GetUnion (const C2DHoledPolygon &Other, C2DHoledPolyBaseSet &HoledPolys, CGrid::eDegenerateHandling eDegen=CGrid::None) const
 Returns the union of this and the other.

Detailed Description

class which represents a polygon with holes.

Class which represents a polygon with holes. Simply consists of a set of simple polygons (without holes) representing the rim and the hole.

---------------------------------------------------------------------------


Constructor & Destructor Documentation

C2DHoledPolygon::C2DHoledPolygon (  void   ) 
 

Constructor.

--------------------------------------------------------------------------
C2DHoledPolygon::C2DHoledPolygon

---------------------------------------------------------------------------

C2DHoledPolygon::C2DHoledPolygon (  const C2DHoledPolygon &  Other  ) 
 

Constructor with assignment.

--------------------------------------------------------------------------
C2DHoledPolygon::C2DHoledPolygon

---------------------------------------------------------------------------

C2DHoledPolygon::C2DHoledPolygon (  const C2DHoledPolyBase &  Other  ) 
 

Constructor with assignment.

--------------------------------------------------------------------------
C2DHoledPolygon::C2DHoledPolygon

---------------------------------------------------------------------------

C2DHoledPolygon::~C2DHoledPolygon (  void   ) 
 

Destructor.

--------------------------------------------------------------------------
C2DHoledPolygon::C2DHoledPolygon

---------------------------------------------------------------------------


Member Function Documentation

void C2DHoledPolygon::AddHole (  const C2DPolygon &  Polygon  ) 
 

Adds a copy of the polygon given.

--------------------------------------------------------------------------
C2DHoledPolygon::SetRim

---------------------------------------------------------------------------

void C2DHoledPolygon::AddHoleDirect (  C2DPolygon *  Polygon  ) 
 

Adds the hole provided. Will delete on destruction.

--------------------------------------------------------------------------
C2DHoledPolygon::AddHoleDirect

---------------------------------------------------------------------------

C2DPolygon * C2DHoledPolygon::ExtractHole (  unsigned short  usIndex  ) 
 

Extracts the hole. Deletion of the hole needs to be managed elsewhere.

--------------------------------------------------------------------------
C2DHoledPolygon::ExtractHole

---------------------------------------------------------------------------

C2DPolygon * C2DHoledPolygon::ExtractRim (  void   ) 
 

Extracts the rim. Deletion of the rim needs to be managed elsewhere.

--------------------------------------------------------------------------
C2DHoledPolygon::ExtractRim

---------------------------------------------------------------------------

Reimplemented from C2DHoledPolyBase.

double C2DHoledPolygon::GetArea (   )  const
 

Area.

--------------------------------------------------------------------------
C2DHoledPolygon::GetArea

---------------------------------------------------------------------------

C2DPoint C2DHoledPolygon::GetCentroid (  void   ) 
 

Returns the centroid.

--------------------------------------------------------------------------
C2DHoledPolygon::GetCentroid

---------------------------------------------------------------------------

const C2DPolygon * C2DHoledPolygon::GetHole (  unsigned short  usIndex  )  const
 

Returns a pointer to the hole specified.

--------------------------------------------------------------------------
C2DHoledPolygon::GetHole

---------------------------------------------------------------------------

C2DPolygon * C2DHoledPolygon::GetHole (  unsigned short  usIndex  ) 
 

Returns a pointer to the hole specified.

--------------------------------------------------------------------------
C2DHoledPolygon::GetHole

---------------------------------------------------------------------------

void C2DHoledPolygon::GetNonOverlaps (  const C2DHoledPolygon &  Other,
C2DHoledPolyBaseSet &  HoledPolys,
CGrid::eDegenerateHandling  eDegen = CGrid::None
)  const
 

Returns the difference between this and the other polygon.

--------------------------------------------------------------------------
C2DHoledPolygon::GetNonOverlaps

---------------------------------------------------------------------------

void C2DHoledPolygon::GetNonOverlaps (  const C2DHoledPolygon &  Other,
C2DHoledPolygonSet &  HoledPolys,
CGrid::eDegenerateHandling  eDegen = CGrid::None
)  const
 

Returns the difference between this and the other polygon.

--------------------------------------------------------------------------
C2DHoledPolygon::GetNonOverlaps

---------------------------------------------------------------------------

void C2DHoledPolygon::GetOverlaps (  const C2DHoledPolygon &  Other,
C2DHoledPolyBaseSet &  HoledPolys,
CGrid::eDegenerateHandling  eDegen = CGrid::None
)  const
 

Returns the overlaps between this and the other complex polygon.

--------------------------------------------------------------------------
C2DHoledPolygon::GetOverlaps

---------------------------------------------------------------------------

void C2DHoledPolygon::GetOverlaps (  const C2DHoledPolygon &  Other,
C2DHoledPolygonSet &  HoledPolys,
CGrid::eDegenerateHandling  eDegen = CGrid::None
)  const
 

Returns the overlaps between this and the other complex polygon.

--------------------------------------------------------------------------
C2DHoledPolygon::GetOverlaps

---------------------------------------------------------------------------

const C2DPolygon * C2DHoledPolygon::GetRim (  void   )  const
 

Returns the rim.

--------------------------------------------------------------------------
C2DHoledPolygon::GetRim

---------------------------------------------------------------------------

Reimplemented from C2DHoledPolyBase.

C2DPolygon * C2DHoledPolygon::GetRim (  void   ) 
 

Returns the rim.

--------------------------------------------------------------------------
C2DHoledPolygon::GetRim

---------------------------------------------------------------------------

Reimplemented from C2DHoledPolyBase.

void C2DHoledPolygon::GetUnion (  const C2DHoledPolygon &  Other,
C2DHoledPolyBaseSet &  HoledPolys,
CGrid::eDegenerateHandling  eDegen = CGrid::None
)  const
 

Returns the union of this and the other.

--------------------------------------------------------------------------
C2DHoledPolygon::GetUnion

---------------------------------------------------------------------------

void C2DHoledPolygon::GetUnion (  const C2DHoledPolygon &  Other,
C2DHoledPolygonSet &  HoledPolys,
CGrid::eDegenerateHandling  eDegen = CGrid::None
)  const
 

Returns the union of this and the other.

--------------------------------------------------------------------------
C2DHoledPolygon::GetUnion

---------------------------------------------------------------------------

void C2DHoledPolygon::Grow (  double  dFactor,
const C2DPoint &  Origin
)  [virtual]
 

Grows the polygon by the amount.

--------------------------------------------------------------------------
C2DHoledPolygon::Grow

---------------------------------------------------------------------------

Reimplemented from C2DHoledPolyBase.

void C2DHoledPolygon::Grow (  double  dFactor  ) 
 

Grows the polygon by the amount.

--------------------------------------------------------------------------
C2DHoledPolygon::Grow

---------------------------------------------------------------------------

const C2DHoledPolygon & C2DHoledPolygon::operator= (  C2DHoledPolygon &  Other  ) 
 

Assignement to another.

--------------------------------------------------------------------------
C2DHoledPolygon::operator=

---------------------------------------------------------------------------

bool C2DHoledPolygon::Overlaps (  const C2DHoledPolygon &  Other  )  const
 

True if this overlaps the other.

--------------------------------------------------------------------------
C2DHoledPolygon::Overlaps

---------------------------------------------------------------------------

void C2DHoledPolygon::RemoveHole (  unsigned short  usIndex  ) 
 

Removes the hole at the index given.

--------------------------------------------------------------------------
C2DHoledPolygon::RemoveHole

---------------------------------------------------------------------------

void C2DHoledPolygon::RotateToRight (  double  dAng,
const C2DPoint &  Origin
)  [virtual]
 

Rotates to the right by the angle around the centroid.

--------------------------------------------------------------------------
C2DHoledPolygon::RotateToRight

---------------------------------------------------------------------------

Reimplemented from C2DHoledPolyBase.

void C2DHoledPolygon::RotateToRight (  double  dAng  ) 
 

Rotates to the right by the angle around the centroid.

--------------------------------------------------------------------------
C2DHoledPolygon::RotateToRight

---------------------------------------------------------------------------

void C2DHoledPolygon::SetHole (  const C2DPolygon &  Polygon,
unsigned short  usIndex
) 
 

Sets the holes to be a copy of the polygon given.

--------------------------------------------------------------------------
C2DHoledPolygon::SetHole

---------------------------------------------------------------------------

void C2DHoledPolygon::SetHoleDirect (  C2DPolygon *  Polygon,
unsigned short  usIndex
) 
 

Sets the hole to be the polygon provided. Will delete on destruction. Deletes old one.

--------------------------------------------------------------------------
C2DHoledPolygon::SetHoleDirect

---------------------------------------------------------------------------

void C2DHoledPolygon::SetRim (  const C2DPolygon &  Polygon  ) 
 

Sets the rim to a copy of the polygon given.

--------------------------------------------------------------------------
C2DHoledPolygon::SetRim

---------------------------------------------------------------------------

void C2DHoledPolygon::SetRimDirect (  C2DPolygon *  Polygon  ) 
 

Sets the rim to be the polygon provided. Will delete on destruction.

--------------------------------------------------------------------------
C2DHoledPolygon::SetRimDirect

---------------------------------------------------------------------------


The documentation for this class was generated from the following files:
Generated on Mon Apr 21 11:43:51 2008 for GeoLib by  doxygen 1.4.4