![]() |
Open CASCADE Technology Reference Manual 8.0.0
|
Provides an algorithm to compute a distribution of points on a 'C2' continuous curve. The algorithm respects a criterion of maximum deflection between the curve and the polygon that results from the computed points. Note: This algorithm is relatively time consuming. A GCPnts_QuasiUniformDeflection algorithm is quicker; it can also work with non-'C2' continuous curves, but it generates more points in the distribution. More...
#include <GCPnts_UniformDeflection.hxx>
Public Member Functions | |
| GCPnts_UniformDeflection () | |
| Constructs an empty algorithm. To define the problem to be solved, use the function Initialize. | |
| GCPnts_UniformDeflection (const Adaptor3d_Curve &theC, const double theDeflection, const bool theWithControl=true) | |
| Computes a uniform Deflection distribution of points on the curve. | |
| GCPnts_UniformDeflection (const Adaptor2d_Curve2d &theC, const double theDeflection, const bool theWithControl=true) | |
| Computes a uniform Deflection distribution of points on the curve. | |
| GCPnts_UniformDeflection (const Adaptor3d_Curve &theC, const double theDeflection, const double theU1, const double theU2, const bool theWithControl=true) | |
| Computes a Uniform Deflection distribution of points on a part of the curve. | |
| GCPnts_UniformDeflection (const Adaptor2d_Curve2d &theC, const double theDeflection, const double theU1, const double theU2, const bool theWithControl=true) | |
| Computes a Uniform Deflection distribution of points on a part of the curve. | |
| void | Initialize (const Adaptor3d_Curve &theC, const double theDeflection, const bool theWithControl=true) |
| Initialize the algorithms with 3D curve and deflection. | |
| void | Initialize (const Adaptor2d_Curve2d &theC, const double theDeflection, const bool theWithControl=true) |
| Initialize the algorithms with 2D curve and deflection. | |
| void | Initialize (const Adaptor3d_Curve &theC, const double theDeflection, const double theU1, const double theU2, const bool theWithControl=true) |
| Initialize the algorithms with 3D curve, deflection, parameter range. | |
| void | Initialize (const Adaptor2d_Curve2d &theC, const double theDeflection, const double theU1, const double theU2, const bool theWithControl=true) |
| Initialize the algorithms with curve, deflection, parameter range. This and the above methods initialize (or reinitialize) this algorithm and compute a distribution of points: | |
| bool | IsDone () const |
| Returns true if the computation was successful. IsDone is a protection against: | |
| int | NbPoints () const |
| Returns the number of points of the distribution computed by this algorithm. Exceptions StdFail_NotDone if this algorithm has not been initialized, or if the computation was not successful. | |
| double | Parameter (const int Index) const |
| Returns the parameter of the point of index Index in the distribution computed by this algorithm. Warning Index must be greater than or equal to 1, and less than or equal to the number of points of the distribution. However, pay particular attention as this condition is not checked by this function. Exceptions StdFail_NotDone if this algorithm has not been initialized, or if the computation was not successful. | |
| gp_Pnt | Value (const int Index) const |
| Returns the point of index Index in the distribution computed by this algorithm. Warning Index must be greater than or equal to 1, and less than or equal to the number of points of the distribution. However, pay particular attention as this condition is not checked by this function. Exceptions StdFAil_NotDone if this algorithm has not been initialized, or if the computation was not successful. | |
| double | Deflection () const |
| Returns the deflection between the curve and the polygon resulting from the points of the distribution computed by this algorithm. This value is the one given to the algorithm at the time of construction (or initialization). Exceptions StdFail_NotDone if this algorithm has not been initialized, or if the computation was not successful. | |
Provides an algorithm to compute a distribution of points on a 'C2' continuous curve. The algorithm respects a criterion of maximum deflection between the curve and the polygon that results from the computed points. Note: This algorithm is relatively time consuming. A GCPnts_QuasiUniformDeflection algorithm is quicker; it can also work with non-'C2' continuous curves, but it generates more points in the distribution.
| GCPnts_UniformDeflection::GCPnts_UniformDeflection | ( | ) |
Constructs an empty algorithm. To define the problem to be solved, use the function Initialize.
| GCPnts_UniformDeflection::GCPnts_UniformDeflection | ( | const Adaptor3d_Curve & | theC, |
| const double | theDeflection, | ||
| const bool | theWithControl = true ) |
Computes a uniform Deflection distribution of points on the curve.
| [in] | theC | input 3D curve |
| [in] | theDeflection | target deflection |
| [in] | theWithControl | when TRUE, the algorithm controls the estimate deflection |
| GCPnts_UniformDeflection::GCPnts_UniformDeflection | ( | const Adaptor2d_Curve2d & | theC, |
| const double | theDeflection, | ||
| const bool | theWithControl = true ) |
Computes a uniform Deflection distribution of points on the curve.
| [in] | theC | input 2D curve |
| [in] | theDeflection | target deflection |
| [in] | theWithControl | when TRUE, the algorithm controls the estimate deflection |
| GCPnts_UniformDeflection::GCPnts_UniformDeflection | ( | const Adaptor3d_Curve & | theC, |
| const double | theDeflection, | ||
| const double | theU1, | ||
| const double | theU2, | ||
| const bool | theWithControl = true ) |
Computes a Uniform Deflection distribution of points on a part of the curve.
| [in] | theC | input 3D curve |
| [in] | theDeflection | target deflection |
| [in] | theU1 | first parameter on curve |
| [in] | theU2 | last parameter on curve |
| [in] | theWithControl | when TRUE, the algorithm controls the estimate deflection |
| GCPnts_UniformDeflection::GCPnts_UniformDeflection | ( | const Adaptor2d_Curve2d & | theC, |
| const double | theDeflection, | ||
| const double | theU1, | ||
| const double | theU2, | ||
| const bool | theWithControl = true ) |
Computes a Uniform Deflection distribution of points on a part of the curve.
| [in] | theC | input 2D curve |
| [in] | theDeflection | target deflection |
| [in] | theU1 | first parameter on curve |
| [in] | theU2 | last parameter on curve |
| [in] | theWithControl | when TRUE, the algorithm controls the estimate deflection |
|
inline |
Returns the deflection between the curve and the polygon resulting from the points of the distribution computed by this algorithm. This value is the one given to the algorithm at the time of construction (or initialization). Exceptions StdFail_NotDone if this algorithm has not been initialized, or if the computation was not successful.
| void GCPnts_UniformDeflection::Initialize | ( | const Adaptor2d_Curve2d & | theC, |
| const double | theDeflection, | ||
| const bool | theWithControl = true ) |
Initialize the algorithms with 2D curve and deflection.
| void GCPnts_UniformDeflection::Initialize | ( | const Adaptor2d_Curve2d & | theC, |
| const double | theDeflection, | ||
| const double | theU1, | ||
| const double | theU2, | ||
| const bool | theWithControl = true ) |
Initialize the algorithms with curve, deflection, parameter range. This and the above methods initialize (or reinitialize) this algorithm and compute a distribution of points:
Warning
Warning theC is an adapted curve, i.e. an object which is an interface between:
| void GCPnts_UniformDeflection::Initialize | ( | const Adaptor3d_Curve & | theC, |
| const double | theDeflection, | ||
| const bool | theWithControl = true ) |
Initialize the algorithms with 3D curve and deflection.
| void GCPnts_UniformDeflection::Initialize | ( | const Adaptor3d_Curve & | theC, |
| const double | theDeflection, | ||
| const double | theU1, | ||
| const double | theU2, | ||
| const bool | theWithControl = true ) |
Initialize the algorithms with 3D curve, deflection, parameter range.
|
inline |
Returns true if the computation was successful. IsDone is a protection against:
|
inline |
Returns the number of points of the distribution computed by this algorithm. Exceptions StdFail_NotDone if this algorithm has not been initialized, or if the computation was not successful.
Returns the parameter of the point of index Index in the distribution computed by this algorithm. Warning Index must be greater than or equal to 1, and less than or equal to the number of points of the distribution. However, pay particular attention as this condition is not checked by this function. Exceptions StdFail_NotDone if this algorithm has not been initialized, or if the computation was not successful.
Returns the point of index Index in the distribution computed by this algorithm. Warning Index must be greater than or equal to 1, and less than or equal to the number of points of the distribution. However, pay particular attention as this condition is not checked by this function. Exceptions StdFAil_NotDone if this algorithm has not been initialized, or if the computation was not successful.