I originally asked this on AI StackExchange here, but since it\'s an algorithm question it might be more suitable here.
I have a shape on a 2D plane, and I want to dr