| Three-dimensional reconstruction technology is an interdisciplinary technology that combines computer vision,optics and electronics,etc.It can reconstruct the three-dimensional information of the target object without contact,efficiently and accurately,and is widely used in industrial inspection,medical health,virtual reality and the protection of cultural relics and other fields.With the continuous development of science and technology,the demand for fast and accurate three-dimensional data acquisition of target objects is gradually increasing,and high-precision three-dimensional reconstruction has become a current research hotspot.This paper studies the three-dimensional reconstruction technology combining structured light and binocular vision.The main research contents are as follows:(1)Design the system model of binocular structured light scanner,conduct feasibility analysis,and select hardware according to the system model to build a hardware system.(2)In-depth analysis of camera imaging principles and system calibration methods,using Zhang Zhengyou calibration method to conduct camera calibration experiments;research binocular epipolar correction principles,and use camera calibration parameters to correct images.(3)In the gray code line-shift structured light three-dimensional reconstruction method,a sub-pixel edge detection algorithm based on quadratic optimization is proposed to solve the problem of large fluctuations in fringe edge extraction results: firstly,the pixel edge curve is extracted by the Canny edge detection algorithm,and then the sub-pixel edge is obtained by fitting the positive and negative stripe curves,and finally the sub-pixel edge is optimized by three-spline interpolation method and sliding window method.Aiming at the problem of decoding errors caused by edge location failure,a layered decoding algorithm based on edge curves is proposed: firstly,the decoding space is established hierarchically according to the projection order,then the decoding area is divided according to the fringe edge curves,and finally all edge points are decoded,and The code value that appears most frequently in each decoding area is taken as the code value of all edge points in the area.This paper conducts three-dimensional reconstruction experiments on standard plane and complex models,and the results show that this method can effectively and accurately reconstruct the three-dimensional information of the target object.(4)In the Gray code line-shift structured light three-dimensional reconstruction method,aiming at the problem of phase jump in the absolute phase,a Gray code phase unwrapping algorithm based on secondary correction is proposed: firstly,the phase is calculated by the traditional Gray code phase unwrapping algorithm,then,the absolute phase is corrected for the first time according to the fringe order distribution characteristics,and finally the phase is corrected for the second time according to the distance threshold.In order to improve the matching accuracy and efficiency,a phase matching algorithm based on SSD and fringe order is proposed: first calculate the SSD cost of each point in the left and right absolute phase maps,then establish vertical constraints according to the fringe order,and adopt the winner-take-all strategy Calculate pixel-level disparity,and finally calculate sub-pixel disparity by quadratic fitting curve.The three-dimensional reconstruction experiments are carried out on the standard plane and complex models,and the results verify the feasibility of the algorithm proposed in this paper.The above two structured light three-dimensional reconstruction methods proposed in this paper can both generate three-dimensional point cloud data of the target object,but due to the discrete nature of line-shift coding and the continuous nature of phase-shift coding,the point cloud generated by the former is relatively sparse,while the latter The generated point cloud is denser. |