import { PointsWithDistance } from './points-with-distance.js'; /** * Calculates and returns an accurate approximation to the minimum distance * between the two given bezier curves. (Actually returns the parameter values * from which the distance can then easily be calculated.) * * * partially based off [Computing the Hausdorff distance between two sets of parametric curves](https://www.semanticscholar.org/paper/COMPUTING-THE-HAUSDORFF-DISTANCE-BETWEEN-TWO-SETS-Kim-McLean/d2bd6529c4b118e389e1db209d8f1bf7467f9016) * * @param A a bezier curve given by an ordered array of its * control points e.g. `[[0,0],[1,1],[2,1],[2,0]]` * @param B a bezier curve given by an ordered array of its * control points e.g. `[[0,0],[1,1],[2,1],[2,0]]` * @param tolerance optional; defaults to `Math.max(maxAbsCoordinate(A),maxAbsCoordinate(B))/1000_000`; * if the calculated absolute error bound is less than this, the result is * returned; this is *not* a hard tolerance and the bound can be less * accurate in hard cases (due to the `maxIterations` parameter). Luckily * however, specifically the upper bound will be very accurate due to * its fast convergence in such hard cases (see the paper) * @param maxIterations optional; defaults to `50`; if the desired guaranteed error bound * has not been achieved after `maxIterations` then the result will be returned * * @doc mdx */ declare function closestPointsBetweenBeziers(A: number[][], B: number[][], tolerance?: number, maxIterations?: number): PointsWithDistance[]; export { closestPointsBetweenBeziers };