88 std::vector<ts::rational> ts_controlPoints;
90 ts_controlPoints.push_back(cp.x());
91 ts_controlPoints.push_back(cp.y());
92 ts_controlPoints.push_back(cp.z());
97 catch (std::runtime_error e) {
117 for (
int i = 0; i < nbBeziers; i++) {
118 std::vector<geo::Coordinate> bez;
120 auto j = nbCoordinate * i;
121 auto end = nbCoordinate * (i+1);
129 _beziers.push_back(std::make_shared<Bezier>(bez.at(0),bez.at(1),bez.at(2)));
132 for (
int i = 0; i < nbBeziers; i++) {
133 std::vector<geo::Coordinate> bez;
135 auto j = nbCoordinate * i;
136 auto end = nbCoordinate * (i+1);
145 _beziers.push_back(std::make_shared<CubicBezier>(bez.at(0),bez.at(1),bez.at(2),bez.at(3)));
152 if(bez->boundingBox().inArea(c)) {
const std::vector< Coordinate > _controlPoints
BSpline toBeziers() const
short degree() const
degree, Returns degree of spline
std::vector< BB_CSPtr > _beziers
double fitTolerance() const
Returns the fit point tolerance of the spline.
void populateCurve()
Fills the opennurbs curve with the data from spline constructor.
void trimAtPoint(const geo::Coordinate &c)
const double _fitTolerance
Coordinate nearestPointOnEntity(const Coordinate &coord) const
returns the nearest Point On Entity itself.
const std::vector< Coordinate > _fitPoints
bool closed() const
closed, returns if spline is closed or not
void setCtrlp(const std::vector< rational > ctrlp)
const std::vector< BB_CSPtr > beziers() const
Coordinate nearestPointOnPath(const Coordinate &coord) const
returns the nearest Point On Path
const std::vector< double > & knotPoints() const
Return a vector of knotpoints.
const std::vector< Coordinate > & fitPoints() const
Return a vector of fitpoints.
const std::vector< Coordinate > & controlPoints() const
control_points, Returns Control points of spline
const std::vector< double > _knotPoints