PLANECONIC Class Reference

#include <mi32/planeconic.h>

List of all members.

Public Types

enum  CLOSURE { CLOSURE_Open, CLOSURE_Chord, CLOSURE_Wedge, CLOSURE_Complete }

Public Member Functions

 PLANECONIC (const PLANECONIC &rhs)
 PLANECONIC ()
void Clear ()
bool ComputeArc (const DPOINT3D &p1, const DPOINT3D &p2, const DPOINT3D &p3)
bool ComputeArc (const DPOINT2D &p1, const DPOINT2D &p2, const DPOINT2D &p3)
bool ComputeArcByBulge (const DPOINT3D &p1, const DPOINT3D &p2, double bulge, const DPOINT3D &Normal)
bool ComputeArcByBulge (const DPOINT2D &p1, const DPOINT2D &p2, double bulge)
bool ComputeCircle (const DPOINT3D &p1, const DPOINT3D &p2, const DPOINT3D &p3)
bool ComputeCircle (const DPOINT2D &p1, const DPOINT2D &p2, const DPOINT2D &p3)
bool ComputeCircle (const DPOINT2D &p1, const DPOINT2D &p2)
double ComputeDistanceFrom (const DPOINT3D &pt) const
double ComputeDistanceFrom (const DPOINT2D &pt) const
bool ComputeEllipseFromRect (const POLYLINE &PolyLine)
void ComputeExtents (DRECT3D &Extents) const
bool ComputeRectFromEllipse (POLYLINE &PolyLine) const
bool ConvertForward (const TRANS2D_MAPGEN &tmg)
bool ConvertForward (const TRANS2D_AFFINE &taf)
bool ConvertInverse (const TRANS2D_MAPGEN &tmg)
bool ConvertInverse (const TRANS2D_AFFINE &taf)
bool GenerateArc3Points (DPOINT2D &p1, DPOINT2D &p2, DPOINT2D &p3) const
ERRVALUE GenerateConicPoints (POLYLINE &PolyLine, double MinChordDist=0.0) const
const DPOINT3DGetCenterPoint () const
CLOSURE GetClosure () const
double GetEndAngle () const
const DPOINT3DGetExtrusionPoint () const
double GetRotation () const
double GetStartAngle () const
double GetXRadius () const
double GetYRadius () const
bool HasExtrusion () const
bool IsCircular () const
bool IsDefined () const
bool IsPointInside (const DPOINT3D &pt) const
bool IsPointInside (const DPOINT2D &pt) const
PLANECONICoperator= (const PLANECONIC &rhs)
void SetCenterPoint (const DPOINT3D &point)
void SetClosure (CLOSURE Closure)
void SetEndAngle (double angle)
void SetExtrusionPoint (const DPOINT3D &Extrusion)
void SetRotation (double rotation)
void SetStartAngle (double angle)
void SetXRadius (double radius)
void SetYRadius (double radius)

Member Enumeration Documentation

Enumerator:
CLOSURE_Open 

Arc or Elliptical arc, no polygon formed.

CLOSURE_Chord 

Arc or Elliptical arc with closure point as a segment from end angle point to start angle point.

CLOSURE_Wedge 

Arc or Elliptical arc with closure point as a line from end angle point to the center point and ending at the start angle point.

CLOSURE_Complete 

Circle or ellipse.


Constructor & Destructor Documentation

PLANECONIC::PLANECONIC (  ) 

Default ctor.

PLANECONIC::PLANECONIC ( const PLANECONIC rhs  ) 

Copy ctor.


Member Function Documentation

void PLANECONIC::Clear (  ) 

Clear conic to initial state (no conic defined).

bool PLANECONIC::ComputeArc ( const DPOINT3D p1,
const DPOINT3D p2,
const DPOINT3D p3 
)

Compute arc based on three points Extrusion vertex calculated based on the plane defined by the three points.

Returns:
'True' if successful, false if not (All 3 points lie on a line or 2 points are the same)
bool PLANECONIC::ComputeArc ( const DPOINT2D p1,
const DPOINT2D p2,
const DPOINT2D p3 
)

Compute arc based on three points.

Returns:
'True' if successful, false if not (All 3 points lie on a line or 2 points are the same)
bool PLANECONIC::ComputeArcByBulge ( const DPOINT3D p1,
const DPOINT3D p2,
double  bulge,
const DPOINT3D Normal 
)

Compute arc based on three points.

Returns:
'True' if successful, false if not (bulge == 0 or 2 points are the same)
bool PLANECONIC::ComputeArcByBulge ( const DPOINT2D p1,
const DPOINT2D p2,
double  bulge 
)

Compute arc based on three points.

Returns:
'True' if successful, false if not (bulge == 0 or 2 points are the same)
Parameters:
bulge If positive, generates the arc on the left side of the line, if negative, on the right side
bool PLANECONIC::ComputeCircle ( const DPOINT3D p1,
const DPOINT3D p2,
const DPOINT3D p3 
)

Compute circle based on three points Extrusion vertex calculated based on the plane defined by the three points.

Returns:
'True' if successful, false if not (All 3 points lie on a line or 2 points are the same)
bool PLANECONIC::ComputeCircle ( const DPOINT2D p1,
const DPOINT2D p2,
const DPOINT2D p3 
)

Compute circle based on three points.

Returns:
'True' if successful, false if not (All 3 points lie on a line or 2 points are the same)
bool PLANECONIC::ComputeCircle ( const DPOINT2D p1,
const DPOINT2D p2 
)

Compute circle based on two points.

Returns:
'True' if successful, false if not (Both points are the same)
double PLANECONIC::ComputeDistanceFrom ( const DPOINT3D pt  )  const

Compute distance from point given to edge of conic.

Returns:
Distance from point to edge of conic
double PLANECONIC::ComputeDistanceFrom ( const DPOINT2D pt  )  const

Compute distance from point given to edge of conic.

Returns:
Distance from point to edge of conic
bool PLANECONIC::ComputeEllipseFromRect ( const POLYLINE PolyLine  ) 

Compute 2D ellipse based on inscribed rectangle given.

Returns:
'True' if successful, false if not (More than 5 points or area of zero)
void PLANECONIC::ComputeExtents ( DRECT3D Extents  )  const

Compute extents of conic.

bool PLANECONIC::ComputeRectFromEllipse ( POLYLINE PolyLine  )  const

Compute circumscribed rectangle from 2D ellipse.

Returns:
'True' if successful, false if not (Not an ellipse)
Parameters:
PolyLine Place to put the computed rectangle to
bool PLANECONIC::ConvertForward ( const TRANS2D_MAPGEN tmg  ) 

Convert conic using generic transformation.

Returns:
'True' if conversion valid, 'false' if approximated
bool PLANECONIC::ConvertForward ( const TRANS2D_AFFINE taf  ) 

Convert conic using affine transformation.

Returns:
'True' if conversion valid, 'false' if approximated
bool PLANECONIC::ConvertInverse ( const TRANS2D_MAPGEN tmg  ) 

Convert conic using generic transformation.

Returns:
'True' if conversion valid, 'false' if approximated
bool PLANECONIC::ConvertInverse ( const TRANS2D_AFFINE taf  ) 

Convert conic using affine transformation.

Returns:
'True' if conversion valid, 'false' if approximated
bool PLANECONIC::GenerateArc3Points ( DPOINT2D p1,
DPOINT2D p2,
DPOINT2D p3 
) const

Given a circular conic (arc or circle), generate a set of three points that will define the arc or circle.

ERRVALUE PLANECONIC::GenerateConicPoints ( POLYLINE PolyLine,
double  MinChordDist = 0.0 
) const

Generate a POLYLINE from 'this' using the 'MinChordDist' to determine the number of points used to create the line or polygon.

Parameters:
MinChordDist Default is to use 5 of the Radius length
const DPOINT3D& PLANECONIC::GetCenterPoint (  )  const [inline]

Get center of conic in absolute coordinates.

Returns:
Center point of the conic
CLOSURE PLANECONIC::GetClosure (  )  const [inline]

Get the closure of the conic.

Returns:
Closure of the conic
double PLANECONIC::GetEndAngle (  )  const [inline]

Get the end angle of the arc or elliptical arc in radians.

Returns:
End angle in radians
const DPOINT3D& PLANECONIC::GetExtrusionPoint (  )  const [inline]

Get extrusion point of conic in absolute coordinates.

This point, along with the center point, define the normal vertex to the plane that this conic resides.

Returns:
Extrusion point of the conic
double PLANECONIC::GetRotation (  )  const [inline]

Rotation of conic with respect to the X axis.

Not used if conic is circle or arc.

Returns:
Rotation of conic in radians.
double PLANECONIC::GetStartAngle (  )  const [inline]

Get the start angle of the arc or elliptical arc in radians.

Returns:
Start angle in radians
double PLANECONIC::GetXRadius (  )  const [inline]

Get the X radius of conic.

Conic is a circle or arc if m_XRadius == m_YRadius or m_YRadius == 0.0.

Returns:
X radius of conic.
double PLANECONIC::GetYRadius (  )  const [inline]

Get the Y radius of conic.

Conic is a circle or arc if m_XRadius == m_YRadius or m_YRadius == 0.0.

Returns:
Y radius of conic.
bool PLANECONIC::HasExtrusion (  )  const [inline]

Is extrusion vertex valid?

Returns:
'True' if extrusion vertex is valid, 'false' if not
bool PLANECONIC::IsCircular (  )  const [inline]

Is the conic element circular?

Returns:
'True' if circular, 'false' if elliptical
bool PLANECONIC::IsDefined (  )  const [inline]

Is the conic element defined?

bool PLANECONIC::IsPointInside ( const DPOINT3D pt  )  const

Does the point lie inside the conic defined on the plane.

bool PLANECONIC::IsPointInside ( const DPOINT2D pt  )  const

Is the point inside the conic If the conic is extruded, it will determine if the point lies inside the projected conic to the XY plane.

PLANECONIC& PLANECONIC::operator= ( const PLANECONIC rhs  ) 

Assigment.

void PLANECONIC::SetCenterPoint ( const DPOINT3D point  )  [inline]

Get center of conic in absolute coordinates.

void PLANECONIC::SetClosure ( CLOSURE  Closure  )  [inline]

Set the closure of the conic.

void PLANECONIC::SetEndAngle ( double  angle  )  [inline]

Set the end angle of the arc or elliptical arc in radians.

void PLANECONIC::SetExtrusionPoint ( const DPOINT3D Extrusion  ) 

Set extrusion point of conic in absolute coordinates.

This point, along with the center point, define the normal vertex to the plane that this conic resides.

void PLANECONIC::SetRotation ( double  rotation  )  [inline]

Rotation of conic with respect to the X axis. Not used if conic is circle or arc.

void PLANECONIC::SetStartAngle ( double  angle  )  [inline]

Set the start angle of the arc or elliptical arc in radians.

void PLANECONIC::SetXRadius ( double  radius  )  [inline]

Set the X radius of conic.

Conic is a circle or arc if m_XRadius == m_YRadius or m_YRadius == 0.0.

void PLANECONIC::SetYRadius ( double  radius  )  [inline]

Set the Y radius of conic.

Conic is a circle or arc if m_XRadius == m_YRadius or m_YRadius == 0.0.


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

Generated on Sun Oct 7 21:33:42 2012 for TNTsdk 2012 by  doxygen 1.6.1