Skip to main content

Home > @jsplumbtoolkit/browser-ui > boxIntersection

boxIntersection() function

Calculates all intersections of the given box with the given curve.

Signature:

export declare function boxIntersection(x: number, y: number, w: number, h: number, curve: Curve): Array<PointXY>;

Parameters

ParameterTypeDescription
xnumberX position of top left corner of box
ynumberY position of top left corner of box
wnumberwidth of box
hnumberheight of box
curveCurve

Returns:

Array<PointXY>

Array of intersecting points.