This tool provides a method for computing pcurve by projecting 3d curve onto a surface. Projection is done by 23 or more points (this number is changed for B-Splines according to the following rule: the total number of the points is not less than number of spans * (degree + 1); it is increased recursively starting with 23 and is added with 22 until the condition is fulfilled). Isoparametric cases (if curve corresponds to U=const or V=const on the surface) are recognized with the given precision.
More...
|
| | ShapeConstruct_ProjectCurveOnSurface () |
| | Empty constructor.
|
| |
| virtual void | Init (const occ::handle< Geom_Surface > &theSurf, const double thePreci) |
| | Initializes the object with all necessary parameters, i.e. surface and precision.
|
| |
| virtual void | Init (const occ::handle< ShapeAnalysis_Surface > &theSurf, const double thePreci) |
| | Initializes the object with all necessary parameters, i.e. surface and precision.
|
| |
| void | SetSurface (const occ::handle< Geom_Surface > &theSurf) |
| | Loads a surface (in the form of Geom_Surface) to project on.
|
| |
| void | SetSurface (const occ::handle< ShapeAnalysis_Surface > &theSurf) |
| | Loads a surface (in the form of ShapeAnalysis_Surface) to project on.
|
| |
| void | SetPrecision (const double thePreci) |
| | Sets value for current precision.
|
| |
| int & | AdjustOverDegenMode () |
| | Returns (modifiable) the flag specifying to which side of parametrical space adjust part of pcurve which lies on seam. This is required in very rare case when 3d curve which is to be projected goes partly along the seam on the closed surface with singularity (e.g. sphere), goes through the degenerated point and partly lies on internal area of surface.
|
| |
| bool | Status (const ShapeExtend_Status theStatus) const |
| | Returns the status of last Perform.
|
| |
| virtual bool | Perform (const occ::handle< Geom_Curve > &theC3D, const double theFirst, const double theLast, occ::handle< Geom2d_Curve > &theC2D, const double theTolFirst=Precision::Confusion(), const double theTolLast=Precision::Confusion()) |
| | Computes the projection of 3d curve onto a surface using the specialized algorithm. Returns False if projector fails, otherwise, if pcurve computed successfully, returns True. The output curve 2D is guaranteed to be same-parameter with input curve 3D on the interval [theFirst, theLast]. If the output curve lies on a direct line the infinite line is returned, in the case same-parameter condition is satisfied.
|
| |
Public Member Functions inherited from Standard_Transient |
| | Standard_Transient () |
| | Empty constructor.
|
| |
| | Standard_Transient (const Standard_Transient &) |
| | Copy constructor – does nothing.
|
| |
| Standard_Transient & | operator= (const Standard_Transient &) |
| | Assignment operator, needed to avoid copying reference counter.
|
| |
| virtual | ~Standard_Transient ()=default |
| | Destructor must be virtual.
|
| |
| virtual const opencascade::handle< Standard_Type > & | DynamicType () const |
| | Returns a type descriptor about this object.
|
| |
| bool | IsInstance (const opencascade::handle< Standard_Type > &theType) const |
| | Returns a true value if this is an instance of Type.
|
| |
| bool | IsInstance (const char *const theTypeName) const |
| | Returns a true value if this is an instance of TypeName.
|
| |
| bool | IsKind (const opencascade::handle< Standard_Type > &theType) const |
| | Returns true if this is an instance of Type or an instance of any class that inherits from Type. Note that multiple inheritance is not supported by OCCT RTTI mechanism.
|
| |
| bool | IsKind (const char *const theTypeName) const |
| | Returns true if this is an instance of TypeName or an instance of any class that inherits from TypeName. Note that multiple inheritance is not supported by OCCT RTTI mechanism.
|
| |
| Standard_Transient * | This () const |
| | Returns non-const pointer to this object (like const_cast). For protection against creating handle to objects allocated in stack or call from constructor, it will raise exception Standard_ProgramError if reference counter is zero.
|
| |
| int | GetRefCount () const noexcept |
| | Get the reference counter of this object.
|
| |
| void | IncrementRefCounter () noexcept |
| | Increments the reference counter of this object. Uses relaxed memory ordering since incrementing only requires atomicity, not synchronization with other memory operations.
|
| |
| int | DecrementRefCounter () noexcept |
| | Decrements the reference counter of this object; returns the decremented value. Uses release ordering for the decrement to ensure all writes to the object are visible before the count reaches zero. An acquire fence is added only when the count reaches zero, ensuring proper synchronization before deletion. This is more efficient than using acq_rel for every decrement.
|
| |
| virtual void | Delete () const |
| | Memory deallocator for transient classes.
|
| |
|
| occ::handle< Geom2d_Curve > | getLine (const ArrayOfPnt &thePoints, const ArrayOfReal &theParams, ArrayOfPnt2d &thePoints2d, const double theTol, bool &theIsRecompute, bool &theIsFromCache) const |
| | Try to approximate 3D curve by Geom2d_Line or Geom2d_BSplineCurve with degree 1 with specified tolerance.
|
| |
| bool | PerformByProjLib (const occ::handle< Geom_Curve > &theC3D, const double theFirst, const double theLast, occ::handle< Geom2d_Curve > &theC2D) |
| | Computes the projection of 3d curve onto a surface using the standard algorithm from ProjLib. Returns False if standard projector fails or raises an exception or cuts the curve by parametrical bounds of the surface. Else, if pcurve computed successfully, returns True.
|
| |
| occ::handle< Geom2d_Curve > | projectAnalytic (const occ::handle< Geom_Curve > &theC3D) const |
| | Performs analytical projection for special cases (plane surfaces)
|
| |
| bool | approxPCurve (const int theNbPnt, const occ::handle< Geom_Curve > &theC3D, const double theTolFirst, const double theTolLast, ArrayOfPnt &thePoints, ArrayOfReal &theParams, ArrayOfPnt2d &thePoints2d, occ::handle< Geom2d_Curve > &theC2D) |
| | Main approximation routine for pcurve computation.
|
| |
| void | correctExtremity (const occ::handle< Geom_Curve > &theC3D, const ArrayOfReal &theParams, ArrayOfPnt2d &thePoints2d, const bool theIsFirstPoint, const gp_Pnt2d &thePointOnIsoLine, const bool theIsUIso) |
| | Corrects extremity point near singularity.
|
| |
| void | insertAdditionalPointOrAdjust (bool &theToAdjust, const int theIndCoord, const double thePeriod, const double theTolOnPeriod, double &theCurCoord, const double thePrevCoord, const occ::handle< Geom_Curve > &theC3D, int &theIndex, ArrayOfPnt &thePoints, ArrayOfReal &theParams, ArrayOfPnt2d &thePoints2d) |
| | Inserts additional point or adjusts coordinate to handle period jumps.
|
| |
| occ::handle< Geom2d_Curve > | interpolatePCurve (const int theNbPnt, const ArrayOfPnt2d &thePoints2d, const ArrayOfReal &theParams) const |
| | Interpolates 2D curve from points.
|
| |
| occ::handle< Geom2d_Curve > | approximatePCurve (const ArrayOfPnt2d &thePoints2d, const ArrayOfReal &theParams) const |
| | Approximates 2D curve from points.
|
| |
| void | checkPoints (ArrayOfPnt &thePoints, ArrayOfReal &theParams, double &thePreci) const |
| | Checks and removes coincident 3D points.
|
| |
| void | checkPoints2d (ArrayOfPnt2d &thePoints2d, ArrayOfReal &theParams, double &thePreci) const |
| | Checks and removes coincident 2D points.
|
| |
| bool | isAnIsoparametric (const int theNbPnt, const ArrayOfPnt &thePoints, const ArrayOfReal &theParams, bool &theIsTypeU, bool &theP1OnIso, gp_Pnt2d &theValueP1, bool &theP2OnIso, gp_Pnt2d &theValueP2, bool &theIsoPar2d3d, occ::handle< Geom_Curve > &theCIso, double &theT1, double &theT2, ArrayOfReal &theParamsOut) const |
| | Detects if curve is isoparametric (U=const or V=const)
|
| |
This tool provides a method for computing pcurve by projecting 3d curve onto a surface. Projection is done by 23 or more points (this number is changed for B-Splines according to the following rule: the total number of the points is not less than number of spans * (degree + 1); it is increased recursively starting with 23 and is added with 22 until the condition is fulfilled). Isoparametric cases (if curve corresponds to U=const or V=const on the surface) are recognized with the given precision.
| int & ShapeConstruct_ProjectCurveOnSurface::AdjustOverDegenMode |
( |
| ) |
|
Returns (modifiable) the flag specifying to which side of parametrical space adjust part of pcurve which lies on seam. This is required in very rare case when 3d curve which is to be projected goes partly along the seam on the closed surface with singularity (e.g. sphere), goes through the degenerated point and partly lies on internal area of surface.
If this flag is True, the seam part of such curve will be adjusted to the left side of parametric space (on sphere U=0), else to the right side (on sphere U=2*PI) Default value is True
- Returns
- modifiable reference to the adjustment flag