java circle recognition from an arraylist of points

前端 未结 4 1723
情话喂你
情话喂你 2020-12-19 18:07

I currently have an arraylist of points from a freehand drawing on a canvas. I was wondering if there is a simple algorithm to detect if that shape represents a circle.I hav

4条回答
  •  情深已故
    2020-12-19 18:54

    Maybe this answer can give you some ideas: https://stackoverflow.com/a/940041/12860

    In short: calculate the second derivative. If it is quite constand, it is probably a circle.

提交回复
热议问题