Trying to figure out if a curved path can constitute a portion of a perfect circle
Hello community,
I've been trying to use scripting to find out if a user-selected curved path (formed from two anchor points) can be part of a perfect circle, and if so, draw the circle with the appropriate circumference on the artboard.
It's a pretty complex topic that (in my mind) requires some mathematical knowledge to figure out. I've found the following article that does a pretty good job explaining how a circle can be approximated based on a cubic Bezier curve. However, I got stuck pretty early on because I didn't know exactly how to translate the two anchor point path I have on the screen into the four control points that form a cubic Bezier curve. Especially when it comes to referencing such coordinates via scripting.
Hoping that some of your bright minds might want to jump in on the challenge!
