nearestOnPath
import { nearestOnPath } from 'pixi-silk/path';
function nearestOnPath(path: BezierPath, p: Vec): PathHitPoint | null;
The closest point of the whole path to p, or null for a path without segments.
Parameters#
| Parameter | Type |
|---|---|
path | BezierPath |
p | Vec |
Returns#
PathHitPoint | null