Skip to content
pixi-silk
GitHub repository
Interface

PathHitPoint

import type { PathHitPoint } from 'pixi-silk/path';

The closest point of a path to a point, as nearestOnPath finds it.

Properties#

PropertyTypeDescriptionDefined in
distancenumberDistance from the query point, in the path’s units.path.ts:61
segmentnumberSegment index: segment i runs from anchor i to the next one.path.ts:53
tnumberPosition along the segment, 0 to 1.path.ts:55
xnumberClosest point x.path.ts:57
ynumberClosest point y.path.ts:59