import * as g from '../classes'; import { IntervalTree } from '../data_structures/interval-tree'; export declare function reverse(result: [number, g.Segment]): [number, g.Segment]; /** * Calculate distance and shortest segment between points */ export declare function point2point(a: g.Point, b: g.Point): [number, g.Segment]; /** * Calculate distance and shortest segment between point and line */ export declare function point2line(pt: g.Point, line: g.Line): [number, g.Segment]; /** * Calculate distance and shortest segment between point and circle */ export declare function point2circle(pt: g.Point, circle: g.Circle): [number, g.Segment]; /** * Calculate distance and shortest segment between point and segment */ export declare function point2segment(pt: g.Point, segment: g.Segment): [number, g.Segment]; /** * Calculate distance and shortest segment between point and arc */ export declare function point2arc(pt: g.Point, arc: g.Arc): [number, g.Segment]; /** * Calculate distance and shortest segment between segment and point */ export declare function segment2point(segment: g.Segment, point: g.Point): [number, g.Segment]; /** * Calculate distance and shortest segment between segment and line */ export declare function segment2line(seg: g.Segment, line: g.Line): [number, g.Segment]; /** * Calculate distance and shortest segment between two segments * @param seg1 * @param seg2 * @returns {Number | Segment} - distance and shortest segment */ export declare function segment2segment(seg1: any, seg2: any): [number, g.Segment]; /** * Calculate distance and shortest segment between segment and circle * @param seg * @param circle * @returns {Number | Segment} - distance and shortest segment */ export declare function segment2circle(seg: g.Segment, circle: g.Circle): [number, g.Segment]; /** * Calculate distance and shortest segment between segment and arc * @param seg * @param arc * @returns {Number | Segment} - distance and shortest segment */ export declare function segment2arc(seg: any, arc: any): [number, g.Segment]; /** * Calculate distance and shortest segment between two circles * @param circle1 * @param circle2 * @returns {Number | Segment} - distance and shortest segment */ export declare function circle2circle(circle1: any, circle2: any): [number, g.Segment]; /** * Calculate distance and shortest segment between two circles * @param circle * @param line * @returns {Number | Segment} - distance and shortest segment */ export declare function circle2line(circle: any, line: any): [number, g.Segment]; /** * Calculate distance and shortest segment between an arc and a point */ export declare function arc2point(arc: g.Arc, point: g.Point): [number, g.Segment]; /** * Calculate distance and shortest segment between an arc and a point */ export declare function arc2segment(arc: g.Arc, segment: g.Segment): [number, g.Segment]; /** * Calculate distance and shortest segment between arc and line * @param arc * @param line * @returns {Number | Segment} - distance and shortest segment */ export declare function arc2line(arc: any, line: any): [number, g.Segment]; /** * Calculate distance and shortest segment between arc and circle * @param arc * @param circle2 * @returns {Number | Segment} - distance and shortest segment */ export declare function arc2circle(arc: any, circle2: any): [number, g.Segment]; /** * Calculate distance and shortest segment between two arcs * @param arc1 * @param arc2 * @returns {Number | Segment} - distance and shortest segment */ export declare function arc2arc(arc1: any, arc2: any): [number, g.Segment]; /** * Calculate distance and shortest segment between point and polygon * @param point * @param polygon * @returns {Number | Segment} - distance and shortest segment */ export declare function point2polygon(point: any, polygon: any): [number, g.Segment]; export declare function shape2polygon(shape: any, polygon: any): [number, g.Segment]; /** * Calculate distance and shortest segment between two polygons * @param polygon1 * @param polygon2 * @returns {Number | Segment} - distance and shortest segment */ export declare function polygon2polygon(polygon1: any, polygon2: any): [number, g.Segment]; /** * Returns [mindist, maxdist] array of squared minimal and maximal distance between boxes * Minimal distance by x is * (box2.xmin - box1.xmax), if box1 is left to box2 * (box1.xmin - box2.xmax), if box2 is left to box1 * 0, if box1 and box2 are intersected by x * Minimal distance by y is defined in the same way * * Maximal distance is estimated as a sum of squared dimensions of the merged box * * @param box1 * @param box2 */ export declare function box2box_minmax(box1: any, box2: any): readonly [number, number]; export declare function minmax_tree_process_level(shape: any, level: any, min_stop: any, tree: any): any; /** * Calculates sorted tree of [mindist, maxdist] intervals between query shape * and shapes of the planar set. * @param shape * @param set */ export declare function minmax_tree(shape: any, set: any, min_stop: any): IntervalTree; export declare function minmax_tree_calc_distance(shape: any, node: any, min_dist_and_segment: any): any[]; /** * Calculates distance between shape and Planar Set of shapes * @param shape * @param {PlanarSet} set * @param {Number} min_stop */ export declare function shape2planarSet(shape: any, set: any, min_stop?: number): [number, g.Segment]; export declare function sort(dist_and_segment: any): void; export declare function distance(shape1: any, shape2: any): any; export declare function pythagore(width: number, height: number): number; //# sourceMappingURL=distance.d.ts.map