Signed distance function

Previous: Ray marching

A signed distnace function returns the distance to the boundary of an object (shape) from a given point. If the point is inside the object, then this value will be negative.