Computes the 2D distance from the nearest point.
The renderer instance.
The snap data array.
The x-coordinate.
The y-coordinate.
The distance from the nearest point.
Computes the 2D distance from the nearest point.