distance

open fun distance(p: Point): Double

Compute the distance to the shortest point to the edge (SDF). Negative inside. Positive outside.


open fun distance(ml: Matrix, p: Point, mr: Matrix): Double

Deprecated

Untested yet

ml transformation matrix of this Shape2D, mr transformation matrix of the point p