calc-quad-offset-x-point
function calcQuadOffsetCurveXPoint(ps: number[][], D: number): number[] | undefined
Defined in offset/calc-quad-offset-x-point.ts:27
Calculates and returns the point (as the t value) of intersection of the
offset curves of a quadratic bezier curve (if any).
-
returns
undefinedif no such point exist -
offset is in normal direction of curve as
tgoes from0to1 -
offset can be negative
Parameters:
| Name | Type | Description |
|---|---|---|
ps | number[][] | an order 1,2 or 3 bezier curve given as an ordered array of its control point coordinates, e.g. [[0,0], [1,1], [2,1], [2,0]] |
D | number | distance of offset curve (can be negative) |