#include <BasisFunction.h>
Public Member Functions | |
| BasisFunction (int _numberOfControlPoints, int _splinePoints) | |
| ~BasisFunction () | |
| int | getNumberOfSplinePoints () |
| double | getValue (int i, int splinePoint) |
Private Member Functions | |
| void | initKnotVector () |
| void | initValueArray () |
| double | coxRecursion (int i, int p, double u) |
Private Attributes | |
| int | numberOfControlPoints |
| int | splinePoints |
| int | p |
| int | n |
| int * | knotVector |
| double ** | valueArray |
Static Private Attributes | |
| static log4cxx::LoggerPtr | logger |
| BasisFunction::BasisFunction | ( | int | _numberOfControlPoints, | |
| int | _splinePoints | |||
| ) |
Constructs a new BasisFunction object
| _numberOfControlPoints | Number of control points for the B-Spline | |
| _splinePoints | Number of points in the line strip to draw the B-Spline |
| BasisFunction::~BasisFunction | ( | ) |
Destroys the object
| double BasisFunction::coxRecursion | ( | int | i, | |
| int | p, | |||
| double | u | |||
| ) | [private] |
Calculates the value of the recursion formula of Cox/De Boor
| i | Index of the function inside [1, n-p] | |
| p | degree parameter, equal to degree-1 | |
| u | running parameter to define the place where the function should be evaluated, must be inside the range of the knot vector |
| int BasisFunction::getNumberOfSplinePoints | ( | ) |
Returns the number of spline points to draw the B-Spline
| double BasisFunction::getValue | ( | int | i, | |
| int | splinePoint | |||
| ) |
Returns the value of the i-th BasisFunction at the splinePoint-th Splinepoint
| i | Index of the BasisFunction starting at 0 | |
| splinePoint | Index of the Splinepoint starting at 0 |
| void BasisFunction::initKnotVector | ( | ) | [private] |
Initializes the knot vector to be a uniform knot vector
| void BasisFunction::initValueArray | ( | ) | [private] |
Initializes the value array by filling it with the weights for all control points at every spline point
int* BasisFunction::knotVector [private] |
The uniform knot vector
LoggerPtr BasisFunction::logger [static, private] |
int BasisFunction::n [private] |
Length of the knot vector, must be at least 2*p
int BasisFunction::numberOfControlPoints [private] |
Number of control points for the B-Spline
int BasisFunction::p [private] |
Degree Parameter, is equal to degree - 1
int BasisFunction::splinePoints [private] |
Number of points in the line strip to draw the B-Spline
double** BasisFunction::valueArray [private] |
2-dim Array with corresponding weights of the control points for every splinePoint
1.5.7.1