fourierknots/fourier_syn.cpp
void FourierKnot::toCurve(const int sampling, Curve<Vector3> *curve) {
  float isampling = 1./(float)sampling, s;
  for (int i=0;i<sampling;++i) {
    s = (float)i*isampling;
    // Tangent gets normalized in biarc constructor
    curve->append((*this)(s),this->prime(s));
  }
}
// sample our fourier knot and put that in initialized
// pointer to Curve curve
sample our fourier knot and put that in initialized
pointer to Curve curve
sample our fourier knot and put that in initialized pointer to Curve curve
void FourierKnot::toCurve(const int sampling, Curve<Vector3> *curve) {
  float isampling = 1./(float)sampling, s;
  for (int i=0;i<sampling;++i) {
    s = (float)i*isampling;
    curve->append((*this)(s),this->prime(s));
  }
}
void FourierKnot :: toCurve ( const int sampling , Curve < Vector3 > * curve ) { float isampling = 1. / ( float ) sampling , s ; for ( int i = 0 ; i < sampling ; ++ i ) { s = ( float ) i * isampling ; curve -> append ( ( * this ) ( s ) , this -> prime ( s ) ) ; } }
sample our fourier knot and put that in initialized
pointer to Curve curve
sample our fourier knot and put that in initialized pointer to Curve curve
// Tangent gets normalized in biarc constructor