DG Kernel (ActiveX) Documentation


Skip Navigation Links.
Start page
Quick Start
Search Page
Installation
What is new
Upgrading Native Apps
Licensing
Collapse ModelsModels
Collapse DG Kernel ControlsDG Kernel Controls
Collapse API ReferenceAPI Reference
Interface List
Vector Space
Collapse General GeometryGeneral Geometry
Collapse ModelModel
Collapse ViewView
Collapse General ComputingGeneral Computing
Collapse ViewsViews
Collapse Samples and TutorialsSamples and Tutorials
Collapse GraphicsGraphics
Collapse Math ObjectsMath Objects
Collapse DeprecatedDeprecated
Redistribution
Model Viewer
Open Source
Support
Skip Navigation Links Go to DGKC docs Search Documentation


IPartialSplineProps_DG Interface

Used to access per parameter properties of a BSpline surface via IBSplineSurface_DG.GetAxialSplineProps()

Indices are 0-based

See also: IBSplineSurface_DG, IBSplineCurve_DG

Properties

int Degree

Methods

GetKnotCount
GetKnot
GetKnots
SetKnot
SetKnot
SetKnots
GetMultiplicity
GetMultiplicities
SetMultiplicity
SetMultiplicity1
GetPoleCount
IsClosed
IsPeriodic
SetPeriodic
IsRational
GetEndParameter
InsertKnot
InsertKnots
RemoveKnot
Reverse
SetRange
SetOrigin
GetEndKnotIndex
GetKnotSequence
GetKnotDistributionType
FindParameter

int GetKnotCount()


double GetKnot(int index)


IArrayDouble_DG GetKnots()


void SetKnot(int index, double knot)


void SetKnot(int index, double knot, int multiplicity)

multiplicity must be <= degree and greater than the previous multiplicity of the knot.

The index must be in [0, GetKnotCount()-1] range.


void SetKnots(IArrayDouble_DG knots)


int GetMultiplicity(int indexKnot)

The indexKnot must be in [0, GetKnotCount()-1] range.


IArrayInt_DG GetMultiplicities()


void SetMultiplicity(int indexKnot, int multiplicity)

Increases multiplicity of the knot. multiplicity must be greater than the previous multiplicity and <= degree of the surface in this parametric direction.

The indexKnot must be in [0, GetKnotCount()-1] range.


void SetMultiplicity1(int indexKnot0, int indexKnot1, int multiplicity)

Increases multiplicity of knots with indices in the [i0, i1] range. multiplicity must be greater than the previous multiplicity and <= degree of the surface in this parametric direction.

The indexKnot0 and indexKnot1 must be in [0, GetKnotCount()-1] range.


int GetPoleCount()


bool IsClosed()


bool IsPeriodic()


void SetPeriodic(bool periodic)


bool IsRational()


double GetEndParameter(bool first)


void InsertKnot(double u, int multiplicity, double tolerance, bool add)

If the knot (up to tolerance) already exists in the table, its multiplicity increased by multiplicity, if add is true or increased to multiplicity, if add is false.
multiplicity must be a positive number not greater than the degree.


void InsertKnots(IArrayDouble_DG knots, IArrayInt_DG multiplicities, double tolerance, bool add)

If a knot[i] (up to tolerance) already exists in the table, its multiplicity increased by multiplicities[i], if add is true or increased to multiplicities[i], if add is false.
multiplicities must contain only positive numbers not greater than the degree.


void RemoveKnot(int index, int multiplicity, double tolerance)

Reduces multiplicity of the knot to the specified value. If multiplicity is 0, the knot is removed.

The index must be in [0, GetKnotCount()-1] range.


void Reverse()

Changes orientation of this BSpline surface in the parametric direction. The bounds of the surface are not changed, but the given parametric direction is reversed. Hence the orientation of the surface is reversed. The knots and poles tables are modified.


void SetRange(double min, double max)

Segments this curve between min and max. Either of these values can be outside the bounds of the curve, but max must be greater than min. All data structures of this curve are modified, but the knots located between min and max are retained. The degree of the curve is not modified.

Warnings : Even if this curve is not closed it can become closed after the segmentation for example if min or max are out of the bounds of the curve or if the curve makes a loop.


void SetOrigin(int indexKnot)

Assigns the knot to be the origin of this periodic BSpline surface in this parametric direction. As a consequence, the knots and poles are modified.
Raises an exception if this BSpline surface is not periodic in the parametric direction or index is outside the bounds.

The indexKnot must be in [0, GetKnotCount()-1] range.


int GetEndKnotIndex(bool first)


IArrayDouble_DG GetKnotSequence()


int GetKnotDistributionType()

Returns: 0 (Non Uniform), 1 (Uniform), 2 (Quasi Uniform) or 3 (Piecewise Bezier).

If all the knots differ by a positive constant from the preceding knot, the BSpline surface can be :
Uniform if all the knots are of multiplicity 1;
QuasiUniform, if all the knots are of multiplicity 1, except for the first and last knot, which have multiplicity degree + 1;
PiecewiseBezier if the first and last knots have multiplicity degree + 1 and if interior knots have multiplicity degree.
Otherwise the surface is non uniform in the direction.


void FindParameter(double u, double tolerance, out int i0, out int i1, bool withKnotRepetition)

If withKnotRepetition is false, returns in i0 a 0-based index of the first knot, which is not greater than u. If u counsides with the knot up to the tolerance, i1 will be set equal to i0, otherwise i1 will be set equal to i0 + 1. If u is smaller than the first knot less tolerance, i0 = -1, i1 = 0 is returned. If u is greater than the last knot plus tolerance, i0 = 'size of the knot array', i1 = i0 + 1 is returned.

If withKnotRepetition is true, the knot array in the above is considered modified by inserting copies of knots with multiplicity greater than one.