import { Box } from './Box'; import { Point } from './Point'; import { Matrix } from './Matrix'; import { Segment } from './Segment'; import { Vector } from './Vector'; import { Shape, ShapeTag } from './Shape'; /** * Class representing a circular arc */ export declare class Arc extends Shape { static EMPTY: Readonly; /** * Arc center */ pc: Point; /** * Arc X radius */ r: number; /** * Arc start angle in radians */ startAngle: number; /** * Arc end angle in radians */ endAngle: number; /** * Arc orientation */ clockwise: boolean; _start: Point | null; _end: Point | null; constructor(arc: Arc); constructor(pc: Point, r: number, startAngle: number, endAngle: number, cw?: boolean); /** * Return new cloned instance of arc */ clone(): Arc; get tag(): ShapeTag; /** * Get bounding box of the arc */ get box(): Box; get center(): Point; /** * Get sweep angle in radians. Sweep angle is non-negative number from 0 to TAU */ get sweep(): number; /** * Get start point of arc */ get start(): Point; set start(p: Point); /** * Get end point of arc */ get end(): Point; set end(p: Point); get vertices(): Point[]; /** * Get arc length */ get length(): number; /** * Returns true if arc contains point, false otherwise */ contains(pt: Point): boolean; /** * When given point belongs to arc, return array of two arcs split by this point. If points is incident * to start or end point of the arc, return clone of the arc. If point does not belong to the arcs, return * empty array. */ split(pt: Point): (Arc | null)[]; splitAtLength(length: number): Arc[]; /** * Return middle point of the arc */ middle(): Point; /** * Get point at given length * @param length - The length along the arc */ pointAtLength(length: number): Point; /** * Returns chord height ("sagitta") of the arc */ chordHeight(): number; /** * Returns array of intersection points between arc and other shape * @param shape Shape of the one of supported types
*/ intersect(shape: Shape): Point[]; /** * Calculate distance and shortest segment from arc to shape and return array [distance, shortest segment] * @param shape Shape of the one of supported types Point, Line, Circle, Segment, Arc, Polygon or Planar Set * @returns distance from arc to shape * @returns shortest segment between arc and shape (started at arc, ended at shape) */ distanceTo(shape: Shape): [number, Segment]; /** * Breaks arc in extreme point 0, pi/2, pi, 3*pi/2 and returns array of sub-arcs */ breakToFunctional(): Arc[]; /** * Return tangent unit vector in the start point in the direction from start to end */ tangentInStart(): Vector; /** * Return tangent unit vector in the end point in the direction from end to start */ tangentInEnd(): Vector; /** * Returns new arc with swapped start and end angles and reversed direction */ reverse(): Arc; /** * Return new arc transformed using affine transformation matrix
*/ transform(matrix?: Matrix): Arc; static arcSE(center: any, start: any, end: any, clockwise: any): Arc; definiteIntegral(ymin?: number): number; circularSegmentDefiniteIntegral(ymin: number): number; circularSegmentArea(): number; /** * Sort given array of points from arc start to end, assuming all points lay on the arc */ sortPoints(pts: Point[]): Point[]; get name(): string; } /** * Function to create arc equivalent to "new" constructor */ export declare const arc: (pc: Point, r: number, startAngle: number, endAngle: number, cw?: boolean) => Arc; //# sourceMappingURL=Arc.d.ts.map