CFx SDK Documentation  2020SP3
DbCurve.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 
25 
26 
27 #ifndef OD_DBCURVE_H
28 #define OD_DBCURVE_H
29 
30 #include "TD_PackPush.h"
31 
32 #include "DbEntity.h"
33 #include "DbVertex.h"
34 
35 class OdDbSpline;
37 
38 class OdDbCurveImpl;
39 class OdDbCurve;
40 
53 {
54 public:
56 
58 
62  virtual bool isClosed() const;
63 
67  virtual bool isPeriodic() const;
68 
78  double& startParam) const = 0;
79 
89  double& endParam) const = 0;
90 
100  OdGePoint3d& startPoint) const = 0;
101 
111  OdGePoint3d& endPoint) const = 0;
112 
123  double param,
124  OdGePoint3d& pointOnCurve) const = 0;
125 
136  const OdGePoint3d& pointOnCurve,
137  double& param) const = 0;
138 
149  double param,
150  double& dist) const = 0;
151 
163  double dist,
164  double& param) const = 0;
165 
175  const OdGePoint3d& pointOnCurve,
176  double& dist)const;
177 
188  double dist,
189  OdGePoint3d& pointOnCurve) const;
190 
201  double param,
202  OdGeVector3d& firstDeriv) const = 0;
203 
214  const OdGePoint3d& pointOnCurve,
215  OdGeVector3d& firstDeriv) const;
216 
227  double param,
228  OdGeVector3d& secondDeriv) const;
229 
240  const OdGePoint3d& pointOnCurve,
241  OdGeVector3d& secondDeriv) const;
242 
254  const OdGePoint3d& givenPoint,
255  OdGePoint3d& pointOnCurve,
256  bool extend = false) const;
257 
276  const OdGePoint3d& givenPoint,
277  const OdGeVector3d& normal,
278  OdGePoint3d& pointOnCurve,
279  bool extend = false) const;
280 
281 
289  virtual OdResult getSpline (
290  OdDbSplinePtr* spline) const;
291 
300  virtual OdResult extend(
301  double param);
302 
312  virtual OdResult
313  extend(bool extendStart,
314  const OdGePoint3d& toPoint);
315 
323  virtual OdResult getArea(
324  double& area) const;
325 
335  virtual OdResult getOrthoProjectedCurve(const OdGePlane& projPlane,
336  OdDbCurvePtr* pProjCurve) const;
337 
348  virtual OdResult getProjectedCurve(const OdGePlane& projPlane,
349  const OdGeVector3d& projDirection, OdDbCurvePtr* pProjCurve) const;
350 
360  virtual OdResult getOffsetCurves(double offsetDistance,
361  OdRxObjectPtrArray& offsetCurves) const;
362 
375  const OdGeVector3d& normal, double offsetDistance,
376  OdRxObjectPtrArray& offsetCurves) const;
377 
388  OdRxObjectPtrArray& curveSegments) const;
389 
400  virtual OdResult getSplitCurves (const OdGePoint3dArray& points,
401  OdRxObjectPtrArray& curveSegments) const;
402 
404 
413  virtual OdResult getOdGeCurve ( OdGeCurve3d*& pGeCurve, const OdGeTol& tol = OdGeContext::gTol ) const;
414 
415 
428  static OdResult createFromOdGeCurve ( const OdGeCurve3d& geCurve, OdDbCurve*& pDbCurve,
429  OdGeVector3d *normal = NULL,
430  const OdGeTol& tol = OdGeContext::gTol );
431 
442  virtual OdResult setFromOdGeCurve ( const OdGeCurve3d& geCurve,
443  OdGeVector3d *normal = NULL,
444  const OdGeTol& tol = OdGeContext::gTol );
445 
446 
447  virtual OdInt32 findVertexIndex(const OdDbVertex* vert) const { return 0; }
448 };
449 
450 #include "TD_PackPop.h"
451 
452 #endif
453 
OdResult
OdResult
Definition: OdResult.h:29
OdDbCurve::getFirstDeriv
virtual OdResult getFirstDeriv(double param, OdGeVector3d &firstDeriv) const =0
OdGePlane
Definition: GePlane.h:45
OdDbCurve::getDistAtParam
virtual OdResult getDistAtParam(double param, double &dist) const =0
OdGeVector3d
Definition: GeVector3d.h:54
NULL
#define NULL
Definition: GsProperties.h:177
OdDbCurve::getStartPoint
virtual OdResult getStartPoint(OdGePoint3d &startPoint) const =0
OdDbCurve::getClosestPointTo
virtual OdResult getClosestPointTo(const OdGePoint3d &givenPoint, OdGePoint3d &pointOnCurve, bool extend=false) const
OdDbCurvePtr
OdSmartPtr< OdDbCurve > OdDbCurvePtr
Definition: DbCurve.h:39
OdDbCurve::getSecondDeriv
virtual OdResult getSecondDeriv(const OdGePoint3d &pointOnCurve, OdGeVector3d &secondDeriv) const
OdDbCurve::getStartParam
virtual OdResult getStartParam(double &startParam) const =0
tol
tol
Definition: DimVarDefs.h:2287
OdDbCurve::getFirstDeriv
virtual OdResult getFirstDeriv(const OdGePoint3d &pointOnCurve, OdGeVector3d &firstDeriv) const
OdDbCurve::extend
virtual OdResult extend(double param)
OdDbCurve::isClosed
virtual bool isClosed() const
OdDbCurve::ODDB_DECLARE_MEMBERS
ODDB_DECLARE_MEMBERS(OdDbCurve)
OdDbCurve::getEndPoint
virtual OdResult getEndPoint(OdGePoint3d &endPoint) const =0
OdDbSpline
Definition: DbSpline.h:44
OdDbCurve::getSplitCurves
virtual OdResult getSplitCurves(const OdGePoint3dArray &points, OdRxObjectPtrArray &curveSegments) const
OdDbCurve::getSecondDeriv
virtual OdResult getSecondDeriv(double param, OdGeVector3d &secondDeriv) const
OdArray< OdRxObjectPtr >
TD_PackPop.h
OdDbCurve::getOffsetCurves
virtual OdResult getOffsetCurves(double offsetDistance, OdRxObjectPtrArray &offsetCurves) const
OdDbCurve::extend
virtual OdResult extend(bool extendStart, const OdGePoint3d &toPoint)
OdDbCurve::getEndParam
virtual OdResult getEndParam(double &endParam) const =0
OdDbCurve::isPeriodic
virtual bool isPeriodic() const
OdDbCurve::getDistAtPoint
virtual OdResult getDistAtPoint(const OdGePoint3d &pointOnCurve, double &dist) const
OdDbCurve::getOdGeCurve
virtual OdResult getOdGeCurve(OdGeCurve3d *&pGeCurve, const OdGeTol &tol=OdGeContext::gTol) const
OdDbCurve::getSpline
virtual OdResult getSpline(OdDbSplinePtr *spline) const
OdSmartPtr
Definition: SmartPtr.h:58
OdDbCurve::reverseCurve
virtual OdResult reverseCurve()
OdGePoint3d
Definition: GePoint3d.h:55
OdDbCurve::getClosestPointTo
virtual OdResult getClosestPointTo(const OdGePoint3d &givenPoint, const OdGeVector3d &normal, OdGePoint3d &pointOnCurve, bool extend=false) const
DbEntity.h
OdInt32
int OdInt32
Definition: OdPlatformSettings.h:782
OdDbCurve::getParamAtPoint
virtual OdResult getParamAtPoint(const OdGePoint3d &pointOnCurve, double &param) const =0
TD_PackPush.h
OdDbVertex
Definition: DbVertex.h:56
OdDbCurve::getPointAtDist
virtual OdResult getPointAtDist(double dist, OdGePoint3d &pointOnCurve) const
OdDbSplinePtr
OdSmartPtr< OdDbSpline > OdDbSplinePtr
Definition: DbCurve.h:35
OdDbCurve::findVertexIndex
virtual OdInt32 findVertexIndex(const OdDbVertex *vert) const
Definition: DbCurve.h:447
params
GLenum GLint * params
Definition: gles2_ext.h:184
OdDbEntity
Definition: DbEntity.h:90
OdDbCurve::setFromOdGeCurve
virtual OdResult setFromOdGeCurve(const OdGeCurve3d &geCurve, OdGeVector3d *normal=NULL, const OdGeTol &tol=OdGeContext::gTol)
OdDbCurve::createFromOdGeCurve
static OdResult createFromOdGeCurve(const OdGeCurve3d &geCurve, OdDbCurve *&pDbCurve, OdGeVector3d *normal=NULL, const OdGeTol &tol=OdGeContext::gTol)
OdGeCurve3d
Definition: GeCurve3d.h:56
OdDbCurve::getOrthoProjectedCurve
virtual OdResult getOrthoProjectedCurve(const OdGePlane &projPlane, OdDbCurvePtr *pProjCurve) const
OdDbCurve
Definition: DbCurve.h:53
DbVertex.h
OdGeContext::gTol
static GE_STATIC_EXPORT OdGeTol gTol
Definition: GeGbl.h:60
OdDbCurve::getParamAtDist
virtual OdResult getParamAtDist(double dist, double &param) const =0
OdDbCurve::getOffsetCurvesGivenPlaneNormal
virtual OdResult getOffsetCurvesGivenPlaneNormal(const OdGeVector3d &normal, double offsetDistance, OdRxObjectPtrArray &offsetCurves) const
OdDbCurve::OdDbCurve
OdDbCurve()
TOOLKIT_EXPORT
#define TOOLKIT_EXPORT
Definition: DbExport.h:40
OdGeTol
Definition: GeTol.h:49
OdDbCurve::getPointAtParam
virtual OdResult getPointAtParam(double param, OdGePoint3d &pointOnCurve) const =0
OdDbCurve::getArea
virtual OdResult getArea(double &area) const
OdDbCurve::getSplitCurves
virtual OdResult getSplitCurves(const OdGeDoubleArray &params, OdRxObjectPtrArray &curveSegments) const
OdDbCurve::getProjectedCurve
virtual OdResult getProjectedCurve(const OdGePlane &projPlane, const OdGeVector3d &projDirection, OdDbCurvePtr *pProjCurve) const