Open CASCADE Technology 7.8.2.dev
ProjLib_ComputeApproxOnPolarSurface Class Reference

Approximate the projection of a 3d curve on an polar surface and stores the result in Approx. The result is a 2d curve. The evaluation of the current point of the 2d curve is done with the evaluation of the extrema P3d - Surface. For approximation some parameters are used, including required tolerance of approximation. Tolerance is maximal possible value of 3d deviation of 3d projection of projected curve from "exact" 3d projection. Since algorithm searches 2d curve on surface, required 2d tolerance is computed from 3d tolerance with help of U,V resolutions of surface. 3d and 2d tolerances have sense only for curves on surface, it defines precision of projecting and approximation and have nothing to do with distance between the projected curve and the surface. More...

#include <ProjLib_ComputeApproxOnPolarSurface.hxx>

Public Member Functions

 ProjLib_ComputeApproxOnPolarSurface ()
 Empty constructor, it only sets some initial values for class fields.
 
 ProjLib_ComputeApproxOnPolarSurface (const Handle< Adaptor3d_Curve > &C, const Handle< Adaptor3d_Surface > &S, const Standard_Real Tol=1.0e-4)
 Constructor, which performs projecting.
 
 ProjLib_ComputeApproxOnPolarSurface (const Handle< Adaptor2d_Curve2d > &InitCurve2d, const Handle< Adaptor3d_Curve > &C, const Handle< Adaptor3d_Surface > &S, const Standard_Real Tol)
 Constructor, which performs projecting, using initial curve 2d InitCurve2d, which is any rough approximation of result curve. Parameter Tol is 3d tolerance of approximation.
 
 ProjLib_ComputeApproxOnPolarSurface (const Handle< Adaptor2d_Curve2d > &InitCurve2d, const Handle< Adaptor2d_Curve2d > &InitCurve2dBis, const Handle< Adaptor3d_Curve > &C, const Handle< Adaptor3d_Surface > &S, const Standard_Real Tol)
 Constructor, which performs projecting, using two initial curves 2d: InitCurve2d and InitCurve2dBis that are any rough approximations of result curves. This constructor is used to get two pcurves for seem edge. Parameter Tol is 3d tolerance of approximation.
 
void SetDegree (const Standard_Integer theDegMin, const Standard_Integer theDegMax)
 Set min and max possible degree of result BSpline curve2d, which is got by approximation. If theDegMin/Max < 0, algorithm uses values min = 2, max = 8.
 
void SetMaxSegments (const Standard_Integer theMaxSegments)
 Set the parameter, which defines maximal value of parametric intervals the projected curve can be cut for approximation. If theMaxSegments < 0, algorithm uses default value = 1000.
 
void SetBndPnt (const AppParCurves_Constraint theBndPnt)
 Set the parameter, which defines type of boundary condition between segments during approximation. It can be AppParCurves_PassPoint or AppParCurves_TangencyPoint. Default value is AppParCurves_TangencyPoint.
 
void SetMaxDist (const Standard_Real theMaxDist)
 Set the parameter, which defines maximal possible distance between projected curve and surface. It is used only for projecting on not analytical surfaces. If theMaxDist < 0, algorithm uses default value 100.*Tolerance. If real distance between curve and surface more then theMaxDist, algorithm stops working.
 
void SetTolerance (const Standard_Real theTolerance)
 Set the tolerance used to project the curve on the surface. Default value is Precision::Approximation().
 
void Perform (const Handle< Adaptor3d_Curve > &C, const Handle< Adaptor3d_Surface > &S)
 Method, which performs projecting, using default values of parameters or they must be set by corresponding methods before using.
 
Handle< Geom2d_BSplineCurvePerform (const Handle< Adaptor2d_Curve2d > &InitCurve2d, const Handle< Adaptor3d_Curve > &C, const Handle< Adaptor3d_Surface > &S)
 Method, which performs projecting, using default values of parameters or they must be set by corresponding methods before using. Parameter InitCurve2d is any rough estimation of 2d result curve.
 
Handle< Adaptor2d_Curve2dBuildInitialCurve2d (const Handle< Adaptor3d_Curve > &Curve, const Handle< Adaptor3d_Surface > &S)
 Builds initial 2d curve as BSpline with degree = 1 using Extrema algorithm. Method is used in method Perform(...).
 
Handle< Geom2d_BSplineCurveProjectUsingInitialCurve2d (const Handle< Adaptor3d_Curve > &Curve, const Handle< Adaptor3d_Surface > &S, const Handle< Adaptor2d_Curve2d > &InitCurve2d)
 Method, which performs projecting. Method is used in method Perform(...).
 
Handle< Geom2d_BSplineCurveBSpline () const
 Returns result curve 2d.
 
Handle< Geom2d_CurveCurve2d () const
 Returns second 2d curve.
 
Standard_Boolean IsDone () const
 
Standard_Real Tolerance () const
 returns the reached Tolerance.
 

Detailed Description

Approximate the projection of a 3d curve on an polar surface and stores the result in Approx. The result is a 2d curve. The evaluation of the current point of the 2d curve is done with the evaluation of the extrema P3d - Surface. For approximation some parameters are used, including required tolerance of approximation. Tolerance is maximal possible value of 3d deviation of 3d projection of projected curve from "exact" 3d projection. Since algorithm searches 2d curve on surface, required 2d tolerance is computed from 3d tolerance with help of U,V resolutions of surface. 3d and 2d tolerances have sense only for curves on surface, it defines precision of projecting and approximation and have nothing to do with distance between the projected curve and the surface.

Constructor & Destructor Documentation

◆ ProjLib_ComputeApproxOnPolarSurface() [1/4]

ProjLib_ComputeApproxOnPolarSurface::ProjLib_ComputeApproxOnPolarSurface ( )

Empty constructor, it only sets some initial values for class fields.

◆ ProjLib_ComputeApproxOnPolarSurface() [2/4]

ProjLib_ComputeApproxOnPolarSurface::ProjLib_ComputeApproxOnPolarSurface ( const Handle< Adaptor3d_Curve > & C,
const Handle< Adaptor3d_Surface > & S,
const Standard_Real Tol = 1.0e-4 )

Constructor, which performs projecting.

◆ ProjLib_ComputeApproxOnPolarSurface() [3/4]

ProjLib_ComputeApproxOnPolarSurface::ProjLib_ComputeApproxOnPolarSurface ( const Handle< Adaptor2d_Curve2d > & InitCurve2d,
const Handle< Adaptor3d_Curve > & C,
const Handle< Adaptor3d_Surface > & S,
const Standard_Real Tol )

Constructor, which performs projecting, using initial curve 2d InitCurve2d, which is any rough approximation of result curve. Parameter Tol is 3d tolerance of approximation.

◆ ProjLib_ComputeApproxOnPolarSurface() [4/4]

ProjLib_ComputeApproxOnPolarSurface::ProjLib_ComputeApproxOnPolarSurface ( const Handle< Adaptor2d_Curve2d > & InitCurve2d,
const Handle< Adaptor2d_Curve2d > & InitCurve2dBis,
const Handle< Adaptor3d_Curve > & C,
const Handle< Adaptor3d_Surface > & S,
const Standard_Real Tol )

Constructor, which performs projecting, using two initial curves 2d: InitCurve2d and InitCurve2dBis that are any rough approximations of result curves. This constructor is used to get two pcurves for seem edge. Parameter Tol is 3d tolerance of approximation.

Member Function Documentation

◆ BSpline()

Handle< Geom2d_BSplineCurve > ProjLib_ComputeApproxOnPolarSurface::BSpline ( ) const

Returns result curve 2d.

◆ BuildInitialCurve2d()

Handle< Adaptor2d_Curve2d > ProjLib_ComputeApproxOnPolarSurface::BuildInitialCurve2d ( const Handle< Adaptor3d_Curve > & Curve,
const Handle< Adaptor3d_Surface > & S )

Builds initial 2d curve as BSpline with degree = 1 using Extrema algorithm. Method is used in method Perform(...).

◆ Curve2d()

Handle< Geom2d_Curve > ProjLib_ComputeApproxOnPolarSurface::Curve2d ( ) const

Returns second 2d curve.

◆ IsDone()

Standard_Boolean ProjLib_ComputeApproxOnPolarSurface::IsDone ( ) const

◆ Perform() [1/2]

Handle< Geom2d_BSplineCurve > ProjLib_ComputeApproxOnPolarSurface::Perform ( const Handle< Adaptor2d_Curve2d > & InitCurve2d,
const Handle< Adaptor3d_Curve > & C,
const Handle< Adaptor3d_Surface > & S )

Method, which performs projecting, using default values of parameters or they must be set by corresponding methods before using. Parameter InitCurve2d is any rough estimation of 2d result curve.

◆ Perform() [2/2]

void ProjLib_ComputeApproxOnPolarSurface::Perform ( const Handle< Adaptor3d_Curve > & C,
const Handle< Adaptor3d_Surface > & S )

Method, which performs projecting, using default values of parameters or they must be set by corresponding methods before using.

◆ ProjectUsingInitialCurve2d()

Handle< Geom2d_BSplineCurve > ProjLib_ComputeApproxOnPolarSurface::ProjectUsingInitialCurve2d ( const Handle< Adaptor3d_Curve > & Curve,
const Handle< Adaptor3d_Surface > & S,
const Handle< Adaptor2d_Curve2d > & InitCurve2d )

Method, which performs projecting. Method is used in method Perform(...).

◆ SetBndPnt()

void ProjLib_ComputeApproxOnPolarSurface::SetBndPnt ( const AppParCurves_Constraint theBndPnt)

Set the parameter, which defines type of boundary condition between segments during approximation. It can be AppParCurves_PassPoint or AppParCurves_TangencyPoint. Default value is AppParCurves_TangencyPoint.

◆ SetDegree()

void ProjLib_ComputeApproxOnPolarSurface::SetDegree ( const Standard_Integer theDegMin,
const Standard_Integer theDegMax )

Set min and max possible degree of result BSpline curve2d, which is got by approximation. If theDegMin/Max < 0, algorithm uses values min = 2, max = 8.

◆ SetMaxDist()

void ProjLib_ComputeApproxOnPolarSurface::SetMaxDist ( const Standard_Real theMaxDist)

Set the parameter, which defines maximal possible distance between projected curve and surface. It is used only for projecting on not analytical surfaces. If theMaxDist < 0, algorithm uses default value 100.*Tolerance. If real distance between curve and surface more then theMaxDist, algorithm stops working.

◆ SetMaxSegments()

void ProjLib_ComputeApproxOnPolarSurface::SetMaxSegments ( const Standard_Integer theMaxSegments)

Set the parameter, which defines maximal value of parametric intervals the projected curve can be cut for approximation. If theMaxSegments < 0, algorithm uses default value = 1000.

◆ SetTolerance()

void ProjLib_ComputeApproxOnPolarSurface::SetTolerance ( const Standard_Real theTolerance)

Set the tolerance used to project the curve on the surface. Default value is Precision::Approximation().

◆ Tolerance()

Standard_Real ProjLib_ComputeApproxOnPolarSurface::Tolerance ( ) const

returns the reached Tolerance.


The documentation for this class was generated from the following file: