Abstract:Due to the limitation of pixel accuracy, there are a large number of sawtooth contour segments in the spectacle lens contour data extracted from the image, which seriously affects the smoothness and accuracy of the contour data. In order to obtain a smooth contour curve, this paper performs segmental fitting processing on the original contour data: firstly, the curvature of each point on the contour is estimated according to the curve direction before and after the target point, and then the contour segments with roughly the same curvature on the contour are calculated according to the least squares. The principle is to fit a circle, and finally the remaining contour segments are conformally fitted based on the Bézier curve. The experimental results show that compared with the existing smoothing algorithm, the segmented fitting algorithm described in this paper has higher accuracy while obtaining a smooth contour curve. It is proved that the segmented fitting algorithm can be used to smooth the contour curve of the spectacle lens.