MCPcopy Create free account
hub / github.com/SeaOfNodes/Simple / pathTween

Function pathTween

chapter24/docs/d3-graphviz.js:373–384  ·  view source on GitHub ↗
(points, d1)

Source from the content-addressed store, hash-verified

371 }
372
373 function pathTween(points, d1) {
374 return function () {
375 var pointInterpolators = points.map(function (p) {
376 return d3Interpolate.interpolate([p[0][0], p[0][1]], [p[1][0], p[1][1]]);
377 });
378 return function (t) {
379 return t < 1 ? "M" + pointInterpolators.map(function (p) {
380 return p(t);
381 }).join("L") : d1;
382 };
383 };
384 }
385 function pathTweenPoints(node, d1, precision, precisionIsRelative) {
386 var path0 = node;
387 var path1 = path0.cloneNode();

Callers 1

attributeElementFunction · 0.70

Calls 2

pFunction · 0.70
joinMethod · 0.45

Tested by

no test coverage detected