CFx SDK Documentation  2023 SP0
GeCurve2d.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 OD_GE_CURVE_2D_H
25 #define OD_GE_CURVE_2D_H
27 class OdGePointOnCurve2d;
28 class OdGeMatrix2d;
29 class OdGeLine2d;
30 class OdGePointOnCurve2dData;
31 class OdGeBoundBlock2d;
32 
33 #include "Ge/GeEntity2d.h"
34 #include "Ge/GeIntArray.h"
35 #include "Ge/GePoint2d.h"
36 #include "Ge/GePoint2dArray.h"
37 #include "Ge/GeVector2d.h"
38 #include "Ge/GeVector2dArray.h"
39 #include "Ge/GeCurve2dPtrArray.h"
40 #include "Ge/GeDoubleArray.h"
41 #include "Ge/GeInterval.h"
42 #include "Ge/GeExtents2d.h"
43 
44 #include "TD_PackPush.h"
45 
54 {
55 public:
56 
57 
67  OdGeInterval& interval) const;
68 
80  OdGeInterval& interval,
81  OdGePoint2d& start,
82  OdGePoint2d& end) const;
83 
94 
102 
112  const OdGeInterval& interval);
113 
121  double distanceTo(
122  const OdGePoint2d& point,
123  const OdGeTol& tol = OdGeContext::gTol) const;
124 
132  double distanceTo(
133  const OdGeCurve2d& otherCur,
134  const OdGeTol& tol = OdGeContext::gTol) const;
135 
143  const OdGePoint2d& point,
144  const OdGeTol& tol = OdGeContext::gTol) const;
145 
153  const OdGeCurve2d& curve2d,
154  OdGePoint2d& pntOnOtherCrv,
155  const OdGeTol& tol= OdGeContext::gTol) const;
156 
164  const OdGePoint2d& point,
165  OdGePointOnCurve2d& pntOnCrv,
166  const OdGeTol& tol = OdGeContext::gTol) const;
167 
175  const OdGeCurve2d& curve2d,
176  OdGePointOnCurve2d& pntOnThisCrv,
177  OdGePointOnCurve2d& pntOnOtherCrv,
178  const OdGeTol& tol = OdGeContext::gTol) const;
179 
187  const OdGePoint2d& point,
188  OdGePointOnCurve2d& pntOnCrv,
189  const OdGeTol& tol = OdGeContext::gTol) const;
190 
192 
201  bool isOn(
202  const OdGePoint2d& point,
203  double& param,
204  const OdGeTol& tol = OdGeContext::gTol) const;
205 
212  bool isOn(
213  double param,
214  const OdGeTol& tol = OdGeContext::gTol) const;
215 
231  double paramOf(
232  const OdGePoint2d& point,
233  const OdGeTol& tol = OdGeContext::gTol) const;
234 
242  double distance,
243  OdGeCurve2dPtrArray& offsetCurveList,
244  OdGe::OffsetCrvExtType extensionType = OdGe::kFillet,
245  const OdGeTol& tol = OdGeContext::gTol) const;
246 
252  bool isClosed(
253  const OdGeTol& tol = OdGeContext::gTol) const;
254 
264  double& period) const;
265 
279  bool isLinear(
280  OdGeLine2d& line,
281  const OdGeTol& tol = OdGeContext::gTol) const;
282 
289  double length(
290  double fromParam,
291  double toParam,
292  double tol
293 #ifndef SWIG
294  = OdGeContext::gTol.equalPoint()
295 #endif
296  ) const;
297 
298 
305  double length(
306  double tol
307 #ifndef SWIG
308  = OdGeContext::gTol.equalPoint()
309 #endif
310  ) const;
311 
319  double datumParam,
320  double length,
321  bool posParamDir
322 #ifndef SWIG
323  = true
324 #endif
325  , double tol
326 #ifndef SWIG
327  = OdGeContext::gTol.equalPoint()
328 #endif
329  ) const;
330 
335  bool area(
336  double startParam, double endParam,
337  double& value,
338  const OdGeTol& tol = OdGeContext::gTol) const;
339 
348  OdGe::EntityId& degenerateType,
349  const OdGeTol& tol = OdGeContext::gTol) const;
350 
359  OdGeEntity2d*& pConvertedEntity,
360  const OdGeTol& tol = OdGeContext::gTol) const;
361 
373  double param,
374  OdGeCurve2d*& piece1,
375  OdGeCurve2d*& piece2) const;
376 
383  bool explode(
384  OdGeCurve2dPtrArray& explodedCurves,
385  OdGeIntArray& newExplodedCurve,
386  const OdGeInterval* interval = NULL) const;
387 
395  const OdGePoint2d& point,
396  OdGePointOnCurve2d& approxPnt,
397  const OdGeInterval* nbhd = NULL,
398  const OdGeTol& tol = OdGeContext::gTol) const;
399 
407  const OdGeCurve2d& otherCurve,
408  OdGePointOnCurve2d& approxPntOnThisCrv,
409  OdGePointOnCurve2d& approxPntOnOtherCrv,
410  const OdGeInterval* nbhd1 = NULL,
411  const OdGeInterval* nbhd2 = NULL,
412  const OdGeTol& tol = OdGeContext::gTol) const;
413 
421 
429  const OdGeInterval& range) const;
430 
438 
446  const OdGeInterval& range) const;
447 
457  OdGePoint2d& startPoint) const;
458 
468  OdGePoint2d& endPoint) const;
469 
479  double param) const;
480 
493  double param,
494  int numDeriv,
495  OdGeVector2dArray& derivatives) const;
496 
507  double fromParam,
508  double toParam,
509  double approxEps,
510  OdGePoint2dArray& pointArray,
511  OdGeDoubleArray& paramArray) const;
512 
523  int numSample,
524  OdGePoint2dArray& pointArray) const;
525 
527 
529  // TD Special :
530 
532  double fromParam,
533  double toParam,
534  double approxEps,
535  OdGePoint2dArray& pointArray,
536  OdGeDoubleArray* pParamArray = NULL) const;
537 
548  double fromParam,
549  double toParam,
550  double approxEps,
551  OdGePoint2dArray& pointArray,
552  OdGeDoubleArray* pParamArray = NULL) const;
553 
561  int numSample,
562  OdGePoint2dArray& pointArray) const;
563 
564  //FELIX_CHANGE_BEGIN
566 
568  const OdGeInterval& range = OdGeInterval(),
569  const OdGeMatrix2d* coordSystem = NULL) const;
570 
571  void evaluate(
572  double param,
573  int numDeriv, OdGeVector2d* values) const;
574 
576  const OdGeCurve3d* curve,
577  const OdGeSurface* surface,
578  const OdGeTol& tol = OdGeContext::gTol);
579  //FELIX_CHANGE_END
580 
581 protected:
586  const OdGeCurve2d& source);
587 };
588 
589 #include "TD_PackPop.h"
590 
591 #endif // OD_GE_CURVE_2D_H
592 
tol
Definition: DimVarDefs.h:2287
#define GE_TOOLKIT_EXPORT
Definition: GeExport.h:49
#define NULL
Definition: GsProperties.h:177
bool isOn(const OdGePoint2d &point, double &param, const OdGeTol &tol=OdGeContext::gTol) const
void evaluate(double param, int numDeriv, OdGeVector2d *values) const
OdGeBoundBlock2d boundBlock() const
void getSamplePoints(double fromParam, double toParam, double approxEps, OdGePoint2dArray &pointArray, OdGeDoubleArray *pParamArray=NULL) const
OdGeCurve2d & setInterval()
TD_USING(OdGeEntity2d::isOn)
static OdGeCurve2d * restoreUvCurve(const OdGeCurve3d *curve, const OdGeSurface *surface, const OdGeTol &tol=OdGeContext::gTol)
double paramOf(const OdGePoint2d &point, const OdGeTol &tol=OdGeContext::gTol) const
double length(double tol=OdGeContext::gTol.equalPoint()) const
bool isClosed(const OdGeTol &tol=OdGeContext::gTol) const
void appendSamplePoints(int numSample, OdGePoint2dArray &pointArray) const
void appendSamplePoints(double fromParam, double toParam, double approxEps, OdGePoint2dArray &pointArray, OdGeDoubleArray *pParamArray=NULL) const
OdGeCurve3d * convertTo3d() const
void getLocalClosestPoints(const OdGePoint2d &point, OdGePointOnCurve2d &approxPnt, const OdGeInterval *nbhd=NULL, const OdGeTol &tol=OdGeContext::gTol) const
bool isDegenerate(OdGe::EntityId &degenerateType, const OdGeTol &tol=OdGeContext::gTol) const
OdGePoint2d evalPoint(double param, int numDeriv, OdGeVector2dArray &derivatives) const
OdGePoint2d closestPointTo(const OdGeCurve2d &curve2d, OdGePoint2d &pntOnOtherCrv, const OdGeTol &tol=OdGeContext::gTol) const
bool isLinear(OdGeLine2d &line, const OdGeTol &tol=OdGeContext::gTol) const
OdGeBoundBlock2d orthoBoundBlock(const OdGeInterval &range) const
void getLocalClosestPoints(const OdGeCurve2d &otherCurve, OdGePointOnCurve2d &approxPntOnThisCrv, OdGePointOnCurve2d &approxPntOnOtherCrv, const OdGeInterval *nbhd1=NULL, const OdGeInterval *nbhd2=NULL, const OdGeTol &tol=OdGeContext::gTol) const
bool isPeriodic(double &period) const
OdGePoint2d evalPoint(double param) const
bool isOn(double param, const OdGeTol &tol=OdGeContext::gTol) const
bool area(double startParam, double endParam, double &value, const OdGeTol &tol=OdGeContext::gTol) const
OdGeCurve2d(const OdGeCurve2d &source)
OdGeBoundBlock2d orthoBoundBlock() const
OdGeBoundBlock2d boundBlock(const OdGeInterval &range) const
double paramAtLength(double datumParam, double length, bool posParamDir=true, double tol=OdGeContext::gTol.equalPoint()) const
void getSamplePoints(int numSample, OdGePoint2dArray &pointArray) const
bool explode(OdGeCurve2dPtrArray &explodedCurves, OdGeIntArray &newExplodedCurve, const OdGeInterval *interval=NULL) const
void getInterval(OdGeInterval &interval) const
double length(double fromParam, double toParam, double tol=OdGeContext::gTol.equalPoint()) const
OdGePoint2d closestPointTo(const OdGePoint2d &point, const OdGeTol &tol=OdGeContext::gTol) const
bool getNormalPoint(const OdGePoint2d &point, OdGePointOnCurve2d &pntOnCrv, const OdGeTol &tol=OdGeContext::gTol) const
void getInterval(OdGeInterval &interval, OdGePoint2d &start, OdGePoint2d &end) const
void getTrimmedOffset(double distance, OdGeCurve2dPtrArray &offsetCurveList, OdGe::OffsetCrvExtType extensionType=OdGe::kFillet, const OdGeTol &tol=OdGeContext::gTol) const
void getClosestPointTo(const OdGePoint2d &point, OdGePointOnCurve2d &pntOnCrv, const OdGeTol &tol=OdGeContext::gTol) const
double distanceTo(const OdGeCurve2d &otherCur, const OdGeTol &tol=OdGeContext::gTol) const
double distanceTo(const OdGePoint2d &point, const OdGeTol &tol=OdGeContext::gTol) const
bool isDegenerate(OdGeEntity2d *&pConvertedEntity, const OdGeTol &tol=OdGeContext::gTol) const
void getSplitCurves(double param, OdGeCurve2d *&piece1, OdGeCurve2d *&piece2) const
OdGeExtents2d getGeomExtents(const OdGeInterval &range=OdGeInterval(), const OdGeMatrix2d *coordSystem=NULL) const
void getSamplePoints(double fromParam, double toParam, double approxEps, OdGePoint2dArray &pointArray, OdGeDoubleArray &paramArray) const
OdGeCurve2d & reverseParam()
bool setInterval(const OdGeInterval &interval)
bool hasEndPoint(OdGePoint2d &endPoint) const
void getClosestPointTo(const OdGeCurve2d &curve2d, OdGePointOnCurve2d &pntOnThisCrv, OdGePointOnCurve2d &pntOnOtherCrv, const OdGeTol &tol=OdGeContext::gTol) const
bool hasStartPoint(OdGePoint2d &startPoint) const
OdGeEntity2d & operator=(const OdGeEntity2d &entity)
bool isOn(const OdGePoint2d &point, const OdGeTol &tol=OdGeContext::gTol) const
Definition: GeTol.h:49
GLsizei GLsizei GLchar * source
Definition: gles2_ext.h:282
GLuint GLsizei GLsizei * length
Definition: gles2_ext.h:274
GLenum GLint * range
Definition: gles2_ext.h:563
GLsizei const GLfloat * value
Definition: gles2_ext.h:302
static GE_STATIC_EXPORT OdGeTol gTol
Definition: GeGbl.h:60
EntityId
Definition: Ge.h:53
OffsetCrvExtType
Definition: Ge.h:179
@ kFillet
Definition: Ge.h:180