UNPKG

jointjs

Version:

JavaScript diagramming library

7 lines (4 loc) 617 B
<pre class="docs-method-signature"><code>g.Curve.throughPoints(points)</code></pre> <p>Return an array of cuic bezier curves that defines a curve passing through provided <code>points</code>.</p> <p>This method automatically computes the cubic bezier control points necessary to create a smooth curve with <code>points</code> as intermediary endpoints. An error is thrown if an array with fewer than two points is provided.</p> <p>The result of this function may be provided directly to the <code>g.Path()</code> <a href="#g.Path.constructor">constructor</a> in order to create a Path object from these curves.</p>