24 #if !defined(DEBUG_DRAW_INCLUDED) 
   25 #define DEBUG_DRAW_INCLUDED 
   47 #include "../Extensions/ExServices/ExHostAppServices.h" 
  101 static bool g_DEBUG_DRAW_ENABLED = 
true;
 
  103 template <
class TSegment2d>
 
  108     pts[0] = rSeg.startPt();
 
  109     pts[1] = rSeg.endPt();
 
  118     rSeg.getArcSeg( 
arc2d );
 
  123 template <
class TSegment2d>
 
  125   if( g_DEBUG_DRAW_ENABLED ) {
 
  131     _debug_draw( proxy.
wGeom(), rSeg );
 
  145   for ( 
OdUInt32 i = 0; i < nSegments; ++i )
 
  168   for ( 
OdUInt32 i = 0; i < nSegments; ++i )
 
  185   if( g_DEBUG_DRAW_ENABLED ) {
 
  197   if( !g_DEBUG_DRAW_ENABLED ) 
 
  212   if( g_DEBUG_DRAW_ENABLED ) {
 
  223   if( g_DEBUG_DRAW_ENABLED ) {
 
  236   if( g_DEBUG_DRAW_ENABLED ) {
 
  243     for(
OdUInt32 nContour = 0; nContour < profile.
size(); nContour++)
 
  259         pt3d[1] = pt3d[0] + (pt3d[1] - pt3d[0]) * 0.1;
 
  286   if( !g_DEBUG_DRAW_ENABLED )
 
  292   const double dMult = 100000.0;
 
  309   if( !g_DEBUG_DRAW_ENABLED )
 
  317   const double dMult = 100000.0;
 
  321   cLineRep.appendVertex(ptS2d);
 
  322   cLineRep.appendVertex(ptE2d);
 
  329   if( !g_DEBUG_DRAW_ENABLED ) 
 
  340   static const double fMarkerSize = 100;
 
  361   if( g_DEBUG_DRAW_ENABLED ) {
 
  374   if( !g_DEBUG_DRAW_ENABLED ) 
 
  388   if( g_DEBUG_DRAW_ENABLED ) {
 
  396     for( i = 0; i <iSize; i++ )
 
  398       OdUInt32 j, jSize = profile[ i ].numSegments();
 
  399       for( j = 0; j < jSize; j++ )
 
  402         profile[ i ].getSegmentAt( j, seg );
 
  403         _debug_draw( proxy.
wGeom(), seg );
 
  411 inline void DEBUG_DRAW( 
const std::vector<FacetModeler::Profile2D>& rProfiles, 
OdInt16 color ) 
 
  413   if( !g_DEBUG_DRAW_ENABLED )
 
  416   for(
size_t idx = 0; idx < rProfiles.size(); idx++)
 
  424   if( g_DEBUG_DRAW_ENABLED ) { 
 
  438   if(!g_DEBUG_DRAW_ENABLED)
 
  444   const double dLineLength = 10000;
 
  467     while(!itEdges.done())
 
  473         if(pPairEdge != 
NULL)
 
  490   if( !g_DEBUG_DRAW_ENABLED )
 
  499   DebugDrawBody( proxy, body );
 
  508     if( !g_DEBUG_DRAW_ENABLED )
 
  516     const double dSizes = dSize;
 
  527   if( !g_DEBUG_DRAW_ENABLED )
 
  544   if( !g_DEBUG_DRAW_ENABLED )
 
  570   if( g_DEBUG_DRAW_ENABLED )
 
  575     const double dLength = 
v.length();
 
  576     const double dVecLength = dLength * 0.9;
 
  591   if( g_DEBUG_DRAW_ENABLED ) { 
 
  604   if( g_DEBUG_DRAW_ENABLED ) { 
 
  653   c3dPlane.as2d().push_back(c2dBox);
 
  676   for(
OdUInt32 contourIdx = 0; contourIdx < faceProfile.
size(); contourIdx++)
 
  679     if(currentContour.
isCCW())
 
  724         double dMin = 
odmin(dL, dW);
 
  733     pts[1] = ptOrigin + mEntity.
getCsXAxis() * dL;
 
  760     pts[1] = origin + xAxis * dBaseLen;
 
  763     pts[1] = origin + yAxis * dBaseLen * 3;
 
  766     pts[1] = origin + zAxis * dBaseLen * 5;
 
  795   for(
int s = 0; s < numSegs; s++)
 
  800     double dBulge = aSeg.
bulge();
 
  814   for(
int i = 0; i < numVerts; i++)
 
void DEBUG_DRAW_ENTITY_EXTENTS_2D(const OdGeMatrix3d &mEntity, const OdGeExtents3d &mExtents, OdUInt16 color)
void DEBUG_DRAW_AXIS4(const OdGePoint3d &ptOrigin, const OdGeVector3d &vAxis, const double fLen, OdInt16 color)
void DEBUG_CONTOUR2D(const Contour2D &c)
void DEBUG_DRAW_POLYLINE(const OdGePoint3d *ptPoly, OdUInt32 nPts, OdInt16 color)
void DEBUG_DRAW_FACE_PROFILE(const Profile2D &faceProfile)
void DEBUG_DRAW_PLANE(const OdGePlane &rPlane, const double fWidth, OdInt16 color)
void DEBUG_DRAW_LINE(const OdGeLine2d &aLine, OdInt16 color)
void DEBUG_DRAW1(const OdCmColor &color)
void DEBUG_DRAW_CS(const OdGePoint3d &ptOrigin, const OdGeVector3d &vx, const OdGeVector3d &vy, const OdGeVector3d &vz, const double fLen)
void DEBUG_DRAW3(OdRemoteGeomProxy &proxy, const Contour2D &contour, OdInt16 color)
void DEBUG_DRAW(const Contour2D &contour, OdInt16 color)
void DEBUG_DRAW_LINESEG(const OdGePoint2d &pt1, const OdGePoint2d &pt2, OdInt16 color)
void DEBUG_DRAW_FACE(const Face *pFace, OdInt16 color)
void DEBUG_DRAW_AXIS(const OdGePoint3d &ptOrigin, const OdGeVector3d &vAxis, const double fLen)
TAecAutoColor< OdUInt16 > AecAutoColor
void DEBUG_DRAW_TRIANGLE(const OdGePoint3d *ptTriangle, OdInt16 color)
bool OdZero(double x, double tol=1.e-10)
static Body box(const OdGePoint3d &ptOrigin, const OdGeVector3d &vSizes)
Result getLineSegAt(OdUInt32 iIndex, OdGeLineSeg2d &geLine) const
Result getBulgeAt(OdUInt32 iIndex, double &dBulge) const
void setClosed(bool bClosed=true)
Result getArcSegAt(OdUInt32 iIndex, OdGeCircArc2d &geArc) const
OdUInt32 numVerts() const
bool isSelfIntersecting(const OdGeTol &gTol=FMGeGbl::gTol, bool bExcludeTouch=false) const
Result getVertexAt(OdUInt32 iIndex, OdGePoint2d *pPoint, double *pBulge=0, OdIntPtr *pMetadata=0, OdUInt32 *puRawFlags=0) const
Result getSegmentAt(OdUInt32 iIndex, Segment2D &rSegment) const
OdUInt32 numSegments() const
Result appendVertex(const OdGePoint2d &ptStart, double dBulge=0.0, OdIntPtr uMetadata=0, OdUInt32 uRawFlags=0)
const OdGePoint3d & startPoint() const
const OdGePoint3d & endPoint() const
FacetModeler::Vertex * vertex() const
void profile(Profile3D &rResult, const OdGePlane *pPlane=0, bool bIncludeHoles=true) const
size_type size() const
DOM.
const OdGePoint2d & startPt() const
const OdGePoint2d & endPt() const
const OdGePoint3d & point() const
const OdGeMatrix3d & transform() const
void to3D(const OdGePoint2d &rSource2D, OdGePoint3d &rDest3D) const
OdCmEntityColor entityColor() const
const OdGePoint3d & maxPoint() const
const OdGePoint3d & minPoint() const
OdGePoint3d startPoint() const
OdGePoint3d endPoint() const
OdGePoint2d pointOnLine() const
OdGeVector2d direction() const
OdGeVector3d direction() const
OdGePoint3d pointOnLine() const
void getCoordSystem(OdGePoint3d &origin, OdGeVector3d &xAxis, OdGeVector3d &yAxis, OdGeVector3d &zAxis) const
OdGePoint3d getCsOrigin() const
OdGeVector3d getCsYAxis() const
OdGeVector3d getCsXAxis() const
OdGePoint3d pointOnPlane() const
OdGeVector3d normal() const
double distanceTo(const OdGePoint3d &point) const
virtual void popModelTransform()=0
virtual void polyline(OdInt32 numVertices, const OdGePoint3d *vertexList, const OdGeVector3d *pNormal=0, OdGsMarker baseSubEntMarker=-1)=0
virtual void polygon(OdInt32 numVertices, const OdGePoint3d *vertexList)=0
virtual void pushModelTransform(const OdGeVector3d &normal)=0
virtual OdUInt16 color() const =0
virtual void setLineWeight(OdDb::LineWeight lineWeight)=0
virtual void setColor(OdUInt16 color)=0
virtual void setTrueColor(const OdCmEntityColor &color)=0
OdGiSubEntityTraits & traits()
void sendStringToExecute(const OdString &s)
OdGiWorldGeometry & wGeom()
GLfloat GLfloat GLfloat v2