lib/toxi/geom/LineStrip3D.js
function( step, doAddFinalVertex ){
			if( doAddFinalVertex !== false ){
				doAddFinalVertex = true;
			}
			var uniform = [];
			if( this.vertices.length < 3 ){
				if( this.vertices.length === 2 ){
					new Line3D( this.vertices[0], this.vertices[1])
						.splitIntoSegments( uniform, step, true );
					if( !doAddFinalVertex ){
						uniform.pop();
					}
				} else {
					return;
				}
			}
			var arcLen = this.getEstimatedArcLength(),
				delta = step / arcLen,
				currIdx = 0,
				currT,
				t,
				p,
				q,
				frac,
				i;

			for( t = 0; t<1.0; t+=delta ){
				currT = t * arcLen;
				while( currT >= this.arcLenIndex[currIdx] ){
					currIdx++;
				}
				p = this.get(currIdx-1);
				q = this.get(currIdx);
				frac = ((currT-this.arcLenIndex[currIdx-1]) / (this.arcLenIndex[currIdx] - this.arcLenIndex[currIdx-1]) );
				i = p.interpolateTo( q, frac );
				uniform.push( i );
			}
			if( doAddFinalVertex ){
				uniform.push( this.get(-1).copy() );
			}
			return uniform;
		}
function( step, doAddFinalVertex ){
			if( doAddFinalVertex !== false ){
				doAddFinalVertex = true;
			}
			var uniform = [];
			if( this.vertices.length < 3 ){
				if( this.vertices.length === 2 ){
					new Line3D( this.vertices[0], this.vertices[1])
						.splitIntoSegments( uniform, step, true );
					if( !doAddFinalVertex ){
						uniform.pop();
					}
				} else {
					return;
				}
			}
			var arcLen = this.getEstimatedArcLength(),
				delta = step / arcLen,
				currIdx = 0,
				currT,
				t,
				p,
				q,
				frac,
				i;

			for( t = 0; t<1.0; t+=delta ){
				currT = t * arcLen;
				while( currT >= this.arcLenIndex[currIdx] ){
					currIdx++;
				}
				p = this.get(currIdx-1);
				q = this.get(currIdx);
				frac = ((currT-this.arcLenIndex[currIdx-1]) / (this.arcLenIndex[currIdx] - this.arcLenIndex[currIdx-1]) );
				i = p.interpolateTo( q, frac );
				uniform.push( i );
			}
			if( doAddFinalVertex ){
				uniform.push( this.get(-1).copy() );
			}
			return uniform;
		}
function ( step , doAddFinalVertex ) { if ( doAddFinalVertex !== false ) { doAddFinalVertex = true ; } var uniform = [ ] ; if ( this . vertices . length < 3 ) { if ( this . vertices . length === 2 ) { new Line3D ( this . vertices [ 0 ] , this . vertices [ 1 ] ) . splitIntoSegments ( uniform , step , true ) ; if ( ! doAddFinalVertex ) { uniform . pop ( ) ; } } else { return ; } } var arcLen = this . getEstimatedArcLength ( ) , delta = step / arcLen , currIdx = 0 , currT , t , p , q , frac , i ; for ( t = 0 ; t < 1.0 ; t += delta ) { currT = t * arcLen ; while ( currT >= this . arcLenIndex [ currIdx ] ) { currIdx ++ ; } p = this . get ( currIdx - 1 ) ; q = this . get ( currIdx ) ; frac = ( ( currT - this . arcLenIndex [ currIdx - 1 ] ) / ( this . arcLenIndex [ currIdx ] - this . arcLenIndex [ currIdx - 1 ] ) ) ; i = p . interpolateTo ( q , frac ) ; uniform . push ( i ) ; } if ( doAddFinalVertex ) { uniform . push ( this . get ( - 1 ) . copy ( ) ) ; } return uniform ; }
Computes a list of points along the spline which are uniformly separated
by the given step distance.

@param {Number} step
@param {Boolean} [doAddFinalVertex] true by default
@return {Vec3D[]} point list
Computes a list of points along the spline which are uniformly separated by the given step distance .