How to calculate rounded corners for a polygon?
Some geometry with Paint: 0. You have a corner: 1. You know the coordinates of corner points, let it be P1, P2 and P: 2. Now you can get vectors from points and angle between vectors: angle = atan(PY – P1Y, PX – P1X) – atan(PY – P2Y, PX – P2X) 3. Get the length … Read more