CN108769459A - Multiple spot laser Full-automatic oblique angle shot based on image procossing corrects system - Google Patents
Multiple spot laser Full-automatic oblique angle shot based on image procossing corrects system Download PDFInfo
- Publication number
- CN108769459A CN108769459A CN201810578200.3A CN201810578200A CN108769459A CN 108769459 A CN108769459 A CN 108769459A CN 201810578200 A CN201810578200 A CN 201810578200A CN 108769459 A CN108769459 A CN 108769459A
- Authority
- CN
- China
- Prior art keywords
- correction
- laser
- automatic
- coordinate
- angle
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000012937 correction Methods 0.000 claims abstract description 88
- 238000000034 method Methods 0.000 claims abstract description 55
- 239000011159 matrix material Substances 0.000 claims abstract description 24
- 238000001514 detection method Methods 0.000 claims abstract description 11
- 238000006243 chemical reaction Methods 0.000 claims abstract description 9
- 238000005336 cracking Methods 0.000 claims 1
- 238000011426 transformation method Methods 0.000 abstract description 7
- 238000003672 processing method Methods 0.000 abstract description 3
- 230000009466 transformation Effects 0.000 description 12
- 230000003287 optical effect Effects 0.000 description 9
- 238000002474 experimental method Methods 0.000 description 8
- 238000010586 diagram Methods 0.000 description 5
- 238000005516 engineering process Methods 0.000 description 5
- 238000003702 image correction Methods 0.000 description 5
- 238000002372 labelling Methods 0.000 description 3
- 238000012545 processing Methods 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000010276 construction Methods 0.000 description 1
- 239000013256 coordination polymer Substances 0.000 description 1
- 239000003814 drug Substances 0.000 description 1
- 239000000284 extract Substances 0.000 description 1
- 238000010330 laser marking Methods 0.000 description 1
- 238000005259 measurement Methods 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/80—Camera processing pipelines; Components thereof
- H04N23/81—Camera processing pipelines; Components thereof for suppressing or minimising disturbance in the image signal generation
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Length Measuring Devices By Optical Means (AREA)
Abstract
在采用图像处理方法进行自动检测的过程中,基于坐标和基于角度的多点激光自动校正方法能够对斜角度拍摄的图像进行快速自动校正,并保证校正精度。1.基于坐标的多点激光自动校正方法:本发明的方案一利用测得的4个距离和4个打点坐标信息,通过空间立体几何法和相似定理的方法,推导出校正后的打点坐标,再根据透视变换方法计算校正矩阵并校正图像,保证了校正的精度要求。2.基于角度的多点激光自动校正方法:本发明利用测得的4个距离和标定的4个打点角度信息,通过空间立体几何法、球坐标系与直角坐标系的转换、相似定理的方法,推导出校正前后的打点坐标,再根据透视变换方法计算校正矩阵并校正图像,保证了校正的精度要求。In the process of automatic detection using image processing methods, the multi-point laser automatic correction method based on coordinates and angles can quickly and automatically correct images taken at oblique angles, and ensure the correction accuracy. 1. Coordinate-based multi-point laser automatic correction method: scheme one of the present invention utilizes 4 distances measured and 4 dotting coordinate information, by the method of spatial three-dimensional geometry method and similarity theorem, deduces the dotting coordinate after correction, Then calculate the correction matrix and correct the image according to the perspective transformation method, so as to ensure the precision requirement of correction. 2. Angle-based multi-point laser automatic correction method: the present invention utilizes the measured 4 distances and the calibrated 4 dot angle information, through the method of spatial three-dimensional geometry, the conversion of the spherical coordinate system and the rectangular coordinate system, and the method of similarity theorem , deduce the dot coordinates before and after correction, and then calculate the correction matrix and correct the image according to the perspective transformation method, which ensures the accuracy requirements of the correction.
Description
技术领域technical field
本发明涉及一种建筑物墙面(例如带图案、带裂缝等)检测的多点激光全自动校正系统,尤其涉及一种利用带激光测距仪的相机对倾斜的墙面拍摄照片并且进行快速校正的技术,属于计算机视觉,图像处理领域。The invention relates to a multi-point laser automatic correction system for detection of building walls (such as patterns, cracks, etc.), in particular to a camera with a laser range finder to take pictures of inclined walls and perform rapid The technology of correction belongs to the fields of computer vision and image processing.
背景技术Background technique
由于相机拍摄角度以及建筑物倾斜等因素,拍摄的图像可能产生畸变和失真,利用图像校正技术能够校正畸变失真图像。图像校正是指对失真图像进行的复原性处理,它作为图像处理技术,不断发展。目前图像校正技术,在教育、军事、医学、航空航天、建筑工程等多个领域发挥着重要作用。Due to factors such as the camera shooting angle and the tilt of the building, the captured image may be distorted and distorted, and the distorted and distorted image can be corrected by using image correction technology. Image correction refers to the restorative processing of distorted images. As an image processing technology, it continues to develop. At present, image correction technology plays an important role in many fields such as education, military affairs, medicine, aerospace, and construction engineering.
目前对拍摄的失真图像进行校正主要采用人工标注的方法,提取畸变图像的边缘,再根据标注的畸变图像坐标推算出标注点在校正后图像的坐标并计算出校正矩阵,最后利用校正矩阵对图像校正。At present, the correction of the captured distorted image mainly adopts the method of manual labeling, extracts the edge of the distorted image, and then calculates the coordinates of the marked point in the corrected image according to the coordinates of the marked distorted image and calculates the correction matrix, and finally uses the correction matrix to correct the image. Correction.
目前的图像校正技术通常存在以下问题:Current image correction techniques usually have the following problems:
(1)对拍摄的照片主要采用人工标注方法,耗时耗力,效率低。(1) The manual labeling method is mainly used for the captured photos, which is time-consuming and labor-intensive, and the efficiency is low.
(2)忽略图像靠近镜头一端的畸变,缺乏准确性。(2) Neglecting the distortion at the end of the image near the lens, it lacks accuracy.
(3)缺乏准确的距离数据,对后续自动拼接图像的正确性也带来影响。(3) The lack of accurate distance data also affects the correctness of subsequent automatic image stitching.
本发明采用多点激光全自动校正的方法,无需人工标注,对倾斜的墙面照片进行快速自动校正,并且能够对距离进行精确校正,从而能够实现对扫描图片进行实时的自动拼接,为大面积建筑物墙面(例如带图案、带裂缝等)的自动快速检测提供条件。The present invention adopts a multi-point laser full-automatic correction method, without manual marking, to quickly and automatically correct tilted wall photos, and to accurately correct distances, thereby enabling real-time automatic splicing of scanned pictures, providing large-area Automatic and rapid detection of building walls (such as patterns, cracks, etc.) provides conditions.
发明内容Contents of the invention
本发明的目的在于解决当前图像校正过程中人工标注耗时耗力,校正矩阵缺乏准确性等问题,提出基于坐标和基于角度的两种多点激光自动校正方法,包括:1.利用激光测距打点技术实现无需人工标注,2.考虑传统校正方法忽略靠近镜头一端畸变的因素,本发明的校正方法计算校正矩阵更加准确,能够对倾斜的墙面照片进行快速自动校正,提高校正精度。The purpose of the present invention is to solve the problems of time-consuming and labor-intensive manual labeling and lack of accuracy of the correction matrix in the current image correction process, and propose two multi-point laser automatic correction methods based on coordinates and angles, including: 1. Using laser distance measurement 2. Considering that the traditional correction method ignores the distortion factor close to the lens end, the correction method of the present invention calculates the correction matrix more accurately, and can quickly and automatically correct the tilted wall photos, improving the correction accuracy.
本发明为了解决以上问题,提出两种技术方案:In order to solve the above problems, the present invention proposes two technical solutions:
方案一:基于坐标的多激光自动校正方法Solution 1: Multi-laser automatic correction method based on coordinates
一种建筑物墙面(例如带图案、带裂缝等)检测的多点激光全自动校正系统,硬件包含CCD摄像机和4个单点激光测距仪。将4个激光测距仪安装在CCD摄像机同一位置的4个不同角度,用激光测距仪同时在4个角度打点测量出4个距离,激光测距仪打点测距的同时,拍摄照片记录打点位置,根据照片中激光打点位置(x1,y1)~(x4,y4)计算校正。本发明的方案一利用测得的4个距离和4个打点坐标信息,通过空间立体几何法和相似定理的方法,推导出校正后的打点坐标,再根据透视变换方法计算校正矩阵,最后利用校正矩阵对图像校正,保证了全自动校正系统的精度要求。A multi-point laser automatic correction system for detection of building walls (such as patterns, cracks, etc.), the hardware includes a CCD camera and 4 single-point laser range finders. Install 4 laser rangefinders at the same position of the CCD camera at 4 different angles, use the laser rangefinder to measure 4 distances at 4 angles at the same time, and take photos to record the dots while the laser rangefinder is marking the distance The position is calculated and corrected according to the laser marking position (x1, y1) ~ (x4, y4) in the photo. Solution 1 of the present invention utilizes the measured 4 distances and 4 dotted coordinate information to derive the corrected dotted coordinates through the method of spatial three-dimensional geometry and similarity theorem, then calculates the correction matrix according to the perspective transformation method, and finally uses the corrected The matrix corrects the image to ensure the accuracy requirements of the automatic correction system.
方案二:基于角度的多激光自动校正方法Solution 2: Multi-laser automatic correction method based on angle
一种建筑物墙面(例如带图案、带裂缝等)检测的多点激光全自动校正系统,硬件包含CCD摄像机和4个单点激光测距仪。将4个激光测距仪安装在CCD摄像机的同一位置,用激光测距仪在事先标定的4个角度同时打点测量出4个距离,根据事先标定4个激光打点的角度(α1,β1)(α2,β2)(α3,β3)(α4,β4)计算校正。本发明利用测得的4个距离和标定的4个打点角度信息,通过空间立体几何法、球坐标系与直角坐标系的转换、相似定理的方法,推导出校正前后的打点坐标,再根据透视变换方法计算校正矩阵,最后利用校正矩阵对图像校正,保证了全自动校正系统的精度要求。A multi-point laser automatic correction system for detection of building walls (such as patterns, cracks, etc.), the hardware includes a CCD camera and 4 single-point laser range finders. Install the 4 laser rangefinders at the same position of the CCD camera, and use the laser rangefinder to measure the 4 distances at the same time at the 4 angles calibrated in advance. α2,β2)(α3,β3)(α4,β4) calculates the correction. The present invention utilizes the measured 4 distances and the calibrated 4 dot angle information to deduce the dot coordinates before and after correction through the method of spatial three-dimensional geometry, the conversion of the spherical coordinate system and the rectangular coordinate system, and the similarity theorem, and then according to the perspective The transformation method is used to calculate the correction matrix, and finally the image is corrected by using the correction matrix, which ensures the precision requirement of the automatic correction system.
本发明的有益效果:在进行建筑物墙面拍摄时,利用多点激光全自动校准方法校正倾斜拍摄图像,从经济层面考虑,无需人工标注,能够大大减少人力,提高工作效;从技术层面考虑,能够对倾斜的墙面照片进行快速自动校正,并且能够对距离进行精确校正,提高校正精度。Beneficial effects of the present invention: when photographing the walls of buildings, the multi-point laser full-automatic calibration method is used to correct the obliquely photographed images. Considering from the economic level, manual marking is not required, which can greatly reduce manpower and improve work efficiency; considering from the technical level , It can quickly and automatically correct the tilted wall photos, and can accurately correct the distance to improve the calibration accuracy.
附图说明Description of drawings
图1基于坐标的多激光自动校正方法流程图Figure 1 Flowchart of coordinate-based multi-laser automatic calibration method
图2倾斜拍摄图Figure 2 Oblique shot
图3基于坐标的多激光打点图Figure 3 Coordinate-based multi-laser dot diagram
图4基于坐标的多激光打点空间坐标系图Figure 4 Coordinate system diagram of multi-laser dot marking space based on coordinates
图5实验一基于坐标的多激光自动校正结果图Figure 5 Experiment 1 Coordinate-based multi-laser automatic calibration results
图6实验二基于坐标的多激光自动校正结果图Figure 6 Experiment 2 Coordinate-based multi-laser automatic calibration results
图7实验一垂直拍摄图与校正图的对比图Figure 7 Experiment 1 Comparison between the vertical shooting picture and the calibration picture
图8实验二垂直拍摄图与校正图的对比图Figure 8 Comparison of the vertical shooting image and the calibration image in experiment 2
图9带裂缝墙面场景一基于坐标的多激光自动校正结果图Fig.9 Scene with cracked wall - the result of multi-laser automatic correction based on coordinates
图10基于角度的多激光自动校正方法流程图Figure 10 Flow chart of angle-based multi-laser automatic correction method
图11球坐标系图Figure 11 Spherical coordinate system diagram
图12基于角度的多激光打点图Figure 12 Angle-based multi-laser dot diagram
图13基于角度的多激光打点空间坐标系图Figure 13 The spatial coordinate system diagram of multi-laser dot marking based on angle
图14实验三基于角度的多激光自动校正结果图Figure 14 Experiment 3 The results of multi-laser automatic correction based on angle
图15实验四基于角度的多激光自动校正结果图Figure 15 Experiment 4: Angle-based multi-laser automatic correction results
图16实验三垂直拍摄图与校正图的对比图Figure 16 The comparison between the three vertical shooting pictures and the correction pictures in the experiment
图17实验四垂直拍摄图与校正图的对比图Figure 17 The comparison between the vertical shooting picture and the calibration picture of Experiment 4
图18带裂缝墙面场景二基于角度的多激光自动校正结果图Figure 18 The results of multi-laser automatic correction based on angle in scene 2 of the wall with cracks
具体实施方式Detailed ways
实施例一Embodiment one
基于坐标的多激光自动校正方法Multi-laser automatic correction method based on coordinates
本方案详细阐述了本发明一种基于坐标的多激光自动校正方法的具体实施方式。This proposal elaborates in detail the specific implementation of a coordinate-based multi-laser automatic correction method of the present invention.
将4个激光测距仪安装在CCD摄像机的同一位置的4个不同角度,用激光测距仪同时在4个角度打点测量出4个距离,激光测距仪打点测距的同时,拍摄照片记录打点位置,根据照片中激光打点位置(x1,y1)~(x4,y4)计算校正。该校正方法涉及三种计算方法:空间立体几何法,相似定理,透视变换。Install 4 laser rangefinders at the same position of the CCD camera at 4 different angles, use the laser rangefinder to measure 4 distances at 4 angles at the same time, and take photos to record while the laser rangefinder is marking the distance The dot position is calculated and corrected according to the laser dot position (x1, y1) ~ (x4, y4) in the photo. The correction method involves three calculation methods: spatial solid geometry method, similarity theorem, and perspective transformation.
以测得的4个距离和4个打点坐标信息为基础:利用空间立体几何法建立空间直角坐标系,计算墙面所在平面方程以及拍摄的倾斜角度;利用相似定理计算校正后的打点坐标;利用透视变换方法计算校正矩阵,最后利用校正矩阵校正图像,方案一流程图如图1。Based on the measured 4 distances and 4 dot coordinate information: use the spatial three-dimensional geometry method to establish a space Cartesian coordinate system, calculate the plane equation of the wall and the tilt angle of the shooting; use the similarity theorem to calculate the corrected dot coordinates; use The perspective transformation method calculates the correction matrix, and finally uses the correction matrix to correct the image. The flow chart of Scheme 1 is shown in Figure 1.
具体步骤:Specific steps:
在采用图像处理方法进行建筑物墙面(例如带图案、带裂缝等)自动检测的过程中,利用相机进行墙面拍摄时,一定会存在如图2视角倾斜的情况。In the process of automatic detection of building walls (such as patterns, cracks, etc.) using image processing methods, when using a camera to take pictures of the wall, there must be a situation where the angle of view is tilted as shown in Figure 2.
步骤1:利用空间立体几何法建立空间直角坐标系,计算墙面所在平面方程以及拍摄的倾斜角度Step 1: Use the spatial three-dimensional geometry method to establish a spatial rectangular coordinate system, calculate the plane equation of the wall and the tilt angle of the shooting
图3中(x1,y1)~(x4,y4)分别为4个激光打点的位置,激光测距仪所测量的4条线段分别为l1,l2,l3,l4;4个距离分别为L1,L2,L3,L4;以相机坐标为原点建立空间直角坐标系,如图4。In Figure 3, (x1, y1) ~ (x4, y4) are the positions of four laser dots, and the four line segments measured by the laser rangefinder are l1, l2, l3, l4; the four distances are L1, L2, L3, L4; establish a space Cartesian coordinate system with the camera coordinates as the origin, as shown in Figure 4.
4个打点位置在空间坐标系的坐标为(x1,y1,z1),(x2,y2,z2),(x3,y3,z3),(x4,y4,z4)。The coordinates of the four dot positions in the space coordinate system are (x1, y1, z1), (x2, y2, z2), (x3, y3, z3), (x4, y4, z4).
已知L1~L4和,(x1,y1)~(x4,y4)计算z1,z2,z3,z4,利用三角形勾股定理Knowing L1~L4 and, (x1, y1)~(x4, y4) to calculate z1, z2, z3, z4, using the triangle Pythagorean theorem
则有:Then there are:
因为4个打点坐标在同一平面,设平面方程为Ax+By+Cz+D=0,将(x1,y1,z1)~(x4,y4,z4)分别代入平面方程,则有:Because the four dotted coordinates are on the same plane, set the plane equation as Ax+By+Cz+D=0, and substitute (x1,y1,z1)~(x4,y4,z4) into the plane equation respectively, then:
此时at this time
通过矩阵运算,计算出系数A,B,C,D。Calculate the coefficients A, B, C, and D through matrix operations.
设相机光轴与平面相交于点P,设光心(0,0,P),将光心坐标代入平面方程有CP+D=0,所以 Let the optical axis of the camera intersect the plane at point P, set the optical center (0,0,P), and substitute the coordinates of the optical center into the plane equation, CP+D=0, so
现以光心为基准,将平面绕光心旋转θ角度使其与光轴相垂直,此时平面方程为: Now take the optical center as the benchmark, rotate the plane around the optical center by an angle of θ to make it perpendicular to the optical axis, then the plane equation is:
计算旋转角度即为拍摄倾斜角度:相机到平面方程Ax+By+Cz+D=0的距离为Calculating the rotation angle is the shooting tilt angle: the distance from the camera to the plane equation Ax+By+Cz+D=0 is
相机到平面方程的距离为: camera to plane The distance of the equation is:
所以so
故so
步骤2:利用相似定理计算校正后的打点坐标Step 2: Use the similarity theorem to calculate the corrected dot coordinates
计算激光在平面上打点的位置,将4条激光线分别投影到X0Z平面,直线方程分别为Calculate the laser in the plane At the dotted position, project the 4 laser lines onto the X0Z plane respectively, and the equations of the lines are
将分别代入到四条直线方程中,l1,l2,l3,l4与平面交点分别为:Will Substitute into the four straight line equations, l1, l2, l3, l4 and the plane The points of intersection are:
由相似定理计算(x1,y1,z1),(x2,y2,z2),(x3,y3,z3),(x4,y4,z4)在平面上对应的坐标(x1',y1',z1'),(x2',y2',z2'),(x3',y3',z3'),(x4',y4',z4')Calculated by the similarity theorem (x1, y1, z1), (x2, y2, z2), (x3, y3, z3), (x4, y4, z4) in the plane Corresponding coordinates on (x1', y1', z1'), (x2', y2', z2'), (x3', y3', z3'), (x4', y4', z4')
所以同理 so in the same way
则激光在旋转后平面的4个打点位置分别为Then the four dotting positions of the laser on the plane after rotation are
至此,校正前后8个位置坐标求得。So far, 8 position coordinates before and after correction are obtained.
步骤3:利用透视变换方法计算校正矩阵,最后利用校正矩阵校正图像Step 3: Calculate the correction matrix using the perspective transformation method, and finally correct the image using the correction matrix
综合以上,原打点位置和校正后打点位置一共8个坐标,根据原打点位置可以获取其在原图中的像素坐标(p1,q1),(p2,q2),(p3,q3),(p4,q4),推算校正后打点位置对应的像素坐标为(p1',q1'),(p2',q2'),(p3',q3'),(p4',q4'),一个二维平面经过透视变换,成为另一个平面图像,这个过程定义为:Based on the above, the original dot position and the corrected dot position have a total of 8 coordinates. According to the original dot position, the pixel coordinates (p1, q1), (p2, q2), (p3, q3), (p4, q4), calculate the pixel coordinates corresponding to the dot position after correction as (p1', q1'), (p2', q2'), (p3', q3'), (p4', q4'), a two-dimensional plane passes Perspective transformation, becoming another flat image, this process is defined as:
其中(pi',qi')是变换后的像素坐标,(pi,qi)是原像素坐标(注:(i=1,2,3,4)),h1,h2,h3,h4,h5,h6,h7,h8是变换系数,对于给定的4组变换点,定义的变换矩阵如下:Among them (pi', qi') are transformed pixel coordinates, (pi, qi) are original pixel coordinates (Note: (i=1,2,3,4)), h1,h2,h3,h4,h5, h6, h7, and h8 are transformation coefficients. For a given set of 4 transformation points, the defined transformation matrix is as follows:
因此,给定4个点及相应变换空间的点,只要其中任意所有的三个点不在一条直线,就可以解出8个变换参数。从而得到透视变换前后的变换关系,即可实现对图形透视变换达到校正图像的目的;图5,图6是基于坐标的多激光自动校正方法对棋盘校正的结果图;图7,图8分别为对应的垂直拍摄图(拍摄距离为相机到光心的距离)与校正图的对比图,通过对比,棋盘大小基本相同;图9是对场景一拍摄带裂缝的墙面校正的结果图。综合实施例一的实验结果,基于坐标的多激光自动校正方法对倾斜拍摄的照片校正效果良好,与原图对比,校正精度较高。Therefore, given 4 points and points in the corresponding transformation space, as long as any three of them are not in a straight line, 8 transformation parameters can be solved. Thus, the transformation relationship before and after the perspective transformation can be obtained, and the purpose of correcting the image can be achieved by the perspective transformation of the figure; Fig. 5 and Fig. 6 are the results of the checkerboard correction based on the multi-laser automatic correction method based on coordinates; Fig. 7 and Fig. 8 are respectively The comparison between the corresponding vertical shooting picture (the shooting distance is the distance from the camera to the optical center) and the correction picture shows that the size of the checkerboard is basically the same; Figure 9 is the result picture of the correction of the cracked wall in scene one. Based on the experimental results of Example 1, the multi-laser automatic correction method based on coordinates has a good correction effect on obliquely taken photos, and the correction accuracy is higher compared with the original image.
实施例二Embodiment two
基于角度的多激光自动校正方法Multi-laser automatic correction method based on angle
本方案详细阐述了本发明一种基于角度的多激光自动校正方法的具体实施方式。This solution describes in detail the specific implementation of an angle-based multi-laser automatic correction method of the present invention.
将4个激光测距仪安装在CCD摄像机的的同一位置,用激光测距仪在事先标定的4个角度同时打点测量出4个距离,根据事先标定4个激光打点的角度(α1,β1),(α2,β2),(α3,β3),(α4,β4)计算校正。该校正方法涉及四种计算方法:空间立体几何法,球坐标系与直角坐标系的转换,相似定理,透视变换。Install 4 laser range finders at the same position of the CCD camera, use the laser range finder to measure 4 distances at the same time at the 4 previously calibrated angles, according to the previously calibrated angles of the 4 laser dots (α1, β1) ,(α2,β2),(α3,β3),(α4,β4) calculate the correction. The correction method involves four calculation methods: the three-dimensional geometry method, the conversion between the spherical coordinate system and the rectangular coordinate system, similarity theorem, and perspective transformation.
以测得的4个距离和4个角度信息为基础:利用空间立体几何法、球坐标系与直角坐标系的转换建立空间直角坐标系,计算墙面所在平面方程、拍摄的倾斜角度和初始打点位置;利用相似定理计算校正后的打点坐标;利用透视变换方法计算校正矩阵,最后利用校正矩阵校正图像,方案二流程图如图10。Based on the measured 4 distances and 4 angles information: use the spatial three-dimensional geometry method, the conversion of the spherical coordinate system and the rectangular coordinate system to establish a spatial rectangular coordinate system, calculate the plane equation of the wall, the tilt angle of the shooting and the initial point. position; use the similarity theorem to calculate the corrected dot coordinates; use the perspective transformation method to calculate the correction matrix, and finally use the correction matrix to correct the image. The flow chart of scheme two is shown in Figure 10.
具体步骤:Specific steps:
在采用图像处理方法进行建筑物墙面(例如带图案、带裂缝等)自动检测的过程中,利用相机进行墙面拍摄时,一定会存在如图2视角倾斜的情况。In the process of automatic detection of building walls (such as patterns, cracks, etc.) using image processing methods, when using a camera to take pictures of the wall, there must be a situation where the angle of view is tilted as shown in Figure 2.
步骤1:利用空间立体几何法、球坐标系与直角坐标系的转换方法建立空间直角坐标系,计算墙面所在平面方程、拍摄的倾斜角度和初始打点位置。Step 1: Use the spatial three-dimensional geometry method, the conversion method of the spherical coordinate system and the rectangular coordinate system to establish a spatial rectangular coordinate system, and calculate the plane equation of the wall, the inclination angle of the shooting and the initial point location.
球坐标系和空间直角坐标的转换关系如图11,其中:The conversion relationship between the spherical coordinate system and the space Cartesian coordinates is shown in Figure 11, where:
(注:假设P(x,y,z)为空间内一点,则点P也可用这样三个有次序的数来确定,其中r为原点O与点P间的距离;θ为有向线段OP与z轴正向的夹角;为从正z轴来看自x轴按逆时针方向转到OM所转过的角,这里M为点P在XOY面上的投影。)(Note: Assuming that P(x,y,z) is a point in the space, the point P can also use such three ordered numbers To determine, where r is the distance between the origin O and point P; θ is the angle between the directed line segment OP and the positive direction of the z-axis; It is the angle turned from the x-axis to OM in the counterclockwise direction from the positive z-axis, where M is the projection of point P on the XOY plane. )
每个空间直角坐标在球坐标系中的转换对应两个角度,角度θ,事先标定,4个打点位置一共需要标定4个角度;如图12事先标定4个激光打点的角度为(α1,β1),(α2,β2),(α3,β3),(α4,β4),设4个打点位置的坐标A,B,C,D分别为(x1,y1,z1),(x2,y2,z2).(x3,y3,z3),(x4,y4,z4),如图13以相机为原点建立空间直角坐标系,光轴与物体平面的交点为P。The conversion of each space Cartesian coordinate in the spherical coordinate system corresponds to two angles, angle θ, Calibrate in advance, 4 dotting positions need to calibrate 4 angles in total; as shown in Figure 12, the angles of 4 laser dots are calibrated in advance as (α1, β1), (α2, β2), (α3, β3), (α4, β4), Let the coordinates A, B, C, and D of the 4 dot positions be (x1, y1, z1), (x2, y2, z2). (x3, y3, z3), (x4, y4, z4), as shown in the figure 13 Establish a space rectangular coordinate system with the camera as the origin, and the intersection point of the optical axis and the object plane is P.
已知激光测距仪测量的原点到A的距离为L1,根据球坐标系和直角坐标的转换关系,则有It is known that the distance from the origin measured by the laser rangefinder to A is L1, and according to the conversion relationship between the spherical coordinate system and the rectangular coordinates, there is
同理in the same way
其中L1,L2,L3,L4,α1,α2,α3,α4,β1,β2,β3,β4已知。Among them, L1, L2, L3, L4, α1, α2, α3, α4, β1, β2, β3, β4 are known.
点A,B,C,D在同一平面,设平面方程为Ax+By+Cz+D=0,将(x1,y1,z1)~(x4,y4,z4)分别代入平面方程,则有:Points A, B, C, and D are on the same plane, and the plane equation is set as Ax+By+Cz+D=0, and (x1, y1, z1) ~ (x4, y4, z4) are respectively substituted into the plane equation, then:
所以so
通过矩阵运算计算出系数A,B,C,D即可得墙面所在的平面方程。Calculate the coefficients A, B, C, and D through matrix operations to get the plane equation where the wall is located.
求旋转角度及校正矩阵同实施例一基于坐标的多点激光自动校正法步骤2、步骤3,图14,图15是基于角度的多激光自动校正方法对棋盘校正的结果图;图16,图17分别为对应的垂直拍摄图(拍摄距离为相机到光心的距离)与校正图的对比图,通过对比,棋盘大小基本相同;图18是对场景二拍摄带裂缝的墙面校正的结果图。综合实施例二的实验结果,基于角度的多激光自动校正方法对倾斜拍摄的照片校正效果良好,与原图对比,校正精度较高。Seek rotation angle and correction matrix with embodiment one coordinate-based multi-point laser automatic correction method step 2, step 3, Fig. 14, Fig. 15 is the result figure of checkerboard correction to the checkerboard correction method based on the multi-laser automatic correction method of angle; Fig. 16, Fig. Figure 17 is the comparison between the corresponding vertical shooting picture (the shooting distance is the distance from the camera to the optical center) and the correction picture. By comparison, the size of the checkerboard is basically the same; Figure 18 is the result of the correction of the wall with cracks taken in scene two . Based on the experimental results of Example 2, the angle-based multi-laser automatic correction method has a good correction effect on obliquely taken photos, and the correction accuracy is higher compared with the original image.
以上所述仅为本发明的实施例,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本发明的专利保护范围内。The above is only an embodiment of the present invention, and does not limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made by using the description of the present invention and the contents of the accompanying drawings, or directly or indirectly used in other related technologies fields, all of which are equally included in the scope of patent protection of the present invention.
Claims (3)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810578200.3A CN108769459A (en) | 2018-06-07 | 2018-06-07 | Multiple spot laser Full-automatic oblique angle shot based on image procossing corrects system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810578200.3A CN108769459A (en) | 2018-06-07 | 2018-06-07 | Multiple spot laser Full-automatic oblique angle shot based on image procossing corrects system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108769459A true CN108769459A (en) | 2018-11-06 |
Family
ID=64000183
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810578200.3A Pending CN108769459A (en) | 2018-06-07 | 2018-06-07 | Multiple spot laser Full-automatic oblique angle shot based on image procossing corrects system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108769459A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111443354A (en) * | 2020-05-18 | 2020-07-24 | 深圳市慧视智图科技有限公司 | Multipoint projection device for improving laser ranging precision and measuring method thereof |
CN112307941A (en) * | 2020-10-28 | 2021-02-02 | 广东小天才科技有限公司 | Image conversion method and terminal equipment |
CN113137920A (en) * | 2021-05-19 | 2021-07-20 | 重庆大学 | Underwater measurement equipment and underwater measurement method |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR0139572B1 (en) * | 1994-12-23 | 1998-06-15 | 양승택 | Image distortion calibration method using nervous network |
CN204302650U (en) * | 2014-11-25 | 2015-04-29 | 深圳先进技术研究院 | A kind of projector of automatically calibrating geometric distortion |
CN105321146A (en) * | 2015-09-25 | 2016-02-10 | 广东小天才科技有限公司 | Method and device for processing topic picture shot by mobile terminal |
CN108111828A (en) * | 2017-12-12 | 2018-06-01 | 成都市极米科技有限公司 | Projector equipment bearing calibration, device and projector equipment |
-
2018
- 2018-06-07 CN CN201810578200.3A patent/CN108769459A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR0139572B1 (en) * | 1994-12-23 | 1998-06-15 | 양승택 | Image distortion calibration method using nervous network |
CN204302650U (en) * | 2014-11-25 | 2015-04-29 | 深圳先进技术研究院 | A kind of projector of automatically calibrating geometric distortion |
CN105321146A (en) * | 2015-09-25 | 2016-02-10 | 广东小天才科技有限公司 | Method and device for processing topic picture shot by mobile terminal |
CN108111828A (en) * | 2017-12-12 | 2018-06-01 | 成都市极米科技有限公司 | Projector equipment bearing calibration, device and projector equipment |
Non-Patent Citations (1)
Title |
---|
许珊珊: "车牌图像倾斜校正算法的研究", 《内江科技》 * |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111443354A (en) * | 2020-05-18 | 2020-07-24 | 深圳市慧视智图科技有限公司 | Multipoint projection device for improving laser ranging precision and measuring method thereof |
CN112307941A (en) * | 2020-10-28 | 2021-02-02 | 广东小天才科技有限公司 | Image conversion method and terminal equipment |
CN112307941B (en) * | 2020-10-28 | 2024-12-24 | 广东小天才科技有限公司 | Image conversion method and terminal device |
CN113137920A (en) * | 2021-05-19 | 2021-07-20 | 重庆大学 | Underwater measurement equipment and underwater measurement method |
CN113137920B (en) * | 2021-05-19 | 2022-09-23 | 重庆大学 | A kind of underwater measurement equipment and underwater measurement method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2018228013A1 (en) | Front coated plane mirror-based structured light parameter calibration device and method | |
JP4147059B2 (en) | Calibration data measuring device, measuring method and measuring program, computer-readable recording medium, and image data processing device | |
CN109325981B (en) | Geometric parameter calibration method for micro-lens array type optical field camera based on focusing image points | |
CN111896221B (en) | Alignment Method of Rotating Optical Measuring System Using Virtual Coordinate System to Assist Camera Calibration | |
CN113920206B (en) | Calibration method of perspective tilt-shift camera | |
CN109827521B (en) | A fast multi-line structured light vision measurement system calibration method | |
CN111080714A (en) | Parallel binocular camera calibration method based on three-dimensional reconstruction | |
CN108648242B (en) | Two-camera calibration method and device without public view field based on assistance of laser range finder | |
WO2023201578A1 (en) | Extrinsic parameter calibration method and device for monocular laser speckle projection system | |
CN108769459A (en) | Multiple spot laser Full-automatic oblique angle shot based on image procossing corrects system | |
CN102314674B (en) | Registering method for data texture image of ground laser radar | |
CN108692656B (en) | A method and device for acquiring laser scanning data | |
CN102589529B (en) | Scanning close-range photogrammetry method | |
CN113781579A (en) | A Geometric Calibration Method for Panoramic Infrared Cameras | |
CN113947638A (en) | Image orthorectification method for fisheye camera | |
CN107328358B (en) | The measuring system and measurement method of aluminium cell pose | |
CN109406525A (en) | The detection system and its detection method of the apparent disease of bridge | |
CN109682312B (en) | Method and device for measuring length based on camera | |
CN115797460B (en) | A Method for Underwater Two-Target Targeting | |
CN116441775B (en) | Assembly method for correcting welding thermal deformation of H-shaped steel based on 3D vision | |
CN112665517A (en) | Multi-camera large-view-field surface shape measurement calibration method | |
CN116147582B (en) | A method for underwater photogrammetry positioning and orientation | |
CN110285831A (en) | A Calibration Method for Grid Structured Light Projector | |
CN116091610B (en) | Combined calibration method of radar and camera based on three-dimensional tower type checkerboard | |
CN112258406B (en) | Linear array push-broom CCD image rapid automatic geometric correction method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WD01 | Invention patent application deemed withdrawn after publication | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20181106 |