--- layout: posts title: Api - point Namespace ---

Index

Functions

add

average

clone

closest

  • closest(referencePoint: IPoint, pointOptions: IPoint[]): IPoint

distort

  • distort(pointToDistort: IPoint, scaleX: number, scaleY: number): IPoint

fromAngleOnCircle

fromArc

  • Get the two end points of an arc path.

    Parameters

    Returns IPoint[]

    Array with 2 elements: [0] is the point object corresponding to the start angle, [1] is the point object corresponding to the end angle.

fromPathEnds

  • fromPathEnds(pathContext: IPath, pathOffset?: IPoint): IPoint[]
  • Get the two end points of a path.

    Parameters

    • pathContext: IPath

      The path object.

    • Optional pathOffset: IPoint

    Returns IPoint[]

    Array with 2 elements: [0] is the point object corresponding to the origin, [1] is the point object corresponding to the end.

fromPolar

  • fromPolar(angleInRadians: number, radius: number): IPoint

fromSlopeIntersection

middle

  • Get the middle point of a path.

    Parameters

    • pathContext: IPath

      The path object.

    • Default value ratio: number = 0.5

      Optional ratio (between 0 and 1) of point along the path. Default is .5 for middle.

    Returns IPoint

    Point on the path, in the middle of the path.

mirror

  • mirror(pointToMirror: IPoint, mirrorX: boolean, mirrorY: boolean): IPoint

rotate

rounded

scale

subtract

zero

Generated using TypeDoc