You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
1.1 KiB

4 months ago
import type { PathArray } from '@antv/util';
import type { Point } from '../types';
/**
* <zh/> points path
*
* <en/> points transform path.
* @param points Point[]
* @param isClose boolean
* @returns path string[][]
*/
export declare function pointsToPath(points: Point[], isClose?: boolean): PathArray;
/**
* <zh/>
*
* <en/> Convert a path string to an array of path segments.
* @param path - <zh/> | <en/> path string
* @returns <zh/> | <en/> path segment array
*/
export declare function parsePath(path: string): PathArray;
/**
* <zh/>
*
* <en/> Convert path to points array
* @param path - <zh/> <en/> path array
* @returns
*/
export declare function pathToPoints(path: string | PathArray): Point[];
/**
* <zh/> 线
*
* <en/> Generate smooth closed curves
* @param points - <zh/> | <en/> points
* @returns <zh/> 线 | <en/> smooth closed curves
*/
export declare const getClosedSpline: (points: Point[]) => PathArray;