UNPKG

@mlightcad/geometry-engine

Version:

The geometry-engine package provides comprehensive geometric entities, mathematical operations, and transformations for 2D and 3D space. This package mimics AutoCAD ObjectARX's AcGe (Geometry) classes and provides the mathematical foundation for CAD opera

59 lines 1.71 kB
import { AcGeEllipseArc2d, AcGeSpline3d } from '../geometry'; import { AcGeBox2d, AcGeMatrix2d, AcGePoint2d } from '../math'; import { AcGeCircArc2d } from './AcGeCircArc2d'; import { AcGeCurve2d } from './AcGeCurve2d'; import { AcGeLine2d } from './AcGeLine2d'; export type AcGeBoundaryEdgeType = AcGeLine2d | AcGeCircArc2d | AcGeSpline3d | AcGeEllipseArc2d; /** * The class representing one closed loop created by connected edges, which can be line, circular arc, * ellipse arc, or spline. */ export declare class AcGeLoop2d extends AcGeCurve2d { private _curves; /** * Create one loop by connected curves * @param curves Input one array of connected curves */ constructor(curves?: Array<AcGeBoundaryEdgeType>); get curves(): ReadonlyArray<AcGeBoundaryEdgeType>; /** * Append an edge to this loop * @param curve */ add(curve: AcGeBoundaryEdgeType): void; /** * The number of edges in this loop */ get numberOfEdges(): number; /** * Start point of this polyline */ get startPoint(): AcGePoint2d; /** * End point of this polyline */ get endPoint(): AcGePoint2d; /** * @inheritdoc */ get length(): number; /** * @inheritdoc */ calculateBoundingBox(): AcGeBox2d; /** * @inheritdoc */ transform(_matrix: AcGeMatrix2d): this; /** * @inheritdoc */ get closed(): boolean; /** * Return boundary points of this area * @param numPoints Input the nubmer of points returned for arc segmentation * @returns Return points */ getPoints(numPoints: number): AcGePoint2d[]; } //# sourceMappingURL=AcGeLoop2d.d.ts.map