CFx SDK Documentation  2023 SP0
AECProfile2DBoundary.h
Go to the documentation of this file.
1 // Copyright (C) 2002-2017, Open Design Alliance (the "Alliance").
3 // All rights reserved.
4 //
5 // This software and its documentation and related materials are owned by
6 // the Alliance. The software may only be incorporated into application
7 // programs owned by members of the Alliance, subject to a signed
8 // Membership Agreement and Supplemental Software License Agreement with the
9 // Alliance. The structure and organization of this software are the valuable
10 // trade secrets of the Alliance and its suppliers. The software is also
11 // protected by copyright law and international treaty provisions. Application
12 // programs incorporating this software must include the following statement
13 // with their copyright notices:
14 //
15 // This application incorporates Teigha(R) software pursuant to a license
16 // agreement with Open Design Alliance.
17 // Teigha(R) Copyright (C) 2002-2017 by Open Design Alliance.
18 // All rights reserved.
19 //
20 // By use of this software, its documentation or related materials, you
21 // acknowledge and accept the above terms.
23 
24 #ifndef __AECPROFILE2DBOUNDARY_H__
25 #define __AECPROFILE2DBOUNDARY_H__
26 
28 #include "FMProfile2D.h"
29 
30 #include <functional> //FELIX_CHANGE
31 
32 class OdDbDatabase;
33 
37 namespace AECGe
38 {
39 
44 class AECGEOMETRY_API Profile2DBoundary
45 {
46  public:
51 
56 
60  const OdGeTol& tol() const;
61 
65  void setTol( const OdGeTol& tTol );
66 
71 
76 
81 
86 
100  FacetModeler::Result getBoundary(const OdGePoint2d& ptInside, double dGap,
101  bool bIgnoreHoles, FacetModeler::Profile2D& rResult,
102  bool bEnableSelfIntersections = false,
103  bool bIgnoreNestedHoles = true ) const;
104 
105  //FELIX_CHANGE_BEGIN
121  bool bIgnoreHoles, FacetModeler::Profile2D& rResult,
122  bool bEnableSelfIntersections = false,
123  bool bIgnoreNestedHoles = true,
124  std::function< bool() > fAbort = nullptr ) const;
125  //FELIX_CHANGE_END
126 
136 
137  private:
138  class Profile2DBoundaryImpl* m_pImpl;
139 };
140 
144 template <class T>
146 {
147  public:
149  Profile2DBoundary& rDestination ) : T( pDb, mUCS ), m_rDestination( rDestination )
150  {
151  }
152 
153  public:
157  virtual void processGeometry( FacetModeler::Segment2D& rGeometry ) const
158  {
159  m_rDestination.addGeometry( rGeometry );
160  }
161 
165  virtual void processGeometry( FacetModeler::Contour2D& rGeometry ) const
166  {
167  m_rDestination.addGeometry( rGeometry );
168  }
169 
173  virtual void processGeometry( FacetModeler::Profile2D& rGeometry ) const
174  {
175  m_rDestination.addGeometry( rGeometry );
176  }
177 
178  private:
179  Profile2DBoundary& m_rDestination;
180 };
181 
182 }
183 
184 #endif // __AECPROFILE2DBOUNDARY_H__
virtual void processGeometry(FacetModeler::Segment2D &rGeometry) const
virtual void processGeometry(FacetModeler::Contour2D &rGeometry) const
Profile2DBoundaryHarvester(OdDbDatabase *pDb, const OdGeMatrix3d &mUCS, Profile2DBoundary &rDestination)
virtual void processGeometry(FacetModeler::Profile2D &rGeometry) const
FacetModeler::Result addGeometry(const FacetModeler::Profile2D &rGeometry)
FacetModeler::Result addGeometry(const FacetModeler::Contour2D &rGeometry)
Profile2DBoundary(const OdGeTol &gTol=FacetModeler::FMGeGbl::gTol)
const OdGeTol & tol() const
FacetModeler::Result getBoundaryAbortable(const OdGePoint2d &ptInside, double dGap, bool bIgnoreHoles, FacetModeler::Profile2D &rResult, bool bEnableSelfIntersections=false, bool bIgnoreNestedHoles=true, std::function< bool() > fAbort=nullptr) const
FacetModeler::Result getOuterBoundary(FacetModeler::Profile2D &rResult) const
FacetModeler::Result addGeometry(const FacetModeler::Segment2D &rGeometry)
FacetModeler::Result clearGeometry()
FacetModeler::Result getBoundary(const OdGePoint2d &ptInside, double dGap, bool bIgnoreHoles, FacetModeler::Profile2D &rResult, bool bEnableSelfIntersections=false, bool bIgnoreNestedHoles=true) const
void setTol(const OdGeTol &tTol)
Definition: GeTol.h:49
static FMGEOMETRY_API_STATIC OdGeTol gTol
Definition: FMGeometry.h:156