detecting shapes in a bitmap

后端 未结 1 1802
轻奢々
轻奢々 2021-01-23 02:40

looking for a good algorithm to do the following: I have a b&w image comprised solely of polygonal shapes, which i got by scanning in a document. I would like to find all th

相关标签:
1条回答
  • 2021-01-23 03:18

    I would start with a connected component labeling in order to separate the different polygons.

    A simple solution for smoothing would be to use opening and a closing, but if the polygons are REALLY thin, it may cut them. A more complex (but better) solution, would be to extract the contour as a parametric function (x(t),y(t)) and to smooth it with a 1D gaussian convolution.

    0 讨论(0)
提交回复
热议问题