16 template <
int N,
typename Real>
50 virtual void Evaluate(Real
t,
unsigned int maxOrder,
64 template <
int N,
typename Real>
105 template <
int N,
typename Real>
111 template <
int N,
typename Real>
114 return static_cast<int>(
mControls.size());
117 template <
int N,
typename Real>
123 template <
int N,
typename Real>
129 template <
int N,
typename Real>
135 template <
int N,
typename Real>
141 template <
int N,
typename Real>
150 template <
int N,
typename Real>
164 template <
int N,
typename Real>
173 template <
int N,
typename Real>
187 template <
int N,
typename Real>
208 Real invW = ((Real)1) /
w;
209 values[0] = invW * X;
216 Compute(1, imin, imax, XDer1, wDer1);
217 values[1] = invW * (XDer1 - wDer1 * values[0]);
224 Compute(2, imin, imax, XDer2, wDer2);
225 values[2] = invW * (XDer2 - ((Real)2) * wDer1 * values[1] -
233 Compute(3, imin, imax, XDer3, wDer3);
234 values[3] = invW * (XDer3 - ((Real)3) * wDer1 * values[2] -
235 ((Real)3) * wDer2 * values[1] - wDer3 * values[0]);
245 template <
int N,
typename Real>
256 for (
int i = imin; i <= imax; ++i)
258 int j = (i >= numControls ? i - numControls : i);
GLfixed GLfixed GLint GLint order
std::vector< Vector< N, Real > > mControls
void SetControl(int i, Vector< N, Real > const &control)
Vector< N, Real > const & GetControl(int i) const
std::vector< Real > mTime
GLuint GLuint GLfloat weight
GLenum GLsizei GLsizei GLint * values
BasisFunction< Real > const & GetBasisFunction() const
GLubyte GLubyte GLubyte GLubyte w
virtual void Evaluate(Real t, unsigned int maxOrder, Vector< N, Real > values[4]) const
std::vector< Real > mWeights
Vector< N, Real > const * GetControls() const
Real const * GetWeights() const
NURBSCurve(BasisFunctionInput< Real > const &input, Vector< N, Real > const *controls, Real const *weights)
void SetWeight(int i, Real weight)
Real const & GetWeight(int i) const
int GetNumControls() const
GLenum GLenum GLenum input
BasisFunction< Real > mBasisFunction
void Compute(unsigned int order, int imin, int imax, Vector< N, Real > &X, Real &w) const