AcGeNurbCurve3d( int degree, const AcGeKnotVector& knots, const AcGePoint3dArray& cntrlPnts, const AcGeDoubleArray& weights, Adesk::Boolean isPeriodic = Adesk::kFalse );
|
Parameters |
Description |
|
int degree |
Input degree of spline |
|
const AcGeKnotVector& knots |
Input array of knot values, partitioning spline's domain into rational pieces |
|
const AcGePoint3dArray& cntrlPnts |
Input array of 3D control points |
|
const AcGeDoubleArray& weights |
Input array of weight values |
|
Adesk::Boolean isPeriodic = Adesk::kFalse |
Input flag indicating if spline is a periodic |
Constructs a 3D rational spline by a knot vector, control points, and weights. If the spline is rational, control points and weights must have same length.
If isPeriodic = Adesk::kFalse then the length of knot vector must be greater than the length of the control array by degree+1.
If isPeriodic = Adesk::kTrue then one of the following must be true:
When creating periodic spline, we accept two data formats:
The knot vector should contains distinct knot values. For example, if we want to create a periodic spline with four control points, the knot vector could be (0, 1, 2, 3, 4).