CFx SDK Documentation  2023 SP0
GeCurve3d.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_GECURVE3D_H_
25 #define _OD_GECURVE3D_H_
27 #include "Ge/GeEntity3d.h"
28 #include "Ge/GeDoubleArray.h"
29 #include "Ge/GeVector3dArray.h"
30 #include "Ge/GeCurve3dPtrArray.h"
31 #include "Ge/GeIntArray.h"
32 #include "Ge/GeInterval.h"
33 #include "Ge/GeBoundBlock3d.h"
34 class OdGeCurve2d;
35 class OdGeSurface;
36 class OdGePoint3d;
37 class OdGePlane;
38 class OdGeVector3d;
39 class OdGeLinearEnt3d;
40 class OdGeLine3d;
41 class OdGePointOnCurve3d;
42 class OdGePointOnSurface;
43 class OdGeMatrix3d;
44 class OdGePointOnCurve3dData;
45 
46 #include "TD_PackPush.h"
47 
56 {
57 public:
58 
59 
69  OdGeInterval& interval) const;
70 
80  OdGeInterval& interval,
81  OdGePoint3d& start,
82  OdGePoint3d& end) const;
83 
100 
117  const OdGeInterval& interval);
118 
125  double distanceTo(
126  const OdGePoint3d& point,
127  const OdGeTol& tol = OdGeContext::gTol) const;
128 
135  double distanceTo(
136  const OdGeCurve3d& curve,
137  const OdGeTol& tol = OdGeContext::gTol) const;
138 
146  const OdGePoint3d& point,
147  const OdGeTol& tol = OdGeContext::gTol) const;
148 
158  const OdGeCurve3d& curve,
159  OdGePoint3d& pntOnOtherCrv,
160  const OdGeTol& tol = OdGeContext::gTol) const;
161 
173  const OdGePoint3d& point,
174  OdGePointOnCurve3d& pntOnCrv,
175  const OdGeTol& tol = OdGeContext::gTol) const;
176 
190  const OdGeCurve3d& curve,
191  OdGePointOnCurve3d& pntOnThisCrv,
192  OdGePointOnCurve3d& pntOnOtherCrv,
193  const OdGeTol& tol = OdGeContext::gTol) const;
194 
213  const OdGePoint3d& point,
214  const OdGeVector3d& projectDirection,
215  const OdGeTol& tol = OdGeContext::gTol) const;
216 
237  const OdGeCurve3d& curve,
238  const OdGeVector3d& projectDirection,
239  OdGePoint3d& pntOnOtherCrv,
240  const OdGeTol& tol = OdGeContext::gTol) const;
241 
261  const OdGePoint3d& point,
262  const OdGeVector3d& projectDirection,
263  OdGePointOnCurve3d& pntOnCrv,
264  const OdGeTol& tol = OdGeContext::gTol) const;
265 
287  const OdGeCurve3d& curve,
288  const OdGeVector3d& projectDirection,
289  OdGePointOnCurve3d& pntOnThisCrv,
290  OdGePointOnCurve3d& pntOnOtherCrv,
291  const OdGeTol& tol = OdGeContext::gTol) const;
292 
311  const OdGePoint3d& point,
312  OdGePointOnCurve3d& pntOnCrv,
313  const OdGeTol& tol = OdGeContext::gTol) const;
314 
328 
344  const OdGeInterval& range) const;
345 
353  const OdGeInterval& range) const;
354 
356  const OdGePlane& projectionPlane,
357  const OdGeVector3d& projectDirection,
358  const OdGeTol& tol = OdGeContext::gTol) const;
359 
361  const OdGePlane& projectionPlane,
362  const OdGeTol& tol = OdGeContext::gTol) const;
363 
364  // Tests if point is on *curve*.
366  bool isOn(
367  const OdGePoint3d& point,
368  double& param,
369  const OdGeTol& tol = OdGeContext::gTol) const;
370  bool isOn(
371  double param,
372  const OdGeTol& tol = OdGeContext::gTol) const;
373 
395  double paramOf(
396  const OdGePoint3d& point,
397  const OdGeTol& tol = OdGeContext::gTol) const;
398 
431  double distance,
432  const OdGeVector3d& planeNormal,
433  OdGeCurve3dPtrArray& offsetCurveList,
434  OdGe::OffsetCrvExtType extensionType = OdGe::kFillet,
435  const OdGeTol& tol = OdGeContext::gTol) const;
436 
442  bool isClosed(
443  const OdGeTol& tol = OdGeContext::gTol) const;
444 
456  bool isPlanar(
457  OdGePlane& plane,
458  const OdGeTol& tol = OdGeContext::gTol) const;
459 
476  bool isLinear(
477  OdGeLine3d& line,
478  const OdGeTol& tol = OdGeContext::gTol) const;
479 
489  const OdGeCurve3d& curve,
490  OdGePlane& plane,
491  const OdGeTol& tol = OdGeContext::gTol) const;
492 
499  double& period) const;
500 
508  double length(
509  double fromParam,
510  double toParam,
511  double tol
512 #ifndef SWIG
513  = OdGeContext::gTol.equalPoint()
514 #endif
515  ) const;
516 
522  double length(
523  double tol
524 #ifndef SWIG
525  = OdGeContext::gTol.equalPoint()
526 #endif
527  ) const;
528 
538  double paramAtLength(
539  double datumParam,
540  double length,
541  bool posParamDir
542 #ifndef SWIG
543  = true
544 #endif
545  , double tol
546 #ifndef SWIG
547  = OdGeContext::gTol.equalPoint()
548 #endif
549  ) const;
550 
560  bool area(
561  double startParam,
562  double endParam,
563  double& value,
564  const OdGeTol& tol = OdGeContext::gTol) const;
565 
577  OdGe::EntityId& degenerateType,
578  const OdGeTol& tol = OdGeContext::gTol) const;
579 
591  OdGeEntity3d*& pConvertedEntity,
592  const OdGeTol& tol = OdGeContext::gTol) const;
593 
611  double param,
612  OdGeCurve3d*& piece1,
613  OdGeCurve3d*& piece2) const;
614 
625  bool explode(
626  OdGeCurve3dPtrArray& explodedCurves,
627  OdGeIntArray& newExplodedCurves,
628  const OdGeInterval* pInterval = NULL) const;
629 
639  const OdGePoint3d& point,
640  OdGePointOnCurve3d& approxPntOnThisCrv,
641  const OdGeInterval* pInterval1 = NULL,
642  const OdGeTol& tol = OdGeContext::gTol) const;
643 
656  const OdGeCurve3d& curve,
657  OdGePointOnCurve3d& approxPntOnThisCrv,
658  OdGePointOnCurve3d& approxPntOnOtherCrv,
659  const OdGeInterval* pInterval1 = NULL,
660  const OdGeInterval* pInterval2 = NULL,
661  const OdGeTol& tol = OdGeContext::gTol) const;
662 
669  OdGePoint3d& startPoint) const;
670 
677  OdGePoint3d& endPoint) const;
678 
685  double param) const;
686 
696  double param,
697  int numDeriv,
698  OdGeVector3dArray& derivatives) const;
699 
711  double fromParam,
712  double toParam,
713  double approxEps,
714  OdGePoint3dArray& pointArray,
715  OdGeDoubleArray& paramArray,
716  bool forceResampling = false) const;
717 
726  int numSample,
727  OdGePoint3dArray& pointArray) const;
728 
737  int numSample,
738  OdGePoint3dArray& pointArray,
739  OdGeDoubleArray& paramArray) const;
740 
741  // Assignment operator.
743 
745  // TD Special :
746 
752  double fromParam,
753  double toParam,
754  double approxEps,
755  OdGePoint3dArray& pointArray,
756  OdGeDoubleArray* paramArray = NULL) const;
757 
768  const OdGeInterval* paramInterval,
769  double approxEps,
770  OdGePoint3dArray& pointArray,
771  OdGeDoubleArray* pParamArray = NULL) const;
772 
786  double fromParam,
787  double toParam,
788  double approxEps,
789  OdGePoint3dArray& pointArray,
790  OdGeDoubleArray* pParamArray = NULL) const;
791 
792 
801  int numSample,
802  OdGePoint3dArray& pointArray,
803  OdGeDoubleArray* pParamArray = NULL) const;
804 
817  const OdGeInterval *paramInterval,
818  double approxEps,
819  OdGePoint3dArray& pointArray,
820  OdGeDoubleArray* pParamArray = NULL) const;
821 
822 //FELIX_CHANGE_BEGIN
837  double paramOf(
838  const OdGePoint3d& point,
839  const OdGeInterval* range,
840  const OdGeTol& tol = OdGeContext::gTol) const;
841 
858  const OdGeInterval& range = OdGeInterval(),
859  const OdGeMatrix3d* coordSystem = NULL) const;
860 
873  void evaluate(
874  double param,
875  int numDeriv, OdGeVector3d* values) const;
876 //FELIX_CHANGE_END
877 
878 protected:
881  const OdGeCurve3d& source);
882 };
883 
885  const OdGeCurve3d* source,
886  const OdGeTol& tol = OdGeContext::gTol,
887  bool sameParametrization = false );
888 
889 #include "TD_PackPop.h"
890 
891 #endif
892 
tol
Definition: DimVarDefs.h:2287
GE_TOOLKIT_EXPORT OdGeCurve2d * convertTo2d(const OdGeCurve3d *source, const OdGeTol &tol=OdGeContext::gTol, bool sameParametrization=false)
#define GE_TOOLKIT_EXPORT
Definition: GeExport.h:49
#define NULL
Definition: GsProperties.h:177
void getLocalClosestPoints(const OdGeCurve3d &curve, OdGePointOnCurve3d &approxPntOnThisCrv, OdGePointOnCurve3d &approxPntOnOtherCrv, const OdGeInterval *pInterval1=NULL, const OdGeInterval *pInterval2=NULL, const OdGeTol &tol=OdGeContext::gTol) const
void getSplitCurves(double param, OdGeCurve3d *&piece1, OdGeCurve3d *&piece2) const
void getInterval(OdGeInterval &interval, OdGePoint3d &start, OdGePoint3d &end) const
void getClosestPointTo(const OdGeCurve3d &curve, OdGePointOnCurve3d &pntOnThisCrv, OdGePointOnCurve3d &pntOnOtherCrv, const OdGeTol &tol=OdGeContext::gTol) const
bool hasStartPoint(OdGePoint3d &startPoint) const
bool isPlanar(OdGePlane &plane, const OdGeTol &tol=OdGeContext::gTol) const
bool isOn(double param, const OdGeTol &tol=OdGeContext::gTol) const
bool isDegenerate(OdGeEntity3d *&pConvertedEntity, const OdGeTol &tol=OdGeContext::gTol) const
double length(double fromParam, double toParam, double tol=OdGeContext::gTol.equalPoint()) const
OdGeEntity3d * orthoProject(const OdGePlane &projectionPlane, const OdGeTol &tol=OdGeContext::gTol) const
void getLocalClosestPoints(const OdGePoint3d &point, OdGePointOnCurve3d &approxPntOnThisCrv, const OdGeInterval *pInterval1=NULL, const OdGeTol &tol=OdGeContext::gTol) const
OdGePoint3d projClosestPointTo(const OdGeCurve3d &curve, const OdGeVector3d &projectDirection, OdGePoint3d &pntOnOtherCrv, const OdGeTol &tol=OdGeContext::gTol) const
OdGeCurve3d & setInterval()
bool isCoplanarWith(const OdGeCurve3d &curve, OdGePlane &plane, const OdGeTol &tol=OdGeContext::gTol) const
bool isOn(const OdGePoint3d &point, double &param, const OdGeTol &tol=OdGeContext::gTol) const
void appendSamplePoints(double fromParam, double toParam, double approxEps, OdGePoint3dArray &pointArray, OdGeDoubleArray *pParamArray=NULL) const
OdGeBoundBlock3d boundBlock() const
bool hasEndPoint(OdGePoint3d &endPoint) const
void getSamplePoints(double fromParam, double toParam, double approxEps, OdGePoint3dArray &pointArray, OdGeDoubleArray &paramArray, bool forceResampling=false) const
void getInterval(OdGeInterval &interval) const
OdGeBoundBlock3d boundBlock(const OdGeInterval &range) const
OdGeExtents3d getGeomExtents(const OdGeInterval &range=OdGeInterval(), const OdGeMatrix3d *coordSystem=NULL) const
void appendSamplePoints(int numSample, OdGePoint3dArray &pointArray, OdGeDoubleArray *pParamArray=NULL) const
OdGePoint3d projClosestPointTo(const OdGePoint3d &point, const OdGeVector3d &projectDirection, const OdGeTol &tol=OdGeContext::gTol) const
bool isPeriodic(double &period) const
void getSamplePoints(int numSample, OdGePoint3dArray &pointArray) const
void getSamplePoints(int numSample, OdGePoint3dArray &pointArray, OdGeDoubleArray &paramArray) const
OdGePoint3d evalPoint(double param) const
void getSamplePoints(double fromParam, double toParam, double approxEps, OdGePoint3dArray &pointArray, OdGeDoubleArray *paramArray=NULL) const
bool getNormalPoint(const OdGePoint3d &point, OdGePointOnCurve3d &pntOnCrv, const OdGeTol &tol=OdGeContext::gTol) const
OdGeEntity3d * project(const OdGePlane &projectionPlane, const OdGeVector3d &projectDirection, const OdGeTol &tol=OdGeContext::gTol) const
double distanceTo(const OdGePoint3d &point, const OdGeTol &tol=OdGeContext::gTol) const
OdGeBoundBlock3d orthoBoundBlock(const OdGeInterval &range) const
OdGeBoundBlock3d orthoBoundBlock() const
OdGePoint3d closestPointTo(const OdGePoint3d &point, const OdGeTol &tol=OdGeContext::gTol) const
OdGeCurve3d & reverseParam()
double distanceTo(const OdGeCurve3d &curve, const OdGeTol &tol=OdGeContext::gTol) const
bool isDegenerate(OdGe::EntityId &degenerateType, const OdGeTol &tol=OdGeContext::gTol) const
bool isClosed(const OdGeTol &tol=OdGeContext::gTol) const
void appendSamplePoints(const OdGeInterval *paramInterval, double approxEps, OdGePoint3dArray &pointArray, OdGeDoubleArray *pParamArray=NULL) const
TD_USING(OdGeEntity3d::isOn)
double paramAtLength(double datumParam, double length, bool posParamDir=true, double tol=OdGeContext::gTol.equalPoint()) const
void evaluate(double param, int numDeriv, OdGeVector3d *values) const
void getClosestPointTo(const OdGePoint3d &point, OdGePointOnCurve3d &pntOnCrv, const OdGeTol &tol=OdGeContext::gTol) const
void getProjClosestPointTo(const OdGeCurve3d &curve, const OdGeVector3d &projectDirection, OdGePointOnCurve3d &pntOnThisCrv, OdGePointOnCurve3d &pntOnOtherCrv, const OdGeTol &tol=OdGeContext::gTol) const
void getProjClosestPointTo(const OdGePoint3d &point, const OdGeVector3d &projectDirection, OdGePointOnCurve3d &pntOnCrv, const OdGeTol &tol=OdGeContext::gTol) const
bool area(double startParam, double endParam, double &value, const OdGeTol &tol=OdGeContext::gTol) const
void getSamplePoints(const OdGeInterval *paramInterval, double approxEps, OdGePoint3dArray &pointArray, OdGeDoubleArray *pParamArray=NULL) const
bool setInterval(const OdGeInterval &interval)
OdGePoint3d evalPoint(double param, int numDeriv, OdGeVector3dArray &derivatives) const
double length(double tol=OdGeContext::gTol.equalPoint()) const
bool explode(OdGeCurve3dPtrArray &explodedCurves, OdGeIntArray &newExplodedCurves, const OdGeInterval *pInterval=NULL) const
bool isLinear(OdGeLine3d &line, const OdGeTol &tol=OdGeContext::gTol) const
OdGeCurve3d(const OdGeCurve3d &source)
void getTrimmedOffset(double distance, const OdGeVector3d &planeNormal, OdGeCurve3dPtrArray &offsetCurveList, OdGe::OffsetCrvExtType extensionType=OdGe::kFillet, const OdGeTol &tol=OdGeContext::gTol) const
OdGePoint3d closestPointTo(const OdGeCurve3d &curve, OdGePoint3d &pntOnOtherCrv, const OdGeTol &tol=OdGeContext::gTol) const
double paramOf(const OdGePoint3d &point, const OdGeTol &tol=OdGeContext::gTol) const
double paramOf(const OdGePoint3d &point, const OdGeInterval *range, const OdGeTol &tol=OdGeContext::gTol) const
bool isOn(const OdGePoint3d &point, const OdGeTol &tol=OdGeContext::gTol) const
OdGeEntity3d & operator=(const OdGeEntity3d &entity)
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