Action:
|
Adds a knot to a B-spline at a given parameter value.
|
|
Prototype:
|
int bs2_curve_add_knot (
|
|
|
bs2_curve bs2,
|
// given curve
|
|
|
double new_knot_param,
|
// returned new knot
|
|
|
|
|
// parameter value
|
|
|
int mult_req,
|
// returned new knot's
|
|
|
|
|
// multiplicity
|
|
|
double knot_tol,
|
// returned knot
|
|
|
|
|
// tolerance
|
|
|
const SPApar_pos&
|
// new knot surface
|
|
|
|
new_knot_uv
|
// par_pos
|
|
|
|
=*(SPApar_pos*)NULL_REF,
|
|
|
const SPApar_vec&
|
// 2-space curve
|
|
|
|
new_knot_deriv_below// deriv below new knot
|
|
|
|
=*(SPApar_vec*)NULL_REF,
|
|
|
const SPApar_vec&
|
// deriv above
|
|
|
|
new_knot_deriv_above
|
// new knot
|
|
|
|
=*(SPApar_vec*)NULL_REF
|
|
|
);
|
|
Includes:
|
#include "kernel/acis.hxx"
|
|
#include "baseutil/vector/param.hxx"
|
|
#include "kernel/spline/bs2_crv/bs2curve.hxx"
|
|
#include "kernel/spline/sg_bs2c/sps2crtn.hxx"
|
|
Description:
|
Add a knot to a B-spline at a given parameter value. The routine returns the number of knots added. If the knot value to be added is an existing knot, the knot is inserted, provided the multiplicity of the current knot does not exceed the degree of the spline curve. The equality of the knots are tested using the tolerance given as input. The knot value must be within the parameter range of the input B-spline. If the
SPApar_pos for the new knot is supplied, the new pcurve is made to have its Bezier form and then the new knot is made to lie at this point. If the 2D curve derivative is supplied, the pcurve is forced to agree with this at the new knot. At present, this is only implemented for curves of degree 3 (which is most curves).
|
|
Library:
|
kernel
|
|
Filename:
|
kern/kernel/spline/sg_bs2c/sps2crtn.hxx
|
|
Effect:
|
Changes model
|