Open CASCADE Technology
7.2.0

Definition of the B_spline curve. A Bspline curve can be Uniform or nonuniform Rational or nonrational Periodic or nonperiodic. More...
#include <Geom_BSplineCurve.hxx>
Public Member Functions  
Geom_BSplineCurve (const TColgp_Array1OfPnt &Poles, const TColStd_Array1OfReal &Knots, const TColStd_Array1OfInteger &Multiplicities, const Standard_Integer Degree, const Standard_Boolean Periodic=Standard_False)  
Creates a nonrational B_spline curve on the basis <Knots, Multiplicities> of degree <Degree>. More...  
Geom_BSplineCurve (const TColgp_Array1OfPnt &Poles, const TColStd_Array1OfReal &Weights, const TColStd_Array1OfReal &Knots, const TColStd_Array1OfInteger &Multiplicities, const Standard_Integer Degree, const Standard_Boolean Periodic=Standard_False, const Standard_Boolean CheckRational=Standard_True)  
Creates a rational B_spline curve on the basis <Knots, Multiplicities> of degree <Degree>. Raises ConstructionError subject to the following conditions 0 < Degree <= MaxDegree. More...  
void  IncreaseDegree (const Standard_Integer Degree) 
Increases the degree of this BSpline curve to Degree. As a result, the poles, weights and multiplicities tables are modified; the knots table is not changed. Nothing is done if Degree is less than or equal to the current degree. Exceptions Standard_ConstructionError if Degree is greater than Geom_BSplineCurve::MaxDegree(). More...  
void  IncreaseMultiplicity (const Standard_Integer Index, const Standard_Integer M) 
Increases the multiplicity of the knot <Index> to <M>. More...  
void  IncreaseMultiplicity (const Standard_Integer I1, const Standard_Integer I2, const Standard_Integer M) 
Increases the multiplicities of the knots in [I1,I2] to <M>. More...  
void  IncrementMultiplicity (const Standard_Integer I1, const Standard_Integer I2, const Standard_Integer M) 
Increment the multiplicities of the knots in [I1,I2] by <M>. More...  
void  InsertKnot (const Standard_Real U, const Standard_Integer M=1, const Standard_Real ParametricTolerance=0.0, const Standard_Boolean Add=Standard_True) 
Inserts a knot value in the sequence of knots. If <U> is an existing knot the multiplicity is increased by <M>. More...  
void  InsertKnots (const TColStd_Array1OfReal &Knots, const TColStd_Array1OfInteger &Mults, const Standard_Real ParametricTolerance=0.0, const Standard_Boolean Add=Standard_False) 
Inserts a set of knots values in the sequence of knots. More...  
Standard_Boolean  RemoveKnot (const Standard_Integer Index, const Standard_Integer M, const Standard_Real Tolerance) 
Reduces the multiplicity of the knot of index Index to M. If M is equal to 0, the knot is removed. With a modification of this type, the array of poles is also modified. Two different algorithms are systematically used to compute the new poles of the curve. If, for each pole, the distance between the pole calculated using the first algorithm and the same pole calculated using the second algorithm, is less than Tolerance, this ensures that the curve is not modified by more than Tolerance. Under these conditions, true is returned; otherwise, false is returned. A low tolerance is used to prevent modification of the curve. A high tolerance is used to "smooth" the curve. Exceptions Standard_OutOfRange if Index is outside the bounds of the knots table. pole insertion and pole removing this operation is limited to the Uniform or QuasiUniform BSplineCurve. The knot values are modified . If the BSpline is NonUniform or Piecewise Bezier an exception Construction error is raised. More...  
void  Reverse () override 
Changes the direction of parametrization of <me>. The Knot sequence is modified, the FirstParameter and the LastParameter are not modified. The StartPoint of the initial curve becomes the EndPoint of the reversed curve and the EndPoint of the initial curve becomes the StartPoint of the reversed curve. More...  
Standard_Real  ReversedParameter (const Standard_Real U) const override 
Returns the parameter on the reversed curve for the point of parameter U on <me>. More...  
void  Segment (const Standard_Real U1, const Standard_Real U2) 
Modifies this BSpline curve by segmenting it between U1 and U2. Either of these values can be outside the bounds of the curve, but U2 must be greater than U1. All data structure tables of this BSpline curve are modified, but the knots located between U1 and U2 are retained. The degree of the curve is not modified. Warnings : Even if <me> is not closed it can become closed after the segmentation for example if U1 or U2 are out of the bounds of the curve <me> or if the curve makes loop. After the segmentation the length of a curve can be null. raises if U2 < U1. Standard_DomainError if U2  U1 exceeds the period for periodic curves. i.e. ((U2  U1)  Period) > Precision::PConfusion(). More...  
void  SetKnot (const Standard_Integer Index, const Standard_Real K) 
Modifies this BSpline curve by assigning the value K to the knot of index Index in the knots table. This is a relatively local modification because K must be such that: Knots(Index  1) < K < Knots(Index + 1) The second syntax allows you also to increase the multiplicity of the knot to M (but it is not possible to decrease the multiplicity of the knot with this function). Standard_ConstructionError if: More...  
void  SetKnots (const TColStd_Array1OfReal &K) 
Modifies this BSpline curve by assigning the array K to its knots table. The multiplicity of the knots is not modified. Exceptions Standard_ConstructionError if the values in the array K are not in ascending order. Standard_OutOfRange if the bounds of the array K are not respectively 1 and the number of knots of this BSpline curve. More...  
void  SetKnot (const Standard_Integer Index, const Standard_Real K, const Standard_Integer M) 
Changes the knot of range Index with its multiplicity. You can increase the multiplicity of a knot but it is not allowed to decrease the multiplicity of an existing knot. More...  
void  PeriodicNormalization (Standard_Real &U) const 
returns the parameter normalized within the period if the curve is periodic : otherwise does not do anything More...  
void  SetPeriodic () 
Changes this BSpline curve into a periodic curve. To become periodic, the curve must first be closed. Next, the knot sequence must be periodic. For this, FirstUKnotIndex and LastUKnotIndex are used to compute I1 and I2, the indexes in the knots array of the knots corresponding to the first and last parameters of this BSpline curve. The period is therefore: Knots(I2)  Knots(I1). Consequently, the knots and poles tables are modified. Exceptions Standard_ConstructionError if this BSpline curve is not closed. More...  
void  SetOrigin (const Standard_Integer Index) 
Assigns the knot of index Index in the knots table as the origin of this periodic BSpline curve. As a consequence, the knots and poles tables are modified. Exceptions Standard_NoSuchObject if this curve is not periodic. Standard_DomainError if Index is outside the bounds of the knots table. More...  
void  SetOrigin (const Standard_Real U, const Standard_Real Tol) 
Set the origin of a periodic curve at Knot U. If U is not a knot of the BSpline a new knot is inseted. KnotVector and poles are modified. Raised if the curve is not periodic. More...  
void  SetNotPeriodic () 
Changes this BSpline curve into a nonperiodic curve. If this curve is already nonperiodic, it is not modified. Note: the poles and knots tables are modified. Warning If this curve is periodic, as the multiplicity of the first and last knots is not modified, and is not equal to Degree + 1, where Degree is the degree of this BSpline curve, the start and end points of the curve are not its first and last poles. More...  
void  SetPole (const Standard_Integer Index, const gp_Pnt &P) 
Modifies this BSpline curve by assigning P to the pole of index Index in the poles table. Exceptions Standard_OutOfRange if Index is outside the bounds of the poles table. Standard_ConstructionError if Weight is negative or null. More...  
void  SetPole (const Standard_Integer Index, const gp_Pnt &P, const Standard_Real Weight) 
Modifies this BSpline curve by assigning P to the pole of index Index in the poles table. This syntax also allows you to modify the weight of the modified pole, which becomes Weight. In this case, if this BSpline curve is nonrational, it can become rational and vice versa. Exceptions Standard_OutOfRange if Index is outside the bounds of the poles table. Standard_ConstructionError if Weight is negative or null. More...  
void  SetWeight (const Standard_Integer Index, const Standard_Real Weight) 
Changes the weight for the pole of range Index. If the curve was non rational it can become rational. If the curve was rational it can become non rational. More...  
void  MovePoint (const Standard_Real U, const gp_Pnt &P, const Standard_Integer Index1, const Standard_Integer Index2, Standard_Integer &FirstModifiedPole, Standard_Integer &LastModifiedPole) 
Moves the point of parameter U of this BSpline curve to P. Index1 and Index2 are the indexes in the table of poles of this BSpline curve of the first and last poles designated to be moved. FirstModifiedPole and LastModifiedPole are the indexes of the first and last poles which are effectively modified. In the event of incompatibility between Index1, Index2 and the value U: More...  
void  MovePointAndTangent (const Standard_Real U, const gp_Pnt &P, const gp_Vec &Tangent, const Standard_Real Tolerance, const Standard_Integer StartingCondition, const Standard_Integer EndingCondition, Standard_Integer &ErrorStatus) 
Move a point with parameter U to P. and makes it tangent at U be Tangent. StartingCondition = 1 means first can move EndingCondition = 1 means last point can move StartingCondition = 0 means the first point cannot move EndingCondition = 0 means the last point cannot move StartingCondition = 1 means the first point and tangent cannot move EndingCondition = 1 means the last point and tangent cannot move and so forth ErrorStatus != 0 means that there are not enought degree of freedom with the constrain to deform the curve accordingly. More...  
Standard_Boolean  IsCN (const Standard_Integer N) const override 
Returns the continuity of the curve, the curve is at least C0. Raised if N < 0. More...  
Standard_Boolean  IsG1 (const Standard_Real theTf, const Standard_Real theTl, const Standard_Real theAngTol) const 
Check if curve has at least G1 continuity in interval [theTf, theTl] Returns true if IsCN(1) or angle betweem "left" and "right" first derivatives at knots with C0 continuity is less then theAngTol only knots in interval [theTf, theTl] is checked. More...  
Standard_Boolean  IsClosed () const override 
Returns true if the distance between the first point and the last point of the curve is lower or equal to Resolution from package gp. Warnings : The first and the last point can be different from the first pole and the last pole of the curve. More...  
Standard_Boolean  IsPeriodic () const override 
Returns True if the curve is periodic. More...  
Standard_Boolean  IsRational () const 
Returns True if the weights are not identical. The tolerance criterion is Epsilon of the class Real. More...  
GeomAbs_Shape  Continuity () const override 
Returns the global continuity of the curve : C0 : only geometric continuity, C1 : continuity of the first derivative all along the Curve, C2 : continuity of the second derivative all along the Curve, C3 : continuity of the third derivative all along the Curve, CN : the order of continuity is infinite. For a Bspline curve of degree d if a knot Ui has a multiplicity p the Bspline curve is only Cdp continuous at Ui. So the global continuity of the curve can't be greater than Cdp where p is the maximum multiplicity of the interior Knots. In the interior of a knot span the curve is infinitely continuously differentiable. More...  
Standard_Integer  Degree () const 
Returns the degree of this BSpline curve. The degree of a Geom_BSplineCurve curve cannot be greater than Geom_BSplineCurve::MaxDegree(). Computation of value and derivatives. More...  
void  D0 (const Standard_Real U, gp_Pnt &P) const override 
Returns in P the point of parameter U. More...  
void  D1 (const Standard_Real U, gp_Pnt &P, gp_Vec &V1) const override 
Raised if the continuity of the curve is not C1. More...  
void  D2 (const Standard_Real U, gp_Pnt &P, gp_Vec &V1, gp_Vec &V2) const override 
Raised if the continuity of the curve is not C2. More...  
void  D3 (const Standard_Real U, gp_Pnt &P, gp_Vec &V1, gp_Vec &V2, gp_Vec &V3) const override 
Raised if the continuity of the curve is not C3. More...  
gp_Vec  DN (const Standard_Real U, const Standard_Integer N) const override 
For the point of parameter U of this BSpline curve, computes the vector corresponding to the Nth derivative. Warning On a point where the continuity of the curve is not the one requested, this function impacts the part defined by the parameter with a value greater than U, i.e. the part of the curve to the "right" of the singularity. Exceptions Standard_RangeError if N is less than 1. More...  
gp_Pnt  LocalValue (const Standard_Real U, const Standard_Integer FromK1, const Standard_Integer ToK2) const 
Raised if FromK1 = ToK2. More...  
void  LocalD0 (const Standard_Real U, const Standard_Integer FromK1, const Standard_Integer ToK2, gp_Pnt &P) const 
Raised if FromK1 = ToK2. More...  
void  LocalD1 (const Standard_Real U, const Standard_Integer FromK1, const Standard_Integer ToK2, gp_Pnt &P, gp_Vec &V1) const 
Raised if the local continuity of the curve is not C1 between the knot K1 and the knot K2. Raised if FromK1 = ToK2. More...  
void  LocalD2 (const Standard_Real U, const Standard_Integer FromK1, const Standard_Integer ToK2, gp_Pnt &P, gp_Vec &V1, gp_Vec &V2) const 
Raised if the local continuity of the curve is not C2 between the knot K1 and the knot K2. Raised if FromK1 = ToK2. More...  
void  LocalD3 (const Standard_Real U, const Standard_Integer FromK1, const Standard_Integer ToK2, gp_Pnt &P, gp_Vec &V1, gp_Vec &V2, gp_Vec &V3) const 
Raised if the local continuity of the curve is not C3 between the knot K1 and the knot K2. Raised if FromK1 = ToK2. More...  
gp_Vec  LocalDN (const Standard_Real U, const Standard_Integer FromK1, const Standard_Integer ToK2, const Standard_Integer N) const 
Raised if the local continuity of the curve is not CN between the knot K1 and the knot K2. Raised if FromK1 = ToK2. Raised if N < 1. More...  
gp_Pnt  EndPoint () const override 
Returns the last point of the curve. Warnings : The last point of the curve is different from the last pole of the curve if the multiplicity of the last knot is lower than Degree. More...  
Standard_Integer  FirstUKnotIndex () const 
Returns the index in the knot array of the knot corresponding to the first or last parameter of this BSpline curve. For a BSpline curve, the first (or last) parameter (which gives the start (or end) point of the curve) is a knot value. However, if the multiplicity of the first (or last) knot is less than Degree + 1, where Degree is the degree of the curve, it is not the first (or last) knot of the curve. More...  
Standard_Real  FirstParameter () const override 
Returns the value of the first parameter of this BSpline curve. This is a knot value. The first parameter is the one of the start point of the BSpline curve. More...  
Standard_Real  Knot (const Standard_Integer Index) const 
Returns the knot of range Index. When there is a knot with a multiplicity greater than 1 the knot is not repeated. The method Multiplicity can be used to get the multiplicity of the Knot. Raised if Index < 1 or Index > NbKnots. More...  
void  Knots (TColStd_Array1OfReal &K) const 
returns the knot values of the Bspline curve; Warning A knot with a multiplicity greater than 1 is not repeated in the knot table. The Multiplicity function can be used to obtain the multiplicity of each knot. More...  
const TColStd_Array1OfReal &  Knots () const 
returns the knot values of the Bspline curve; Warning A knot with a multiplicity greater than 1 is not repeated in the knot table. The Multiplicity function can be used to obtain the multiplicity of each knot. More...  
void  KnotSequence (TColStd_Array1OfReal &K) const 
Returns K, the knots sequence of this BSpline curve. In this sequence, knots with a multiplicity greater than 1 are repeated. In the case of a nonperiodic curve the length of the sequence must be equal to the sum of the NbKnots multiplicities of the knots of the curve (where NbKnots is the number of knots of this BSpline curve). This sum is also equal to : NbPoles + Degree + 1 where NbPoles is the number of poles and Degree the degree of this BSpline curve. In the case of a periodic curve, if there are k periodic knots, the period is Knot(k+1)  Knot(1). The initial sequence is built by writing knots 1 to k+1, which are repeated according to their corresponding multiplicities. If Degree is the degree of the curve, the degree of continuity of the curve at the knot of index 1 (or k+1) is equal to c = Degree + 1  Mult(1). c knots are then inserted at the beginning and end of the initial sequence: More...  
const TColStd_Array1OfReal &  KnotSequence () const 
returns the knots of the Bspline curve. Knots with multiplicit greater than 1 are repeated More...  
GeomAbs_BSplKnotDistribution  KnotDistribution () const 
Returns NonUniform or Uniform or QuasiUniform or PiecewiseBezier. If all the knots differ by a positive constant from the preceding knot the BSpline Curve can be : More...  
Standard_Integer  LastUKnotIndex () const 
For a BSpline curve the last parameter (which gives the end point of the curve) is a knot value but if the multiplicity of the last knot index is lower than Degree + 1 it is not the last knot of the curve. This method computes the index of the knot corresponding to the last parameter. More...  
Standard_Real  LastParameter () const override 
Computes the parametric value of the end point of the curve. It is a knot value. More...  
void  LocateU (const Standard_Real U, const Standard_Real ParametricTolerance, Standard_Integer &I1, Standard_Integer &I2, const Standard_Boolean WithKnotRepetition=Standard_False) const 
Locates the parametric value U in the sequence of knots. If "WithKnotRepetition" is True we consider the knot's representation with repetition of multiple knot value, otherwise we consider the knot's representation with no repetition of multiple knot values. Knots (I1) <= U <= Knots (I2) . if I1 = I2 U is a knot value (the tolerance criterion ParametricTolerance is used). . if I1 < 1 => U < Knots (1)  Abs(ParametricTolerance) . if I2 > NbKnots => U > Knots (NbKnots) + Abs(ParametricTolerance) More...  
Standard_Integer  Multiplicity (const Standard_Integer Index) const 
Returns the multiplicity of the knots of range Index. Raised if Index < 1 or Index > NbKnots. More...  
void  Multiplicities (TColStd_Array1OfInteger &M) const 
Returns the multiplicity of the knots of the curve. More...  
const TColStd_Array1OfInteger &  Multiplicities () const 
returns the multiplicity of the knots of the curve. More...  
Standard_Integer  NbKnots () const 
Returns the number of knots. This method returns the number of knot without repetition of multiple knots. More...  
Standard_Integer  NbPoles () const 
Returns the number of poles. More...  
const gp_Pnt &  Pole (const Standard_Integer Index) const 
Returns the pole of range Index. Raised if Index < 1 or Index > NbPoles. More...  
void  Poles (TColgp_Array1OfPnt &P) const 
Returns the poles of the Bspline curve;. More...  
const TColgp_Array1OfPnt &  Poles () const 
Returns the poles of the Bspline curve;. More...  
gp_Pnt  StartPoint () const override 
Returns the start point of the curve. Warnings : This point is different from the first pole of the curve if the multiplicity of the first knot is lower than Degree. More...  
Standard_Real  Weight (const Standard_Integer Index) const 
Returns the weight of the pole of range Index . Raised if Index < 1 or Index > NbPoles. More...  
void  Weights (TColStd_Array1OfReal &W) const 
Returns the weights of the Bspline curve;. More...  
const TColStd_Array1OfReal *  Weights () const 
Returns the weights of the Bspline curve;. More...  
void  Transform (const gp_Trsf &T) override 
Applies the transformation T to this BSpline curve. More...  
void  Resolution (const Standard_Real Tolerance3D, Standard_Real &UTolerance) 
Computes for this BSpline curve the parametric tolerance UTolerance for a given 3D tolerance Tolerance3D. If f(t) is the equation of this BSpline curve, UTolerance ensures that:  t1  t0 < Utolerance ===> f(t1)  f(t0) < Tolerance3D. More...  
Handle< Geom_Geometry >  Copy () const override 
Creates a new object which is a copy of this BSpline curve. More...  
Standard_Boolean  IsEqual (const Handle< Geom_BSplineCurve > &theOther, const Standard_Real thePreci) const 
Comapare two Bspline curve on identity;. More...  
Public Member Functions inherited from Geom_Curve  
virtual Standard_Real  TransformedParameter (const Standard_Real U, const gp_Trsf &T) const 
Returns the parameter on the transformed curve for the transform of the point of parameter U on <me>. More...  
virtual Standard_Real  ParametricTransformation (const gp_Trsf &T) const 
Returns a coefficient to compute the parameter on the transformed curve for the transform of the point on <me>. More...  
Handle< Geom_Curve >  Reversed () const 
Returns a copy of <me> reversed. More...  
virtual Standard_Real  Period () const 
Returns the period of this curve. Exceptions Standard_NoSuchObject if this curve is not periodic. More...  
gp_Pnt  Value (const Standard_Real U) const 
Computes the point of parameter U on <me>. If the curve is periodic then the returned point is P(U) with U = Ustart + (U  Uend) where Ustart and Uend are the parametric bounds of the curve. it is implemented with D0. More...  
Public Member Functions inherited from Geom_Geometry  
void  Mirror (const gp_Pnt &P) 
Performs the symmetrical transformation of a Geometry with respect to the point P which is the center of the symmetry. More...  
void  Mirror (const gp_Ax1 &A1) 
Performs the symmetrical transformation of a Geometry with respect to an axis placement which is the axis of the symmetry. More...  
void  Mirror (const gp_Ax2 &A2) 
Performs the symmetrical transformation of a Geometry with respect to a plane. The axis placement A2 locates the plane of the symmetry : (Location, XDirection, YDirection). More...  
void  Rotate (const gp_Ax1 &A1, const Standard_Real Ang) 
Rotates a Geometry. A1 is the axis of the rotation. Ang is the angular value of the rotation in radians. More...  
void  Scale (const gp_Pnt &P, const Standard_Real S) 
Scales a Geometry. S is the scaling value. More...  
void  Translate (const gp_Vec &V) 
Translates a Geometry. V is the vector of the tanslation. More...  
void  Translate (const gp_Pnt &P1, const gp_Pnt &P2) 
Translates a Geometry from the point P1 to the point P2. More...  
Handle< Geom_Geometry >  Mirrored (const gp_Pnt &P) const 
Handle< Geom_Geometry >  Mirrored (const gp_Ax1 &A1) const 
Handle< Geom_Geometry >  Mirrored (const gp_Ax2 &A2) const 
Handle< Geom_Geometry >  Rotated (const gp_Ax1 &A1, const Standard_Real Ang) const 
Handle< Geom_Geometry >  Scaled (const gp_Pnt &P, const Standard_Real S) const 
Handle< Geom_Geometry >  Transformed (const gp_Trsf &T) const 
Handle< Geom_Geometry >  Translated (const gp_Vec &V) const 
Handle< Geom_Geometry >  Translated (const gp_Pnt &P1, const gp_Pnt &P2) const 
Public Member Functions inherited from Standard_Transient  
Standard_Transient ()  
Empty constructor. More...  
Standard_Transient (const Standard_Transient &)  
Copy constructor – does nothing. More...  
Standard_Transient &  operator= (const Standard_Transient &) 
Assignment operator, needed to avoid copying reference counter. More...  
virtual  ~Standard_Transient () 
Destructor must be virtual. More...  
virtual void  Delete () const 
Memory deallocator for transient classes. More...  
virtual const opencascade::handle< Standard_Type > &  DynamicType () const 
Returns a type descriptor about this object. More...  
Standard_Boolean  IsInstance (const opencascade::handle< Standard_Type > &theType) const 
Returns a true value if this is an instance of Type. More...  
Standard_Boolean  IsInstance (const Standard_CString theTypeName) const 
Returns a true value if this is an instance of TypeName. More...  
Standard_Boolean  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. More...  
Standard_Boolean  IsKind (const Standard_CString 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. More...  
Standard_Transient *  This () const 
Returns nonconst 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. More...  
Standard_Integer  GetRefCount () const 
Get the reference counter of this object. More...  
void  IncrementRefCounter () const 
Increments the reference counter of this object. More...  
Standard_Integer  DecrementRefCounter () const 
Decrements the reference counter of this object; returns the decremented value. More...  
Static Public Member Functions  
static Standard_Integer  MaxDegree () 
Returns the value of the maximum degree of the normalized Bspline basis functions in this package. More...  
Static Public Member Functions inherited from Standard_Transient  
static const char *  get_type_name () 
Returns a type descriptor about this object. More...  
static const opencascade::handle< Standard_Type > &  get_type_descriptor () 
Returns type descriptor of Standard_Transient class. More...  
Additional Inherited Members  
Public Types inherited from Standard_Transient  
typedef void  base_type 
Returns a type descriptor about this object. More...  
Definition of the B_spline curve. A Bspline curve can be Uniform or nonuniform Rational or nonrational Periodic or nonperiodic.
a bspline curve is defined by : its degree; the degree for a Geom_BSplineCurve is limited to a value (25) which is defined and controlled by the system. This value is returned by the function MaxDegree;
References : . A survey of curve and surface methods in CADG Wolfgang BOHM CAGD 1 (1984) . On de Boorlike algorithms and blossoming Wolfgang BOEHM cagd 5 (1988) . Blossoming and knot insertion algorithms for Bspline curves Ronald N. GOLDMAN . Modelisation des surfaces en CAO, Henri GIAUME Peugeot SA . Curves and Surfaces for Computer Aided Geometric Design, a practical guide Gerald Farin
Geom_BSplineCurve::Geom_BSplineCurve  (  const TColgp_Array1OfPnt &  Poles, 
const TColStd_Array1OfReal &  Knots,  
const TColStd_Array1OfInteger &  Multiplicities,  
const Standard_Integer  Degree,  
const Standard_Boolean  Periodic = Standard_False 

) 
Creates a nonrational B_spline curve on the basis <Knots, Multiplicities> of degree <Degree>.
Geom_BSplineCurve::Geom_BSplineCurve  (  const TColgp_Array1OfPnt &  Poles, 
const TColStd_Array1OfReal &  Weights,  
const TColStd_Array1OfReal &  Knots,  
const TColStd_Array1OfInteger &  Multiplicities,  
const Standard_Integer  Degree,  
const Standard_Boolean  Periodic = Standard_False , 

const Standard_Boolean  CheckRational = Standard_True 

) 
Creates a rational B_spline curve on the basis <Knots, Multiplicities> of degree <Degree>. Raises ConstructionError subject to the following conditions 0 < Degree <= MaxDegree.
Weights.Length() == Poles.Length()
Knots.Length() == Mults.Length() >= 2
Knots(i) < Knots(i+1) (Knots are increasing)
1 <= Mults(i) <= Degree
On a non periodic curve the first and last multiplicities may be Degree+1 (this is even recommanded if you want the curve to start and finish on the first and last pole).
On a periodic curve the first and the last multicities must be the same.
on nonperiodic curves
Poles.Length() == Sum(Mults(i))  Degree  1 >= 2
on periodic curves
Poles.Length() == Sum(Mults(i)) except the first or last

overridevirtual 
Returns the global continuity of the curve : C0 : only geometric continuity, C1 : continuity of the first derivative all along the Curve, C2 : continuity of the second derivative all along the Curve, C3 : continuity of the third derivative all along the Curve, CN : the order of continuity is infinite. For a Bspline curve of degree d if a knot Ui has a multiplicity p the Bspline curve is only Cdp continuous at Ui. So the global continuity of the curve can't be greater than Cdp where p is the maximum multiplicity of the interior Knots. In the interior of a knot span the curve is infinitely continuously differentiable.
Implements Geom_Curve.

overridevirtual 
Creates a new object which is a copy of this BSpline curve.
Implements Geom_Geometry.

overridevirtual 
Returns in P the point of parameter U.
Implements Geom_Curve.

overridevirtual 
Raised if the continuity of the curve is not C1.
Implements Geom_Curve.

overridevirtual 
Raised if the continuity of the curve is not C2.
Implements Geom_Curve.

overridevirtual 
Raised if the continuity of the curve is not C3.
Implements Geom_Curve.
Standard_Integer Geom_BSplineCurve::Degree  (  )  const 
Returns the degree of this BSpline curve. The degree of a Geom_BSplineCurve curve cannot be greater than Geom_BSplineCurve::MaxDegree(). Computation of value and derivatives.

overridevirtual 
For the point of parameter U of this BSpline curve, computes the vector corresponding to the Nth derivative. Warning On a point where the continuity of the curve is not the one requested, this function impacts the part defined by the parameter with a value greater than U, i.e. the part of the curve to the "right" of the singularity. Exceptions Standard_RangeError if N is less than 1.
The following functions compute the point of parameter U and the derivatives at this point on the Bspline curve arc defined between the knot FromK1 and the knot ToK2. U can be out of bounds [Knot (FromK1), Knot (ToK2)] but for the computation we only use the definition of the curve between these two knots. This method is useful to compute local derivative, if the order of continuity of the whole curve is not greater enough. Inside the parametric domain Knot (FromK1), Knot (ToK2) the evaluations are the same as if we consider the whole definition of the curve. Of course the evaluations are different outside this parametric domain.
Implements Geom_Curve.

overridevirtual 
Returns the last point of the curve. Warnings : The last point of the curve is different from the last pole of the curve if the multiplicity of the last knot is lower than Degree.
Implements Geom_BoundedCurve.

overridevirtual 
Returns the value of the first parameter of this BSpline curve. This is a knot value. The first parameter is the one of the start point of the BSpline curve.
Implements Geom_Curve.
Standard_Integer Geom_BSplineCurve::FirstUKnotIndex  (  )  const 
Returns the index in the knot array of the knot corresponding to the first or last parameter of this BSpline curve. For a BSpline curve, the first (or last) parameter (which gives the start (or end) point of the curve) is a knot value. However, if the multiplicity of the first (or last) knot is less than Degree + 1, where Degree is the degree of the curve, it is not the first (or last) knot of the curve.
void Geom_BSplineCurve::IncreaseDegree  (  const Standard_Integer  Degree  ) 
Increases the degree of this BSpline curve to Degree. As a result, the poles, weights and multiplicities tables are modified; the knots table is not changed. Nothing is done if Degree is less than or equal to the current degree. Exceptions Standard_ConstructionError if Degree is greater than Geom_BSplineCurve::MaxDegree().
void Geom_BSplineCurve::IncreaseMultiplicity  (  const Standard_Integer  Index, 
const Standard_Integer  M  
) 
Increases the multiplicity of the knot <Index> to <M>.
If <M> is lower or equal to the current multiplicity nothing is done. If <M> is higher than the degree the degree is used. If <Index> is not in [FirstUKnotIndex, LastUKnotIndex]
void Geom_BSplineCurve::IncreaseMultiplicity  (  const Standard_Integer  I1, 
const Standard_Integer  I2,  
const Standard_Integer  M  
) 
Increases the multiplicities of the knots in [I1,I2] to <M>.
For each knot if <M> is lower or equal to the current multiplicity nothing is done. If <M> is higher than the degree the degree is used. If <I1,I2> are not in [FirstUKnotIndex, LastUKnotIndex]
void Geom_BSplineCurve::IncrementMultiplicity  (  const Standard_Integer  I1, 
const Standard_Integer  I2,  
const Standard_Integer  M  
) 
Increment the multiplicities of the knots in [I1,I2] by <M>.
If <M> is not positive nithing is done.
For each knot the resulting multiplicity is limited to the Degree. If <I1,I2> are not in [FirstUKnotIndex, LastUKnotIndex]
void Geom_BSplineCurve::InsertKnot  (  const Standard_Real  U, 
const Standard_Integer  M = 1 , 

const Standard_Real  ParametricTolerance = 0.0 , 

const Standard_Boolean  Add = Standard_True 

) 
Inserts a knot value in the sequence of knots. If <U> is an existing knot the multiplicity is increased by <M>.
If U is not on the parameter range nothing is done.
If the multiplicity is negative or null nothing is done. The new multiplicity is limited to the degree.
The tolerance criterion for knots equality is the max of Epsilon(U) and ParametricTolerance.
void Geom_BSplineCurve::InsertKnots  (  const TColStd_Array1OfReal &  Knots, 
const TColStd_Array1OfInteger &  Mults,  
const Standard_Real  ParametricTolerance = 0.0 , 

const Standard_Boolean  Add = Standard_False 

) 
Inserts a set of knots values in the sequence of knots.
For each U = Knots(i), M = Mults(i)
If <U> is an existing knot the multiplicity is increased by <M> if <Add> is True, increased to <M> if <Add> is False.
If U is not on the parameter range nothing is done.
If the multiplicity is negative or null nothing is done. The new multiplicity is limited to the degree.
The tolerance criterion for knots equality is the max of Epsilon(U) and ParametricTolerance.

overridevirtual 
Returns true if the distance between the first point and the last point of the curve is lower or equal to Resolution from package gp. Warnings : The first and the last point can be different from the first pole and the last pole of the curve.
Implements Geom_Curve.

overridevirtual 
Returns the continuity of the curve, the curve is at least C0. Raised if N < 0.
Implements Geom_Curve.
Standard_Boolean Geom_BSplineCurve::IsEqual  (  const Handle< Geom_BSplineCurve > &  theOther, 
const Standard_Real  thePreci  
)  const 
Comapare two Bspline curve on identity;.
Standard_Boolean Geom_BSplineCurve::IsG1  (  const Standard_Real  theTf, 
const Standard_Real  theTl,  
const Standard_Real  theAngTol  
)  const 
Check if curve has at least G1 continuity in interval [theTf, theTl] Returns true if IsCN(1) or angle betweem "left" and "right" first derivatives at knots with C0 continuity is less then theAngTol only knots in interval [theTf, theTl] is checked.

overridevirtual 
Returns True if the curve is periodic.
Implements Geom_Curve.
Standard_Boolean Geom_BSplineCurve::IsRational  (  )  const 
Returns True if the weights are not identical. The tolerance criterion is Epsilon of the class Real.
Standard_Real Geom_BSplineCurve::Knot  (  const Standard_Integer  Index  )  const 
Returns the knot of range Index. When there is a knot with a multiplicity greater than 1 the knot is not repeated. The method Multiplicity can be used to get the multiplicity of the Knot. Raised if Index < 1 or Index > NbKnots.
GeomAbs_BSplKnotDistribution Geom_BSplineCurve::KnotDistribution  (  )  const 
Returns NonUniform or Uniform or QuasiUniform or PiecewiseBezier. If all the knots differ by a positive constant from the preceding knot the BSpline Curve can be :
void Geom_BSplineCurve::Knots  (  TColStd_Array1OfReal &  K  )  const 
returns the knot values of the Bspline curve; Warning A knot with a multiplicity greater than 1 is not repeated in the knot table. The Multiplicity function can be used to obtain the multiplicity of each knot.
Raised K.Lower() is less than number of first knot or K.Upper() is more than number of last knot.
const TColStd_Array1OfReal& Geom_BSplineCurve::Knots  (  )  const 
returns the knot values of the Bspline curve; Warning A knot with a multiplicity greater than 1 is not repeated in the knot table. The Multiplicity function can be used to obtain the multiplicity of each knot.
void Geom_BSplineCurve::KnotSequence  (  TColStd_Array1OfReal &  K  )  const 
Returns K, the knots sequence of this BSpline curve. In this sequence, knots with a multiplicity greater than 1 are repeated. In the case of a nonperiodic curve the length of the sequence must be equal to the sum of the NbKnots multiplicities of the knots of the curve (where NbKnots is the number of knots of this BSpline curve). This sum is also equal to : NbPoles + Degree + 1 where NbPoles is the number of poles and Degree the degree of this BSpline curve. In the case of a periodic curve, if there are k periodic knots, the period is Knot(k+1)  Knot(1). The initial sequence is built by writing knots 1 to k+1, which are repeated according to their corresponding multiplicities. If Degree is the degree of the curve, the degree of continuity of the curve at the knot of index 1 (or k+1) is equal to c = Degree + 1  Mult(1). c knots are then inserted at the beginning and end of the initial sequence:
const TColStd_Array1OfReal& Geom_BSplineCurve::KnotSequence  (  )  const 
returns the knots of the Bspline curve. Knots with multiplicit greater than 1 are repeated

overridevirtual 
Computes the parametric value of the end point of the curve. It is a knot value.
Implements Geom_Curve.
Standard_Integer Geom_BSplineCurve::LastUKnotIndex  (  )  const 
For a BSpline curve the last parameter (which gives the end point of the curve) is a knot value but if the multiplicity of the last knot index is lower than Degree + 1 it is not the last knot of the curve. This method computes the index of the knot corresponding to the last parameter.
void Geom_BSplineCurve::LocalD0  (  const Standard_Real  U, 
const Standard_Integer  FromK1,  
const Standard_Integer  ToK2,  
gp_Pnt &  P  
)  const 
Raised if FromK1 = ToK2.
void Geom_BSplineCurve::LocalD1  (  const Standard_Real  U, 
const Standard_Integer  FromK1,  
const Standard_Integer  ToK2,  
gp_Pnt &  P,  
gp_Vec &  V1  
)  const 
Raised if the local continuity of the curve is not C1 between the knot K1 and the knot K2. Raised if FromK1 = ToK2.
void Geom_BSplineCurve::LocalD2  (  const Standard_Real  U, 
const Standard_Integer  FromK1,  
const Standard_Integer  ToK2,  
gp_Pnt &  P,  
gp_Vec &  V1,  
gp_Vec &  V2  
)  const 
Raised if the local continuity of the curve is not C2 between the knot K1 and the knot K2. Raised if FromK1 = ToK2.
void Geom_BSplineCurve::LocalD3  (  const Standard_Real  U, 
const Standard_Integer  FromK1,  
const Standard_Integer  ToK2,  
gp_Pnt &  P,  
gp_Vec &  V1,  
gp_Vec &  V2,  
gp_Vec &  V3  
)  const 
Raised if the local continuity of the curve is not C3 between the knot K1 and the knot K2. Raised if FromK1 = ToK2.
gp_Vec Geom_BSplineCurve::LocalDN  (  const Standard_Real  U, 
const Standard_Integer  FromK1,  
const Standard_Integer  ToK2,  
const Standard_Integer  N  
)  const 
Raised if the local continuity of the curve is not CN between the knot K1 and the knot K2. Raised if FromK1 = ToK2. Raised if N < 1.
gp_Pnt Geom_BSplineCurve::LocalValue  (  const Standard_Real  U, 
const Standard_Integer  FromK1,  
const Standard_Integer  ToK2  
)  const 
Raised if FromK1 = ToK2.
void Geom_BSplineCurve::LocateU  (  const Standard_Real  U, 
const Standard_Real  ParametricTolerance,  
Standard_Integer &  I1,  
Standard_Integer &  I2,  
const Standard_Boolean  WithKnotRepetition = Standard_False 

)  const 
Locates the parametric value U in the sequence of knots. If "WithKnotRepetition" is True we consider the knot's representation with repetition of multiple knot value, otherwise we consider the knot's representation with no repetition of multiple knot values. Knots (I1) <= U <= Knots (I2) . if I1 = I2 U is a knot value (the tolerance criterion ParametricTolerance is used). . if I1 < 1 => U < Knots (1)  Abs(ParametricTolerance) . if I2 > NbKnots => U > Knots (NbKnots) + Abs(ParametricTolerance)

static 
Returns the value of the maximum degree of the normalized Bspline basis functions in this package.
void Geom_BSplineCurve::MovePoint  (  const Standard_Real  U, 
const gp_Pnt &  P,  
const Standard_Integer  Index1,  
const Standard_Integer  Index2,  
Standard_Integer &  FirstModifiedPole,  
Standard_Integer &  LastModifiedPole  
) 
Moves the point of parameter U of this BSpline curve to P. Index1 and Index2 are the indexes in the table of poles of this BSpline curve of the first and last poles designated to be moved. FirstModifiedPole and LastModifiedPole are the indexes of the first and last poles which are effectively modified. In the event of incompatibility between Index1, Index2 and the value U:
void Geom_BSplineCurve::MovePointAndTangent  (  const Standard_Real  U, 
const gp_Pnt &  P,  
const gp_Vec &  Tangent,  
const Standard_Real  Tolerance,  
const Standard_Integer  StartingCondition,  
const Standard_Integer  EndingCondition,  
Standard_Integer &  ErrorStatus  
) 
Move a point with parameter U to P. and makes it tangent at U be Tangent. StartingCondition = 1 means first can move EndingCondition = 1 means last point can move StartingCondition = 0 means the first point cannot move EndingCondition = 0 means the last point cannot move StartingCondition = 1 means the first point and tangent cannot move EndingCondition = 1 means the last point and tangent cannot move and so forth ErrorStatus != 0 means that there are not enought degree of freedom with the constrain to deform the curve accordingly.
void Geom_BSplineCurve::Multiplicities  (  TColStd_Array1OfInteger &  M  )  const 
Returns the multiplicity of the knots of the curve.
Raised if the length of M is not equal to NbKnots.
const TColStd_Array1OfInteger& Geom_BSplineCurve::Multiplicities  (  )  const 
returns the multiplicity of the knots of the curve.
Standard_Integer Geom_BSplineCurve::Multiplicity  (  const Standard_Integer  Index  )  const 
Returns the multiplicity of the knots of range Index. Raised if Index < 1 or Index > NbKnots.
Standard_Integer Geom_BSplineCurve::NbKnots  (  )  const 
Returns the number of knots. This method returns the number of knot without repetition of multiple knots.
Standard_Integer Geom_BSplineCurve::NbPoles  (  )  const 
Returns the number of poles.
void Geom_BSplineCurve::PeriodicNormalization  (  Standard_Real &  U  )  const 
returns the parameter normalized within the period if the curve is periodic : otherwise does not do anything
const gp_Pnt& Geom_BSplineCurve::Pole  (  const Standard_Integer  Index  )  const 
Returns the pole of range Index. Raised if Index < 1 or Index > NbPoles.
void Geom_BSplineCurve::Poles  (  TColgp_Array1OfPnt &  P  )  const 
Returns the poles of the Bspline curve;.
Raised if the length of P is not equal to the number of poles.
const TColgp_Array1OfPnt& Geom_BSplineCurve::Poles  (  )  const 
Returns the poles of the Bspline curve;.
Standard_Boolean Geom_BSplineCurve::RemoveKnot  (  const Standard_Integer  Index, 
const Standard_Integer  M,  
const Standard_Real  Tolerance  
) 
Reduces the multiplicity of the knot of index Index to M. If M is equal to 0, the knot is removed. With a modification of this type, the array of poles is also modified. Two different algorithms are systematically used to compute the new poles of the curve. If, for each pole, the distance between the pole calculated using the first algorithm and the same pole calculated using the second algorithm, is less than Tolerance, this ensures that the curve is not modified by more than Tolerance. Under these conditions, true is returned; otherwise, false is returned. A low tolerance is used to prevent modification of the curve. A high tolerance is used to "smooth" the curve. Exceptions Standard_OutOfRange if Index is outside the bounds of the knots table. pole insertion and pole removing this operation is limited to the Uniform or QuasiUniform BSplineCurve. The knot values are modified . If the BSpline is NonUniform or Piecewise Bezier an exception Construction error is raised.
void Geom_BSplineCurve::Resolution  (  const Standard_Real  Tolerance3D, 
Standard_Real &  UTolerance  
) 
Computes for this BSpline curve the parametric tolerance UTolerance for a given 3D tolerance Tolerance3D. If f(t) is the equation of this BSpline curve, UTolerance ensures that:  t1  t0 < Utolerance ===> f(t1)  f(t0) < Tolerance3D.

overridevirtual 
Changes the direction of parametrization of <me>. The Knot sequence is modified, the FirstParameter and the LastParameter are not modified. The StartPoint of the initial curve becomes the EndPoint of the reversed curve and the EndPoint of the initial curve becomes the StartPoint of the reversed curve.
Implements Geom_Curve.

overridevirtual 
Returns the parameter on the reversed curve for the point of parameter U on <me>.
returns UFirst + ULast  U
Implements Geom_Curve.
void Geom_BSplineCurve::Segment  (  const Standard_Real  U1, 
const Standard_Real  U2  
) 
Modifies this BSpline curve by segmenting it between U1 and U2. Either of these values can be outside the bounds of the curve, but U2 must be greater than U1. All data structure tables of this BSpline curve are modified, but the knots located between U1 and U2 are retained. The degree of the curve is not modified. Warnings : Even if <me> is not closed it can become closed after the segmentation for example if U1 or U2 are out of the bounds of the curve <me> or if the curve makes loop. After the segmentation the length of a curve can be null. raises if U2 < U1. Standard_DomainError if U2  U1 exceeds the period for periodic curves. i.e. ((U2  U1)  Period) > Precision::PConfusion().
void Geom_BSplineCurve::SetKnot  (  const Standard_Integer  Index, 
const Standard_Real  K  
) 
Modifies this BSpline curve by assigning the value K to the knot of index Index in the knots table. This is a relatively local modification because K must be such that: Knots(Index  1) < K < Knots(Index + 1) The second syntax allows you also to increase the multiplicity of the knot to M (but it is not possible to decrease the multiplicity of the knot with this function). Standard_ConstructionError if:
void Geom_BSplineCurve::SetKnot  (  const Standard_Integer  Index, 
const Standard_Real  K,  
const Standard_Integer  M  
) 
Changes the knot of range Index with its multiplicity. You can increase the multiplicity of a knot but it is not allowed to decrease the multiplicity of an existing knot.
Raised if K >= Knots(Index+1) or K <= Knots(Index1). Raised if M is greater than Degree or lower than the previous multiplicity of knot of range Index. Raised if Index < 1  Index > NbKnots
void Geom_BSplineCurve::SetKnots  (  const TColStd_Array1OfReal &  K  ) 
Modifies this BSpline curve by assigning the array K to its knots table. The multiplicity of the knots is not modified. Exceptions Standard_ConstructionError if the values in the array K are not in ascending order. Standard_OutOfRange if the bounds of the array K are not respectively 1 and the number of knots of this BSpline curve.
void Geom_BSplineCurve::SetNotPeriodic  (  ) 
Changes this BSpline curve into a nonperiodic curve. If this curve is already nonperiodic, it is not modified. Note: the poles and knots tables are modified. Warning If this curve is periodic, as the multiplicity of the first and last knots is not modified, and is not equal to Degree + 1, where Degree is the degree of this BSpline curve, the start and end points of the curve are not its first and last poles.
void Geom_BSplineCurve::SetOrigin  (  const Standard_Integer  Index  ) 
Assigns the knot of index Index in the knots table as the origin of this periodic BSpline curve. As a consequence, the knots and poles tables are modified. Exceptions Standard_NoSuchObject if this curve is not periodic. Standard_DomainError if Index is outside the bounds of the knots table.
void Geom_BSplineCurve::SetOrigin  (  const Standard_Real  U, 
const Standard_Real  Tol  
) 
Set the origin of a periodic curve at Knot U. If U is not a knot of the BSpline a new knot is inseted. KnotVector and poles are modified. Raised if the curve is not periodic.
void Geom_BSplineCurve::SetPeriodic  (  ) 
Changes this BSpline curve into a periodic curve. To become periodic, the curve must first be closed. Next, the knot sequence must be periodic. For this, FirstUKnotIndex and LastUKnotIndex are used to compute I1 and I2, the indexes in the knots array of the knots corresponding to the first and last parameters of this BSpline curve. The period is therefore: Knots(I2)  Knots(I1). Consequently, the knots and poles tables are modified. Exceptions Standard_ConstructionError if this BSpline curve is not closed.
void Geom_BSplineCurve::SetPole  (  const Standard_Integer  Index, 
const gp_Pnt &  P  
) 
Modifies this BSpline curve by assigning P to the pole of index Index in the poles table. Exceptions Standard_OutOfRange if Index is outside the bounds of the poles table. Standard_ConstructionError if Weight is negative or null.
void Geom_BSplineCurve::SetPole  (  const Standard_Integer  Index, 
const gp_Pnt &  P,  
const Standard_Real  Weight  
) 
Modifies this BSpline curve by assigning P to the pole of index Index in the poles table. This syntax also allows you to modify the weight of the modified pole, which becomes Weight. In this case, if this BSpline curve is nonrational, it can become rational and vice versa. Exceptions Standard_OutOfRange if Index is outside the bounds of the poles table. Standard_ConstructionError if Weight is negative or null.
void Geom_BSplineCurve::SetWeight  (  const Standard_Integer  Index, 
const Standard_Real  Weight  
) 
Changes the weight for the pole of range Index. If the curve was non rational it can become rational. If the curve was rational it can become non rational.
Raised if Index < 1  Index > NbPoles Raised if Weight <= 0.0

overridevirtual 
Returns the start point of the curve. Warnings : This point is different from the first pole of the curve if the multiplicity of the first knot is lower than Degree.
Implements Geom_BoundedCurve.

overridevirtual 
Applies the transformation T to this BSpline curve.
Implements Geom_Geometry.
Standard_Real Geom_BSplineCurve::Weight  (  const Standard_Integer  Index  )  const 
Returns the weight of the pole of range Index . Raised if Index < 1 or Index > NbPoles.
void Geom_BSplineCurve::Weights  (  TColStd_Array1OfReal &  W  )  const 
Returns the weights of the Bspline curve;.
Raised if the length of W is not equal to NbPoles.
const TColStd_Array1OfReal* Geom_BSplineCurve::Weights  (  )  const 
Returns the weights of the Bspline curve;.