Abstract:In order to cut subscriber identification module (SIM)card slot via laser cutting with coaxial visual sensing system, this paper presents an algorithm for detecting the specific straight lines. This algorithm makes full use of the gradient magnitude and direction information, and selects the seed points based on the difference of gradient modulus values between adjacent pixels. Then the line-support regions are found via growing a region from the seed points using gradient angle measure. The line segment can be determined based on the gradient modulus values of pixels in the line-support regions. The numerical experiments demonstrate that the proposed algorithm has super performance of high detection precision, good robustness and low calculation cost, thus meeting the application requirements of industry detection.