## 1 Introduction  
In tandem with the burgeoning digital transformation and escalating industrial automation, there is a concomitant surge in the demand for stringent product quality benchmarks. The advent of sophisticated machine vision systems has revolutionized traditional manufacturing paradigms, enabling unparalleled precision and efficiency in automated defect detection across production lines [1, 2, 3]. Scratches on textured surfaces, in particular, represent a critical challenge that significantly impairs product integrity. Consequently, the meticulous identification and analysis of such defects have emerged as a cornerstone in contemporary quality assurance protocols, underscoring the pivotal role of machine vision in maintaining high-quality standards. Machine vision-based capture and image processing analysis are two of the most important methods to achieve high-quality and high-precision defect detection [4, 5]. Analyzed according to the detection method, the commonly used machine vision-based surface defect detection methods can be divided into two-dimensional (2D) methods, three-dimensional (3D) methods, and deep learning techniques. While deep learning stands as a powerful defect detection technology capable of automatically learning defect features, its industrial application faces certain limitations. Although deep learning models can rapidly and accurately detect scratch defect locations after being trained on a large dataset, their industrial implementation is currently constrained by the high costs associated with collecting and training large volumes of sample data. Furthermore, extensive network parameter tuning is required for different material scenarios, which involves a trial-and-error process that is less acceptable in high-precision industrial applications. This is because high-precision industrial settings demand a level of accuracy and stability that cannot be easily achieved without significant investment in time and resources for fine-tuning the deep learning. Two-dimensional detection methods are mainly based on image processing techniques to detect defects, and the specific methods include grayscale symbiotic matrix segmentation [6; 7], the spectral method [8; 9; 10], and the template matching method [11]. Two-dimensional methods are widely used due to their simplicity of use and ease of maneuverability. [PERSON] [12] proposed a method combining an adaptive threshold segmentation algorithm and a mathematical morphological reconstruction of the solution to solve the defect segmentation problem and for the detection of aluminum metal materials. [PERSON] [13] developed a hybrid surface defect detection method for complex and widely varying curved surfaces, which realizes defect detection for different regions through image region segmentation, gradient threshold, and image alignment. [PERSON] [10] propose a vision-based fabric inspection method that is based on the fast Fourier transform and cross-correlation techniques followed by a filter transform, highlighting the defective portions to check the structural regularity features of the fabric image in the spatial domain. However, due to the lack of depth information, 2D methods do not have sufficient reliability and stable robustness. Contrary to the image processing methods that hinge on 2D techniques, providing merely a planar perspective, the inspection methods based on three-dimensional visual measurement offer an all-encompassing perspective of flaws. This perspective encompasses the depth, volume, and spatial orientation of defects, rendering a rich, detailed analysis of surface anomalies paramount. It empowers us to evaluate the severity and position of defects with greater accuracy and nuance [14]. Notably, 3D defect detection techniques, inclusive of those employing structured light [15; 16] and photometric stereo vision [17], demonstrate a reduced susceptibility to inaccuracies engendered by variable lighting conditions.