MCPcopy
hub / github.com/stemkoski/stemkoski.github.com / interpolate

Function interpolate

Three.js/js/Three59dev.js:5985–5992  ·  view source on GitHub ↗
( p0, p1, p2, p3, t, t2, t3 )

Source from the content-addressed store, hash-verified

5983 // Catmull-Rom
5984
5985 function interpolate( p0, p1, p2, p3, t, t2, t3 ) {
5986
5987 var v0 = ( p2 - p0 ) * 0.5,
5988 v1 = ( p3 - p1 ) * 0.5;
5989
5990 return ( 2 * ( p1 - p2 ) + v0 + v1 ) * t3 + ( - 3 * ( p1 - p2 ) - 2 * v0 - v1 ) * t2 + v0 * t + p1;
5991
5992 };
5993
5994};
5995

Callers 1

Three59dev.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected