OCCT 8.0.1
OCCT documentation

Search guides and API reference

Enter at least two characters.

    Open CASCADE Technology Reference Manual 8.0.1
    Convert_ConicToBSplineCurve Class Reference

    Root class for algorithms which convert a conic curve into a BSpline curve (CircleToBSplineCurve, EllipseToBSplineCurve, HyperbolaToBSplineCurve, ParabolaToBSplineCurve). These algorithms all work on 2D curves from the gp package and compute all the data needed to construct a BSpline curve equivalent to the conic curve. This data consists of: More...

    #include <Convert_ConicToBSplineCurve.hxx>

    Inheritance diagram for Convert_ConicToBSplineCurve:

    Public Member Functions

    int Degree () const
     Returns the degree of the BSpline curve whose data is computed in this framework.
    int NbPoles () const
     Returns the number of poles of the BSpline curve whose data is computed in this framework.
    int NbKnots () const
     Returns the number of knots of the BSpline curve whose data is computed in this framework.
    bool IsPeriodic () const
     Returns true if the BSpline curve whose data is computed in this framework is periodic.
    gp_Pnt2d Pole (const int theIndex) const
     Returns the pole of index Index to the poles table of the BSpline curve whose data is computed in this framework.
    double Weight (const int theIndex) const
     Returns the weight of the pole of index Index to the poles table of the BSpline curve whose data is computed in this framework.
    double Knot (const int theIndex) const
     Returns the knot of index Index to the knots table of the BSpline curve whose data is computed in this framework.
    int Multiplicity (const int theIndex) const
     Returns the multiplicity of the knot of index Index to the knots table of the BSpline curve whose data is computed in this framework.
    const NCollection_Array1< gp_Pnt2d > & Poles () const
     Returns the poles of the BSpline curve.
    const NCollection_Array1< double > & Weights () const
     Returns the weights of the BSpline curve.
    const NCollection_Array1< double > & Knots () const
     Returns the knots of the BSpline curve.
    const NCollection_Array1< int > & Multiplicities () const
     Returns the multiplicities of the BSpline curve.
    void BuildCosAndSin (const Convert_ParameterisationType theParametrisation, occ::handle< NCollection_HArray1< double > > &theCosNumerator, occ::handle< NCollection_HArray1< double > > &theSinNumerator, occ::handle< NCollection_HArray1< double > > &theDenominator, int &theDegree, occ::handle< NCollection_HArray1< double > > &theKnots, occ::handle< NCollection_HArray1< int > > &theMults) const
     Legacy API returning handle arrays for compatibility.
    void BuildCosAndSin (const Convert_ParameterisationType theParametrisation, const double theUFirst, const double theULast, occ::handle< NCollection_HArray1< double > > &theCosNumerator, occ::handle< NCollection_HArray1< double > > &theSinNumerator, occ::handle< NCollection_HArray1< double > > &theDenominator, int &theDegree, occ::handle< NCollection_HArray1< double > > &theKnots, occ::handle< NCollection_HArray1< int > > &theMults) const
     Legacy API returning handle arrays for compatibility.

    Protected Member Functions

     Convert_ConicToBSplineCurve (const int theNumberOfPoles, const int theNumberOfKnots, const int theDegree)
    void BuildCosAndSin (const Convert_ParameterisationType theParametrisation, NCollection_Array1< double > &theCosNumerator, NCollection_Array1< double > &theSinNumerator, NCollection_Array1< double > &theDenominator, int &theDegree, NCollection_Array1< double > &theKnots, NCollection_Array1< int > &theMults) const
    void BuildCosAndSin (const Convert_ParameterisationType theParametrisation, const double theUFirst, const double theULast, NCollection_Array1< double > &theCosNumerator, NCollection_Array1< double > &theSinNumerator, NCollection_Array1< double > &theDenominator, int &theDegree, NCollection_Array1< double > &theKnots, NCollection_Array1< int > &theMults) const

    Protected Attributes

    NCollection_Array1< gp_Pnt2d > myPoles
    NCollection_Array1< double > myWeights
    NCollection_Array1< double > myKnots
    NCollection_Array1< int > myMults
    int myDegree = 0
    bool myIsPeriodic = false

    Detailed Description

    Root class for algorithms which convert a conic curve into a BSpline curve (CircleToBSplineCurve, EllipseToBSplineCurve, HyperbolaToBSplineCurve, ParabolaToBSplineCurve). These algorithms all work on 2D curves from the gp package and compute all the data needed to construct a BSpline curve equivalent to the conic curve. This data consists of:

    • the degree of the curve,
    • the periodic characteristics of the curve,
    • a poles table with associated weights,
    • a knots table with associated multiplicities. The abstract class ConicToBSplineCurve provides a framework for storing and consulting this computed data.

    Constructor & Destructor Documentation

    ◆ Convert_ConicToBSplineCurve()

    Convert_ConicToBSplineCurve::Convert_ConicToBSplineCurve ( const int theNumberOfPoles,
    const int theNumberOfKnots,
    const int theDegree )
    protected

    Member Function Documentation

    ◆ BuildCosAndSin() [1/4]

    void Convert_ConicToBSplineCurve::BuildCosAndSin ( const Convert_ParameterisationType theParametrisation,
    const double theUFirst,
    const double theULast,
    NCollection_Array1< double > & theCosNumerator,
    NCollection_Array1< double > & theSinNumerator,
    NCollection_Array1< double > & theDenominator,
    int & theDegree,
    NCollection_Array1< double > & theKnots,
    NCollection_Array1< int > & theMults ) const
    protected

    ◆ BuildCosAndSin() [2/4]

    void Convert_ConicToBSplineCurve::BuildCosAndSin ( const Convert_ParameterisationType theParametrisation,
    const double theUFirst,
    const double theULast,
    occ::handle< NCollection_HArray1< double > > & theCosNumerator,
    occ::handle< NCollection_HArray1< double > > & theSinNumerator,
    occ::handle< NCollection_HArray1< double > > & theDenominator,
    int & theDegree,
    occ::handle< NCollection_HArray1< double > > & theKnots,
    occ::handle< NCollection_HArray1< int > > & theMults ) const

    Legacy API returning handle arrays for compatibility.

    Deprecated
    ("Use array-based BuildCosAndSin() overload instead")

    ◆ BuildCosAndSin() [3/4]

    void Convert_ConicToBSplineCurve::BuildCosAndSin ( const Convert_ParameterisationType theParametrisation,
    NCollection_Array1< double > & theCosNumerator,
    NCollection_Array1< double > & theSinNumerator,
    NCollection_Array1< double > & theDenominator,
    int & theDegree,
    NCollection_Array1< double > & theKnots,
    NCollection_Array1< int > & theMults ) const
    protected

    ◆ BuildCosAndSin() [4/4]

    void Convert_ConicToBSplineCurve::BuildCosAndSin ( const Convert_ParameterisationType theParametrisation,
    occ::handle< NCollection_HArray1< double > > & theCosNumerator,
    occ::handle< NCollection_HArray1< double > > & theSinNumerator,
    occ::handle< NCollection_HArray1< double > > & theDenominator,
    int & theDegree,
    occ::handle< NCollection_HArray1< double > > & theKnots,
    occ::handle< NCollection_HArray1< int > > & theMults ) const

    Legacy API returning handle arrays for compatibility.

    Deprecated
    ("Use array-based BuildCosAndSin() overload instead")

    ◆ Degree()

    int Convert_ConicToBSplineCurve::Degree ( ) const
    nodiscard

    Returns the degree of the BSpline curve whose data is computed in this framework.

    ◆ IsPeriodic()

    bool Convert_ConicToBSplineCurve::IsPeriodic ( ) const
    nodiscard

    Returns true if the BSpline curve whose data is computed in this framework is periodic.

    ◆ Knot()

    double Convert_ConicToBSplineCurve::Knot ( const int theIndex) const

    Returns the knot of index Index to the knots table of the BSpline curve whose data is computed in this framework.

    Parameters
    [in]theIndexknot index (1-based)
    Returns
    knot at the given index
    Exceptions
    Standard_OutOfRangeif theIndex is out of bounds
    Deprecated
    ("Use Knots() batch accessor instead")

    ◆ Knots()

    const NCollection_Array1< double > & Convert_ConicToBSplineCurve::Knots ( ) const
    nodiscard

    Returns the knots of the BSpline curve.

    ◆ Multiplicities()

    const NCollection_Array1< int > & Convert_ConicToBSplineCurve::Multiplicities ( ) const
    nodiscard

    Returns the multiplicities of the BSpline curve.

    ◆ Multiplicity()

    int Convert_ConicToBSplineCurve::Multiplicity ( const int theIndex) const

    Returns the multiplicity of the knot of index Index to the knots table of the BSpline curve whose data is computed in this framework.

    Parameters
    [in]theIndexmultiplicity index (1-based)
    Returns
    multiplicity at the given index
    Exceptions
    Standard_OutOfRangeif theIndex is out of bounds
    Deprecated
    ("Use Multiplicities() batch accessor instead")

    ◆ NbKnots()

    int Convert_ConicToBSplineCurve::NbKnots ( ) const
    nodiscard

    Returns the number of knots of the BSpline curve whose data is computed in this framework.

    ◆ NbPoles()

    int Convert_ConicToBSplineCurve::NbPoles ( ) const
    nodiscard

    Returns the number of poles of the BSpline curve whose data is computed in this framework.

    ◆ Pole()

    gp_Pnt2d Convert_ConicToBSplineCurve::Pole ( const int theIndex) const

    Returns the pole of index Index to the poles table of the BSpline curve whose data is computed in this framework.

    Parameters
    [in]theIndexpole index (1-based)
    Returns
    pole at the given index
    Exceptions
    Standard_OutOfRangeif theIndex is out of bounds
    Deprecated
    ("Use Poles() batch accessor instead")

    ◆ Poles()

    const NCollection_Array1< gp_Pnt2d > & Convert_ConicToBSplineCurve::Poles ( ) const
    nodiscard

    Returns the poles of the BSpline curve.

    ◆ Weight()

    double Convert_ConicToBSplineCurve::Weight ( const int theIndex) const

    Returns the weight of the pole of index Index to the poles table of the BSpline curve whose data is computed in this framework.

    Parameters
    [in]theIndexweight index (1-based)
    Returns
    weight at the given index
    Exceptions
    Standard_OutOfRangeif theIndex is out of bounds
    Deprecated
    ("Use Weights() batch accessor instead")

    ◆ Weights()

    const NCollection_Array1< double > & Convert_ConicToBSplineCurve::Weights ( ) const
    nodiscard

    Returns the weights of the BSpline curve.

    Field Documentation

    ◆ myDegree

    int Convert_ConicToBSplineCurve::myDegree = 0
    protected

    ◆ myIsPeriodic

    bool Convert_ConicToBSplineCurve::myIsPeriodic = false
    protected

    ◆ myKnots

    NCollection_Array1<double> Convert_ConicToBSplineCurve::myKnots
    protected

    ◆ myMults

    NCollection_Array1<int> Convert_ConicToBSplineCurve::myMults
    protected

    ◆ myPoles

    NCollection_Array1<gp_Pnt2d> Convert_ConicToBSplineCurve::myPoles
    protected

    ◆ myWeights

    NCollection_Array1<double> Convert_ConicToBSplineCurve::myWeights
    protected

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