if degree = degree + 2 -> Index + 2 and insert new knots or Multiplicities
nurbs_surface->Setknot(Index, knots);// new Knots
Please read the help
//! 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:
//! - K is not such that:
//! Knots(Index - 1) < K < Knots(Index + 1)
//! - M is greater than the degree of this BSpline curve
//! or lower than the previous multiplicity of knot of
//! index Index in the knots table.
//! Standard_OutOfRange if Index is outside the bounds of the knots table.
Dear Rabih
Thanks for your kindly help! But I do not understand how your code decrease the surface's degree?
I mean I need decrease a surface'degree along U direction or along V direction,but how can I do it with the function:
Handle_Geom_BSplineSurface nurbs_surface = new
Geom_BSplineSurface(poles,uknots, vknots, umults, vmults, UDegree, VDegree,IsUPeriodic, IsVPeriodic);
Tue, 12/11/2012 - 16:53
Hi,
Handle_Geom_BSplineSurface nurbs_surface = new Geom_BSplineSurface(poles,uknots, vknots, umults, vmults, UDegree, VDegree,IsUPeriodic, IsVPeriodic);
nurbs_surface->IncreaseDegree(UDegree, VDegree);
Best regards
Rabih
Wed, 12/12/2012 - 10:01
I want to decrease degree not to increase degree ,but thanks your information all the same!
Wed, 12/12/2012 - 18:11
Hi,
you need
Handle_Geom_BSplineSurface nurbs_surface = new Geom_BSplineSurface(poles,uknots, vknots, umults, vmults, UDegree, VDegree,IsUPeriodic, IsVPeriodic);
degree = nurbs_surface->GetDegree(); // degree = degree + 1 or +2 ... +3
nbKnots = nurbs_surface->getNBKnot();
if degree = degree + 2 -> Index + 2 and insert new knots or Multiplicities
nurbs_surface->Setknot(Index, knots);// new Knots
Please read the help
//! 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:
//! - K is not such that:
//! Knots(Index - 1) < K < Knots(Index + 1)
//! - M is greater than the degree of this BSpline curve
//! or lower than the previous multiplicity of knot of
//! index Index in the knots table.
//! Standard_OutOfRange if Index is outside the bounds of the knots table.
// formel
nbKnots = (degree + 1) + nbControlPoint
Best regards
Rabih
Fri, 12/14/2012 - 09:35
Dear Rabih
Thanks for your kindly help! But I do not understand how your code decrease the surface's degree?
I mean I need decrease a surface'degree along U direction or along V direction,but how can I do it with the function:
Handle_Geom_BSplineSurface nurbs_surface = new
Geom_BSplineSurface(poles,uknots, vknots, umults, vmults, UDegree, VDegree,IsUPeriodic, IsVPeriodic);
Please help again ,Thanks very much!
Best regards
SunHongLei