本文基于双目立体视觉测距原理，用普通的USB摄像头搭建双目立体视觉系统，提出了图像面积的非接触在线测量方法。首先对摄像头进行标定，得到摄像头的内参数，然后根据OpenCV的模板匹配算法，求出两幅图像中对应匹配点的水平视差，得到距离参数，最后根据平行双目视觉的成像原理，求得实际图像与其在成像平面上的图像之间的空间几何关系，进而求出图像的实际面积。该方法实现简单、成本低、实时性好。经过实验验证，该算法在一定测量范围内达到精度要求。 >Abinocular stereo vision system with a common USB camera is developed based on the distance measurement principle of binocular stereo vision, and the non-contact and on-line inspection method for the area of image is studied. First, we calibrate the camera and obtain the internal parameters of the camera. Second, horizontal parallax of the cor- responding points in two images is calculated by template matching based on OpenCV, and then the distance parameter is obtained. Finally, we find the spatial geometrical relationship between the image of the imaging plane and the actual image, and then the actual area of image is gotten. This method is easy to realize with low cost and real-time perform- ance. The experiment indicates that the algorithm meets the accuracy requirements within certain range of measurement.
Zhang, Z.Y. (1999) Flexible cam-era calibration by viewing a plane from unknown orientations. Pro-ceedings of the Interna- tional Conference on Computer Vision (ICCV’99), Corfu, 21-22 September 1999, 666-673.