CN104408762A - Method for obtaining object image information and three-dimensional model by using monocular unit and two-dimensional platform - Google Patents
Method for obtaining object image information and three-dimensional model by using monocular unit and two-dimensional platform Download PDFInfo
- Publication number
- CN104408762A CN104408762A CN201410595963.0A CN201410595963A CN104408762A CN 104408762 A CN104408762 A CN 104408762A CN 201410595963 A CN201410595963 A CN 201410595963A CN 104408762 A CN104408762 A CN 104408762A
- Authority
- CN
- China
- Prior art keywords
- dimensional
- viewpoint
- point cloud
- cloud
- reconstruction
- 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
- 238000000034 method Methods 0.000 title claims abstract description 35
- 239000011159 matrix material Substances 0.000 claims description 7
- 230000010363 phase shift Effects 0.000 claims description 7
- 238000001914 filtration Methods 0.000 claims description 6
- 238000009499 grossing Methods 0.000 claims description 4
- 238000013519 translation Methods 0.000 claims description 4
- 239000012535 impurity Substances 0.000 claims 1
- 238000004064 recycling Methods 0.000 claims 1
- 230000000694 effects Effects 0.000 abstract description 3
- 238000005259 measurement Methods 0.000 description 52
- 238000005516 engineering process Methods 0.000 description 21
- 238000000691 measurement method Methods 0.000 description 11
- 238000011161 development Methods 0.000 description 8
- 239000000523 sample Substances 0.000 description 6
- 238000010586 diagram Methods 0.000 description 5
- 230000003287 optical effect Effects 0.000 description 5
- 241000282414 Homo sapiens Species 0.000 description 4
- 238000012545 processing Methods 0.000 description 4
- 238000011160 research Methods 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 3
- 238000009776 industrial production Methods 0.000 description 3
- 230000008569 process Effects 0.000 description 3
- 230000008859 change Effects 0.000 description 2
- 230000008094 contradictory effect Effects 0.000 description 2
- 238000013480 data collection Methods 0.000 description 2
- 230000007547 defect Effects 0.000 description 2
- 230000007613 environmental effect Effects 0.000 description 2
- 239000004744 fabric Substances 0.000 description 2
- 230000000007 visual effect Effects 0.000 description 2
- 229910000831 Steel Inorganic materials 0.000 description 1
- 230000002776 aggregation Effects 0.000 description 1
- 238000004220 aggregation Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 239000003814 drug Substances 0.000 description 1
- 238000005538 encapsulation Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 238000003384 imaging method Methods 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 239000000463 material Substances 0.000 description 1
- 238000004377 microelectronic Methods 0.000 description 1
- 239000000203 mixture Substances 0.000 description 1
- 230000005693 optoelectronics Effects 0.000 description 1
- 230000008447 perception Effects 0.000 description 1
- 238000003908 quality control method Methods 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
- 239000010959 steel Substances 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T17/00—Three dimensional [3D] modelling, e.g. data description of 3D objects
Landscapes
- Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Computer Graphics (AREA)
- Geometry (AREA)
- Software Systems (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Length Measuring Devices By Optical Means (AREA)
- Image Processing (AREA)
Abstract
本发明涉及一种利用单目和二维平台获取物体图像信息及三维模型的方法,该方法将物体放在电动二维旋转台上,根据视点最优规划,控制WNSC400精确的调整各最优视点所需的旋转角度,利用PCL点云库对点云进行滤波,分割,采样,配准,能够快速重建出未知物体的三维模型。该方法不仅重建速度快,实用性好,而且操作简单,重建成本低,容易操作,重建效果好。
The invention relates to a method for acquiring object image information and a three-dimensional model by using a monocular and two-dimensional platform. The method places the object on an electric two-dimensional rotating platform, and controls WNSC400 to accurately adjust each optimal viewpoint according to the optimal viewpoint planning. The required rotation angle, using the PCL point cloud library to filter, segment, sample, and register the point cloud, can quickly reconstruct the 3D model of the unknown object. This method not only has fast reconstruction speed and good practicability, but also has simple operation, low reconstruction cost, easy operation and good reconstruction effect.
Description
技术领域 technical field
本发明涉及快速自动三维重建技术领域,特别是一种利用单目结构光和电动二维旋转平台快速获取未知物体的三维模型的自动重建方法。 The invention relates to the technical field of fast automatic three-dimensional reconstruction, in particular to an automatic reconstruction method for quickly acquiring a three-dimensional model of an unknown object by using monocular structured light and an electric two-dimensional rotating platform.
背景技术 Background technique
人类对外部世界的感知主要是依靠视觉。据研究,人类通过自身感官所获得的外界信息,有80%来源于视觉。而视觉本身是一个能够感受光信号,并可以传输、处理、存储与理解视觉信息的过程。随着科技的发展与人类的进步,人们开始通过摄像机模仿人眼获取环境图像,并将其转换成数字信号,然后通过计算机实现对视觉信息的处理,这就是计算机视觉。另一方面,由于工业生产等方面的需要,使得人们对物体外形的测量技术不断提出新的要求。而计算机视觉的发展,使人们渐渐意识到这将引起测量技术尤其是非接触式测量技术的重大变革。 Human beings' perception of the external world mainly relies on vision. According to research, 80% of the external information obtained by human beings through their own senses comes from vision. Vision itself is a process that can perceive light signals, and can transmit, process, store and understand visual information. With the development of science and technology and the progress of human beings, people began to use cameras to imitate human eyes to obtain environmental images, convert them into digital signals, and then process visual information through computers, which is computer vision. On the other hand, due to the needs of industrial production and other aspects, people continue to put forward new requirements for the measurement technology of object shape. The development of computer vision makes people gradually realize that this will cause a major change in measurement technology, especially non-contact measurement technology.
随着科学技术和工业生产的迅猛发展,许多领域都需要对三维物体的形状进行快速准确的测量。而且,随着计算机技术的发展以及数字成像装置、激光器和其他光电元件的出现,三维形状测量技术已逐渐成熟,并根据各自特点广泛应用于机器人视觉,自动制造和产品质量控制等不同领域。三维测量技术根据测量方式的不同可分为两大类,即接触式测量和非接触式测量。传统的三维测量方法是接触法,如三坐标机,它用可以精确定位的测头去接触物体表面,测出被接触点的空间坐标。测头在物体表面扫描一遍,就可以得到物体表面各点的空间坐标.以三坐标机为代表的接触式测量技术在精度上是其他方法所不能替代的,但是接触式测量固有的一些缺陷也同样限制了其自身的发展。第一,测头在与被测物接触时会产生一定程度的压力,这种压力足以使柔软物体的表面产生微小形变,因而影响测量结果;第二,理想测头应该是一个表面积为零的点,而实际中的测头表面积不可能为零,所以无法测量某些复杂表面的细微特征:第三,逐点测量的方式限制了测量的速度,不适合对表面积较大的物体进行测量。第四,与精密被测物接触还会导致其表面磨损,同时也会使测头本身造成损伤,限制了测量次数和精度。因此,接触式测量的缺陷来源于三维测量技术,己成为各国研究的热点,它弥补了接触式测量的不足,虽然测量精度不能与接触式测量相比,但是随着计算机与微电子技术的进步,这一问题也正在得到解决。基于视觉的非接触式三维测量是以三维视觉传感器所获得的深度图像来恢复物体的三维形状。这种非接触三维测量技术具有效率高、自动化程度高、造价较低等优点,在工业生产和现实生活中有着广阔的应用前景。 With the rapid development of science and technology and industrial production, many fields require fast and accurate measurement of the shape of three-dimensional objects. Moreover, with the development of computer technology and the emergence of digital imaging devices, lasers and other optoelectronic components, three-dimensional shape measurement technology has gradually matured and is widely used in different fields such as robot vision, automatic manufacturing and product quality control according to their respective characteristics. Three-dimensional measurement technology can be divided into two categories according to different measurement methods, namely contact measurement and non-contact measurement. The traditional three-dimensional measurement method is the contact method, such as a three-coordinate machine, which uses a probe that can be precisely positioned to touch the surface of the object and measure the spatial coordinates of the touched point. The probe scans the surface of the object once, and the spatial coordinates of each point on the surface of the object can be obtained. The contact measurement technology represented by the three-coordinate machine cannot be replaced by other methods in terms of accuracy, but some inherent defects of contact measurement also limit its own development. First, the probe will generate a certain degree of pressure when it is in contact with the measured object, which is enough to cause a small deformation on the surface of the soft object, thus affecting the measurement results; second, the ideal probe should be a surface area of zero. Points, and the actual surface area of the probe cannot be zero, so it is impossible to measure the subtle features of some complex surfaces: Third, the point-by-point measurement method limits the measurement speed and is not suitable for measuring objects with large surface areas. Fourth, the contact with the precision measured object will also cause its surface to wear, and at the same time, it will cause damage to the probe itself, which limits the number of measurements and accuracy. Therefore, the defect of contact measurement comes from three-dimensional measurement technology, which has become a research hotspot in various countries. It makes up for the shortcomings of contact measurement. Although the measurement accuracy cannot be compared with contact measurement, with the progress of computer and microelectronics technology , this issue is also being resolved. Vision-based non-contact 3D measurement is to recover the 3D shape of the object from the depth image obtained by the 3D vision sensor. This non-contact three-dimensional measurement technology has the advantages of high efficiency, high degree of automation, and low cost, and has broad application prospects in industrial production and real life.
准确和高效率的三维测量方法不仅是三维重建的基础,而且也是快速、自动的进行三维重建所必须的。现有的三维模型测量方法分接触式测量和非接触式测量两种。 Accurate and efficient 3D measurement methods are not only the basis of 3D reconstruction, but also necessary for fast and automatic 3D reconstruction. The existing three-dimensional model measurement methods are divided into contact measurement and non-contact measurement.
1、接触式测量:接触式测量主要是使用一些机械式的手工测量仪器或由接触式传感器组成的电子测量仪器,其中以手工测量为主。手工测量的工具主要包括:布带尺、钢卷尺、划笔、量高仪、踏脚印器和量脚卡尺。手工测量从测量方法上又分为直接法和间接法。直接法比较简单。首先用笔在脚的特征部位上标出有关测量点,利用布带尺、量高仪等工具可以直接测量出脚的各个有关数据。间接法利用脚印器踏出脚印并绘制出脚的轮廓线,然后再进行测量分析。接触式脚型测量的优点是投资少、操作步骤简单、灵活性强、方便携带、便于短时间内在不同的测量地点进行测量。缺点是接触式测量方式会对脚部产生压力,引起脚部形变,造成测量误差,测量时间长,而且测量的脚部参数有限,有些较复杂的参数或曲线无法测量,工作效率低、劳动强度大、重复再现性差、测量者之间的误差大,同时,这种测量方式难以获得脚部整体的数据信息。也不能对脚的截面形态进行数据采集。无法进行更深层次的研究。 1. Contact measurement: Contact measurement mainly uses some mechanical manual measuring instruments or electronic measuring instruments composed of contact sensors, among which manual measurement is the main method. The tools for manual measurement mainly include: cloth tape ruler, steel tape measure, drawing pen, height measuring instrument, footprint device and foot calipers. Manual measurement is divided into direct method and indirect method in terms of measurement methods. The direct method is relatively simple. First, use a pen to mark the relevant measurement points on the characteristic parts of the feet, and use tools such as a cloth tape ruler and an altimeter to directly measure various relevant data of the feet. The indirect method uses a footprint tool to take a footprint and draw the outline of the foot, which is then measured and analyzed. The advantages of contact foot type measurement are less investment, simple operation steps, strong flexibility, easy to carry, and easy to measure at different measurement locations in a short time. The disadvantage is that the contact measurement method will generate pressure on the feet, cause deformation of the feet, cause measurement errors, take a long time to measure, and the measured parameters of the feet are limited, some more complex parameters or curves cannot be measured, low work efficiency and labor intensity Large, poor reproducibility, large errors between measurers, and at the same time, it is difficult to obtain the data information of the whole foot with this measurement method. Data collection cannot be performed on the cross-sectional shape of the foot either. Unable to conduct deeper research.
2、非接触式测量:在计算机、光学等学科发展的带动下。光学非接触式测量作为近年来兴起的一门测量技术受到越来越多的重视。目前,光学非接触式测量方法主要有构光测量、立体视觉测量、激光测量等。 2. Non-contact measurement: Driven by the development of computer, optics and other disciplines. Optical non-contact measurement, as a measurement technology emerging in recent years, has received more and more attention. At present, optical non-contact measurement methods mainly include composition measurement, stereo vision measurement, laser measurement and so on.
(1)结构光测量:结构光三维视觉基于光学三角法原理,其基本原理是由结构光投射器向被测物体表面投射可控制的光点、光条或光面结构,并由图像传感器(如摄像机)获得图像,通过系统几何关系,利用三角原理计算得到物体的三维坐标。结构光测量方法具有计算简单、体积小、价格低、便于安装和维护的特点,在实际三维轮廓测量中被广泛使用。但是测量精度受物理光学的限制,存在遮挡问题,测量精度与速度相互矛盾,难以同时得到提高。 (1) Structured light measurement: structured light 3D vision is based on the principle of optical triangulation. Such as a camera) to obtain images, through the geometric relationship of the system, using the triangulation principle to calculate the three-dimensional coordinates of the object. The structured light measurement method has the characteristics of simple calculation, small size, low price, easy installation and maintenance, and is widely used in actual 3D profile measurement. However, the measurement accuracy is limited by physical optics, and there is an occlusion problem. The measurement accuracy and speed are contradictory, and it is difficult to improve at the same time.
(2)立体视觉测量:在计算机视觉系统中,利用两台位置相对固定的摄像机或一个摄像机在两个不同的位置,从不同角度同时获取同一景物的两幅图像,通过计算空间点在两幅图像中的视差来获得其三维坐标值。立体视觉方法最大的特点是拍摄速度快,可以在不到一秒时间内完成拍摄任务,适合于需要快速测量场合。但立体视觉方法数据处理量大,处理时间长,而且需要进行两幅图像的匹配,在物体表面灰度和面形变化不大时,会影响匹配和测量精度。 (2) Stereo vision measurement: In the computer vision system, two cameras with relatively fixed positions or one camera at two different positions are used to obtain two images of the same scene from different angles at the same time. The disparity in the image to obtain its three-dimensional coordinate value. The biggest feature of the stereo vision method is that the shooting speed is fast, and the shooting task can be completed in less than one second, which is suitable for occasions that require fast measurement. However, the stereo vision method has a large amount of data processing, a long processing time, and needs to match two images. When the gray level and surface shape of the object surface do not change much, the matching and measurement accuracy will be affected.
(3)激光测量:由一个多边形镜头定位的一根直线可视激光束,通过高频扫描来对物体表面进行扫描测量;应用三角定律,激光束在物体表面经反射后由激光接受器接收,然后经计算获得物体表面的坐标。激光扫描可以可以精确地提供三维环境信息,数据处理简单,受环境影响小。但成本高,精度、测距与扫描速率存在矛盾关系。 (3) Laser measurement: A linear visible laser beam positioned by a polygonal lens scans and measures the surface of the object through high-frequency scanning; applying the law of trigonometry, the laser beam is received by the laser receiver after being reflected on the surface of the object. Then the coordinates of the surface of the object are obtained through calculation. Laser scanning can accurately provide three-dimensional environmental information, data processing is simple, and it is less affected by the environment. But the cost is high, and there is a contradictory relationship between accuracy, ranging and scanning rate.
三维重建技术近年来发展迅速,这主要得益于科学技术的发展,三维重建成本的降低,特别是三维重建技术的成熟,结构光系统的迅速发展,极大地激发了广大研究者将三维重建技术应用到医学、娱乐、机械等各研究领域。 3D reconstruction technology has developed rapidly in recent years, mainly due to the development of science and technology, the reduction of 3D reconstruction costs, especially the maturity of 3D reconstruction technology, and the rapid development of structured light systems, which have greatly inspired researchers to apply 3D reconstruction technology. It is applied to various research fields such as medicine, entertainment, machinery, etc.
本专利所用的系统包含短焦相机、投影仪、WNSC400,以及相对应的软件设备。该重建技术利用格雷码与相移相结合的方法,根据三角测量原理对放入WNSC400上的物体进行三维测量,由视点1分析未知物体的几何及拓朴信息,从而相继得到其它视点的三维信息,由几个视点配准得到完整的三维模型。 The system used in this patent includes a short-focus camera, projector, WNSC400, and corresponding software equipment. This reconstruction technology uses the method of combining Gray code and phase shifting, and performs three-dimensional measurement on the objects placed on WNSC400 according to the principle of triangulation, and analyzes the geometry and topology information of unknown objects from viewpoint 1, so as to obtain the three-dimensional information of other viewpoints successively , a complete 3D model is obtained by registration of several viewpoints.
与人工测量和其他三维扫描测量相比,该系统的优势在于:(1)能够快速对未知物体进行三维测量;(2)能自动对视点进行拼接,快速完成整理模型的重建;(3)结构光系统价格低廉,使用成本低;(3)操作简单,用户能快速掌握其原理。 Compared with manual measurement and other 3D scanning measurements, the advantages of this system are: (1) It can quickly perform 3D measurement on unknown objects; (2) It can automatically stitch the viewpoints and quickly complete the reconstruction of the finishing model; (3) The structure The optical system is cheap and the cost of use is low; (3) The operation is simple, and the user can quickly grasp its principle.
发明内容 Contents of the invention
本发明涉及一种利用单目和二维平台获取物体图像信息及三维模型的方法,该方法不仅重建速度快,实用性好,而且操作简单,重建成本低,容易操作,重建效果好。 The invention relates to a method for acquiring object image information and a three-dimensional model by using a monocular and two-dimensional platform. The method not only has fast reconstruction speed and good practicability, but also has simple operation, low reconstruction cost, easy operation and good reconstruction effect.
为实现上述目的,本发明的技术方案是:一种利用单目和二维平台获取物体图像信息及三维模型的方法,包括以下步骤: In order to achieve the above object, the technical solution of the present invention is: a method for obtaining object image information and a three-dimensional model using a monocular and two-dimensional platform, comprising the following steps:
(1)快速重建:首先标定出相机与投影仪的内外参数,根据格雷码与相移结合的方法,利用单目结构光中的短焦获取图像信息,对未知物体进行三维重建,由三角测量原理得到某一视点的点云数据,剔除杂点,得到该视点下的三维模型; (1) Fast reconstruction: Firstly, the internal and external parameters of the camera and projector are calibrated, and according to the method of combining Gray code and phase shift, the image information is obtained by using the short focus in the monocular structured light, and the unknown object is reconstructed in three dimensions. The principle is to obtain the point cloud data of a certain viewpoint, remove the noise points, and obtain the 3D model under the viewpoint;
(2)视点规划:用户将待重建物体放在WNSC400(电动二维旋转台)上,利用相机获取该视点下的几何信息及拓朴信息,通过比较左右参考位置下所获可视面积的大小,取大者所在位置作为下一视点的位置,最后通过规划自终止判据,判断是否完成重建; (2) View point planning: the user places the object to be reconstructed on the WNSC400 (electric two-dimensional rotating table), uses the camera to obtain the geometric information and topology information under the point of view, and compares the size of the visible area obtained under the left and right reference positions , take the position of the larger one as the position of the next viewpoint, and finally judge whether to complete the reconstruction through the planning self-termination criterion;
(3)配准点云:将视点1-n重建出来的三维点云,将点云数据转化到视点1坐标系下,利用PCL点云库读取点云,进行ICP(迭代最近点算法)迭代,当迭代趋于稳定,配准结束,去除重合区域点云,分析重建出的点云数据,获得物体的完整三维模型; (3) Point cloud registration: reconstruct the 3D point cloud from viewpoint 1-n, transform the point cloud data into the coordinate system of viewpoint 1, use the PCL point cloud library to read the point cloud, and perform ICP (Iterative Closest Point Algorithm) iteration , when the iteration tends to be stable and the registration ends, the point cloud in the overlapping area is removed, the reconstructed point cloud data is analyzed, and the complete 3D model of the object is obtained;
在本发明一实施例中,所述步骤(1)包括以下步骤: In an embodiment of the present invention, the step (1) includes the following steps:
(1.1)内外参数的标定:根据张正友标定方法,利用matlab标定工具箱,标定出投影仪和短焦相机的内参数矩阵,再利用棋盘格标定出短焦与投影仪的R(旋转)、T(平移)矩阵,从而标定得到内外参数; (1.1) Calibration of internal and external parameters: According to Zhang Zhengyou’s calibration method, use the matlab calibration toolbox to calibrate the internal parameter matrix of the projector and short-focus camera, and then use the checkerboard to calibrate the R (rotation) and T of the short-focus and projector (translation) matrix, so as to calibrate the internal and external parameters;
(1.2)根据格雷码与相移结合的方法,利用单目结构光中的短焦对未知物体进行三维重建,得到其点云数据。 (1.2) According to the method of combining Gray code and phase shift, the short focus in monocular structured light is used to reconstruct the unknown object in 3D and obtain its point cloud data.
(1.3)优化模型表面质量:通过平滑算法进行了去噪,优化测量的三维数据,提高三维数据的精度。 (1.3) Optimizing the surface quality of the model: denoising is carried out through a smoothing algorithm, the measured 3D data is optimized, and the accuracy of the 3D data is improved.
在本发明一实施例中,所述步骤(2)采用WNSC400电动二维旋转台,包括以下步骤: In one embodiment of the present invention, the step (2) uses a WNSC400 electric two-dimensional rotary table, including the following steps:
(2.1)WNSC400初始化:设置好电动二维旋转台的初始参数,计算其脉冲当量,旋转一定角度所需的脉冲量; (2.1) WNSC400 initialization: set the initial parameters of the electric two-dimensional rotary table, calculate its pulse equivalent, and the pulse amount required for a certain angle of rotation;
(2.2)提取视点1下的点云信息:将物体置于WNSC400上,重建出三维点云信息,将重建出的点云,转化为pcd格式,利用PCL点云库对点云进行直通滤波,分离出视点1下的有用的最小点云,接下再使用滤波器进行滤波,移除离散点,最后通过欧氏聚类将经过滤波后的点云分割出几类点云数据,设置阀值,得到点云量大者为视点1下的有用点云数据 ; (2.2) Extract the point cloud information under viewpoint 1: place the object on WNSC400, reconstruct the 3D point cloud information, convert the reconstructed point cloud into pcd format, and use the PCL point cloud library to perform direct filtering on the point cloud, Separate the useful minimum point cloud under viewpoint 1, then use the filter to filter, remove the discrete points, and finally divide the filtered point cloud into several types of point cloud data through Euclidean clustering, and set the threshold , to get the useful point cloud data under viewpoint 1 with the largest amount of point cloud;
(2.3)确定下一个最优视点(NVB):由2.2得到的点云数据,分析前一视点的几何及拓朴信息,以得到最大的可视面积为下一个最优视点; (2.3) Determine the next optimal viewpoint (NVB): From the point cloud data obtained in 2.2, analyze the geometry and topology information of the previous viewpoint to obtain the largest viewing area as the next optimal viewpoint;
(2.4)重建整体模型:得到各个最优视点,重建各视点的三维点云,利用角度判据作为规划自终止判据,即将n次规划后所获得数据对齐到初始视点坐标系下(工作台中心与上一视点已获得模型边界、当前视点所获得模型别一边界连线所成角定义为边界夹角),满足角度判据(即边界夹角之和大于 ),则认为完成对物体表面的三维重建,得到整体模型。 (2.4) Reconstruct the overall model: obtain each optimal viewpoint, reconstruct the 3D point cloud of each viewpoint, use the angle criterion as the planning self-termination criterion, and align the data obtained after n times of planning to the initial viewpoint coordinate system (workbench The angle formed between the center and the boundary of the model obtained at the previous viewpoint and another boundary of the model obtained at the current viewpoint is defined as the boundary angle), which satisfies the angle criterion (that is, the sum of the boundary angles is greater than ), it is considered that the three-dimensional reconstruction of the object surface is completed and the overall model is obtained.
相较于现有技术,本发明的有益效果是将单目结构光系和WNSC400应用于快速获取未知物体的三维模型及自动重建中。容易实现,只需一个单目结构光系统和一台WNSC400即对物体完成三维测量;采集数据效率高;本专利采用光编码技术,使用的是连续照明,不需要特制的感光材料,只需普通的CMOS感光芯片,因此可大大降低成本;结合传统的三维重建技术,在点云处理中采用PCL技术,能够快速自动的变成各视点的拼接,重建效率高;测量效率高,具有很强的实用性和广阔的应用前景。 Compared with the prior art, the beneficial effect of the present invention is that the monocular structured light system and the WNSC400 are applied to fast acquisition of three-dimensional models of unknown objects and automatic reconstruction. It is easy to realize, only one monocular structured light system and one WNSC400 are needed to complete the three-dimensional measurement of the object; the data collection efficiency is high; this patent adopts the optical coding technology, and uses continuous lighting, which does not require special photosensitive materials, only ordinary CMOS photosensitive chip, so the cost can be greatly reduced; combined with traditional 3D reconstruction technology, PCL technology is used in point cloud processing, which can quickly and automatically become the splicing of each viewpoint, and the reconstruction efficiency is high; the measurement efficiency is high, and it has a strong Practicality and broad application prospects.
附图说明 Description of drawings
图1是本发明实施例中以某一人物模型为例视点1下的模型图。 Fig. 1 is a model diagram of a certain character model in viewpoint 1 in an embodiment of the present invention.
图2是本发明实施例中以某一人物模型为例视点2下的模型图。 Fig. 2 is a model diagram in the embodiment of the present invention, taking a character model as an example under viewpoint 2.
图3是本发明实施例中以某一人物模型为例视点3下的模型图。 Fig. 3 is a model diagram under viewpoint 3 taking a character model as an example in the embodiment of the present invention.
图4是本发明实施例中以某一人物模型为例视点4下的模型图。 Fig. 4 is a model diagram of a certain character model in viewpoint 4 in the embodiment of the present invention.
图5是本发明实施例中以某一人物模型为例整体模型封装图。 Fig. 5 is an encapsulation diagram of an overall model taking a character model as an example in the embodiment of the present invention.
具体实施方式 Detailed ways
一种利用单目结构光和电动二维旋转平台快速获取未知物体的图像信息及三维模型的测量方法,包括以下步骤: A measurement method for quickly acquiring image information and a three-dimensional model of an unknown object by using monocular structured light and an electric two-dimensional rotating platform, comprising the following steps:
(1)快速重建:首先标定出相机与投影仪的内外参数,根据格雷码与相移结合的方法,利用单目结构光中的短焦具有快速获取图像信息的功能,对未知物体进行三维重建,由三角测量原理得到某一视点的点云数据,剔除杂点,得到该视点下的三维模型,具体包括如下步骤: (1) Fast reconstruction: Firstly, the internal and external parameters of the camera and projector are calibrated, and according to the method of combining Gray code and phase shift, the short-focus in the monocular structured light has the function of quickly obtaining image information, and three-dimensional reconstruction of unknown objects , obtain the point cloud data of a certain point of view by the principle of triangulation, remove the noise points, and obtain the 3D model under the point of view, which specifically includes the following steps:
(1.1)内外参数的标定:根据张正友标定方法,利用matlab标定工具箱,标定出投影仪和短焦相机的内参数矩阵,再利用棋盘格标定出短焦与投影仪的R(旋转)、T(平移)矩阵,从而标定得到内外参数; (1.1) Calibration of internal and external parameters: According to Zhang Zhengyou’s calibration method, use the matlab calibration toolbox to calibrate the internal parameter matrix of the projector and short-focus camera, and then use the checkerboard to calibrate the R (rotation) and T of the short-focus and projector (translation) matrix, so as to calibrate the internal and external parameters;
(1.2)根据格雷码与相移结合的方法,利用双目结构光中的短焦对未知物体进行三维重建,得到其点云数据。 (1.2) According to the method of combining Gray code and phase shift, the short focus of binocular structured light is used to reconstruct the unknown object in 3D, and its point cloud data is obtained.
(1.3)优化模型表面质量:通过平滑算法进行了去噪,优化测量的三维数据,提高三维数据的精度。 (1.3) Optimizing the surface quality of the model: denoising is carried out through the smoothing algorithm, the measured three-dimensional data is optimized, and the accuracy of the three-dimensional data is improved.
(2)视点规划:用户将待重建物体放在WNSC400(电动二维旋转台)上,利用相机获取该视点下的几何信息及拓朴信息,通过比较左右参考位置下所获可视面积的大小,取大者所在位置作为下一视点的位置,最后通过规划自终止判据,判断是否完成重建,具体包括以下步骤: (2) View point planning: the user places the object to be reconstructed on the WNSC400 (electric two-dimensional rotating table), uses the camera to obtain the geometric information and topology information under the point of view, and compares the size of the visible area obtained under the left and right reference positions , take the position of the larger one as the position of the next viewpoint, and finally determine whether the reconstruction is completed by planning the self-termination criterion, which specifically includes the following steps:
(2.1)WNSC400初始化:设置好电动二维旋转台的初始参数,计算其脉冲当量,旋转一定角度所需的脉冲量; (2.1) WNSC400 initialization: set the initial parameters of the electric two-dimensional rotary table, calculate its pulse equivalent, and the pulse amount required for a certain angle of rotation;
(2.2)提取视点1下的点云信息:将物体置于WNSC400上,重建出三维点云信息,将重建出的点云,转化为pcd格式,利用PCL点云库对点云进行直通滤波,分离出视点1下的有用的最小点云,接下再使用滤波器进行滤波,移除离散点,最后通过欧氏聚类将经过滤波后的点云分割出几类点云数据,设置阀值,得到点云量大者为视点1下的有用点云数据 ; (2.2) Extract the point cloud information under viewpoint 1: place the object on WNSC400, reconstruct the 3D point cloud information, convert the reconstructed point cloud into pcd format, and use the PCL point cloud library to perform direct filtering on the point cloud, Separate the useful minimum point cloud under viewpoint 1, then use the filter to filter, remove the discrete points, and finally divide the filtered point cloud into several types of point cloud data through Euclidean clustering, and set the threshold , to get the useful point cloud data under viewpoint 1 with the largest amount of point cloud;
(2.3)确定下一个最优视点(NVB):由2.2得到的点云数据,分析前一视点的几何及拓朴信息,以得到最大的可视面积为下一个最优视点; (2.3) Determine the next optimal viewpoint (NVB): From the point cloud data obtained in 2.2, analyze the geometry and topology information of the previous viewpoint to obtain the largest viewing area as the next optimal viewpoint;
(2.4)重建整体模型:得到各个最优视点,重建各视点的三维点云,利用角度判据作为规划自终止判据,即将n次规划后所获得数据对齐到初始视点坐标系下(工作台中心与上一视点已获得模型边界、当前视点所获得模型别一边界连线所成角定义为边界夹角),满足角度判据(即边界夹角之和大于),则认为完成对物体表面的三维重建,得到整体模型。 (2.4) Reconstruct the overall model: obtain each optimal viewpoint, reconstruct the 3D point cloud of each viewpoint, use the angle criterion as the planning self-termination criterion, and align the data obtained after n times of planning to the initial viewpoint coordinate system (workbench The angle formed between the center and the boundary of the model obtained at the previous viewpoint and another boundary of the model obtained at the current viewpoint is defined as the boundary angle), which satisfies the angle criterion (that is, the sum of the boundary angles is greater than ), it is considered that the three-dimensional reconstruction of the object surface is completed and the overall model is obtained.
(3)配准点云:将视点1-n重建出来的三维点云,将点云数据转化到视点1坐标系下,利用PCL点云库读取点云,进行ICP(迭代最近点算法)迭代,当迭代趋于稳定,配准结束,去除重合区域点云,分析重建出的点云数据,获得物体的完整三维模型; (3) Point cloud registration: reconstruct the 3D point cloud from viewpoint 1-n, transform the point cloud data into the coordinate system of viewpoint 1, use the PCL point cloud library to read the point cloud, and perform ICP (Iterative Closest Point Algorithm) iteration , when the iteration tends to be stable and the registration ends, the point cloud in the overlapping area is removed, the reconstructed point cloud data is analyzed, and the complete 3D model of the object is obtained;
下面结合附图及具体实施例对本发明作进一步说明。 The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments.
1、如图1所示,将双目结构光系统与WNSC400放入合适位置,将待重建物体(以人物模型为例说明)放入WNSC400上方。 1. As shown in Figure 1, put the binocular structured light system and WNSC400 in a suitable position, and place the object to be reconstructed (take the character model as an example) on top of WNSC400.
2、分别标定相机与投影仪,获取它们的内部参数:焦距、主点坐标、畸变参数,同时标定相机与投影仪的外部参数,得到它们间的相互R(旋转),T(平移)矩阵。 2. Calibrate the camera and projector separately to obtain their internal parameters: focal length, principal point coordinates, and distortion parameters. At the same time, calibrate the external parameters of the camera and projector to obtain their mutual R (rotation), T (translation) matrix.
3、将待重建物体放在WNSC400上,根据格雷码与相移相结合的方法,利用三角测量原理,用短焦对物体快速完成重建。 3. Put the object to be reconstructed on the WNSC400, and use the principle of triangulation according to the method of combining Gray code and phase shift to quickly complete the reconstruction with short focus.
4、对3所得到的点云,通过平滑算法进行了去噪,优化测量的三维数据,提高三维数据的精度。 4. For the point cloud obtained in 3, denoising is carried out through a smoothing algorithm to optimize the measured 3D data and improve the accuracy of the 3D data.
5、分析进行预处理的点云得到其几何信息及拓朴信息,通过比较左右参考位置下所获可视面积的大小,取大者所在位置作为下一视点的位置,根据规划自终止判据,直到所有视点都完成重建。 5. Analyze the preprocessed point cloud to obtain its geometric information and topological information. By comparing the size of the visible area obtained under the left and right reference positions, the position of the larger one is taken as the position of the next viewpoint. According to the planning self-termination criterion , until all viewpoints have been reconstructed.
5.1将得到的点云信息,转化为pcd格式,利用PCL进行直通滤波,分离出视点1下的有用的最小点云,接下再使用滤波器进行滤波,移除离散点,最后通过欧氏聚类将经过滤波后的点云分割出几类点云数据,设置阀值,得到点云量大者为视点1下的有用点云数据(如图1所示为视点1下的点云数据); 5.1 Convert the obtained point cloud information into pcd format, use PCL to perform through filtering, and separate the useful minimum point cloud under viewpoint 1, then use the filter to filter, remove discrete points, and finally pass Euclidean aggregation The class divides the filtered point cloud into several types of point cloud data, sets the threshold value, and obtains the useful point cloud data under viewpoint 1 for the one with the largest amount of point cloud (as shown in Figure 1, the point cloud data under viewpoint 1) ;
5.2由5.1得到的点云数据,分析前一视点的几何及拓朴信息,以得到最大的可视面积为下一个最优视点; 5.2 From the point cloud data obtained in 5.1, analyze the geometry and topology information of the previous viewpoint to obtain the largest viewing area as the next optimal viewpoint;
5.3由5.2计算所得到各个最优视点,调整WNSC400重建各视点的三维点云,利用角度判据作为规划自终止准则,重建出整体模型。 5.3 For each optimal viewpoint obtained from the calculation in 5.2, adjust the WNSC400 to reconstruct the 3D point cloud of each viewpoint, and use the angle criterion as the planning self-terminating criterion to reconstruct the overall model.
6、将视点1-4重建出来的三维点云(图1-4),将点云数据转化到视点1坐标系下,利用PCL读取,进行ICP迭代,当迭代趋于稳定,配准结束,去除重合区域点云,分析重建出的点云数据,得到该人物的三维测量模型(如图5如示)。 6. Reconstruct the 3D point cloud from viewpoint 1-4 (Fig. 1-4), transform the point cloud data into the coordinate system of viewpoint 1, use PCL to read, and perform ICP iteration. When the iteration tends to be stable, the registration ends , remove the point cloud in the overlapping area, analyze the reconstructed point cloud data, and obtain the 3D measurement model of the person (as shown in Figure 5).
以上是本发明的较佳实施例,凡依本发明技术方案所作的改变,所产生的功能作用未超出本发明技术方案的范围时,均属于本发明的保护范围。 The above are the preferred embodiments of the present invention, and all changes made according to the technical solution of the present invention, when the functional effect produced does not exceed the scope of the technical solution of the present invention, all belong to the protection scope of the present invention. the
Claims (3)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410595963.0A CN104408762A (en) | 2014-10-30 | 2014-10-30 | Method for obtaining object image information and three-dimensional model by using monocular unit and two-dimensional platform |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410595963.0A CN104408762A (en) | 2014-10-30 | 2014-10-30 | Method for obtaining object image information and three-dimensional model by using monocular unit and two-dimensional platform |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104408762A true CN104408762A (en) | 2015-03-11 |
Family
ID=52646390
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410595963.0A Pending CN104408762A (en) | 2014-10-30 | 2014-10-30 | Method for obtaining object image information and three-dimensional model by using monocular unit and two-dimensional platform |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104408762A (en) |
Cited By (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105547188A (en) * | 2015-12-07 | 2016-05-04 | 中国科学院地球环境研究所 | Three-dimensional scanning system and three-dimensional scanning method for measuring volume of loose sediment block sample |
CN106548516A (en) * | 2015-09-23 | 2017-03-29 | 腾讯科技(深圳)有限公司 | Three-dimensional range method and apparatus |
CN106552412A (en) * | 2015-09-30 | 2017-04-05 | 捷荣科技集团有限公司 | Auxiliary fitness method and system based on human body model self-correction |
CN106895795A (en) * | 2017-02-16 | 2017-06-27 | 上海理工大学 | Monocular vision measurement apparatus and its 3 d modeling system |
WO2018049843A1 (en) * | 2016-09-14 | 2018-03-22 | 杭州思看科技有限公司 | Three-dimensional sensor system and three-dimensional data acquisition method |
CN109977466A (en) * | 2019-02-20 | 2019-07-05 | 深圳大学 | A kind of 3-D scanning viewpoint planning method, apparatus and computer readable storage medium |
CN110516564A (en) * | 2019-08-06 | 2019-11-29 | 深兰科技(上海)有限公司 | Pavement detection method and apparatus |
CN111754462A (en) * | 2020-05-28 | 2020-10-09 | 新拓三维技术(深圳)有限公司 | A method and system for visual inspection of three-dimensional pipe bends |
CN112013792B (en) * | 2020-10-19 | 2021-02-02 | 南京知谱光电科技有限公司 | Surface scanning three-dimensional reconstruction method for complex large-component robot |
WO2021097843A1 (en) * | 2019-11-22 | 2021-05-27 | 驭势科技(南京)有限公司 | Three-dimensional reconstruction method and device, system and storage medium |
CN113689558A (en) * | 2021-08-04 | 2021-11-23 | 广州市运通水务有限公司 | Three-dimensional reconstruction system based on three-dimensional laser scanner and PCL point cloud base |
CN113701664A (en) * | 2021-08-04 | 2021-11-26 | 广州市运通水务有限公司 | Underground target feature rapid extraction method based on three-dimensional laser scanning technology |
CN113890955A (en) * | 2021-12-08 | 2022-01-04 | 天远三维(天津)科技有限公司 | Scanning method, device and system of multiple sets of photographing scanners |
CN117523106A (en) * | 2023-11-24 | 2024-02-06 | 广州市斯睿特智能科技有限公司 | Three-dimensional reconstruction method, system, equipment and medium for monocular structured light |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101853521A (en) * | 2010-04-22 | 2010-10-06 | 武汉微目科技有限公司 | Three-dimensional digital modeling method of cultural relics with rotating structured light |
CN104063894A (en) * | 2014-06-13 | 2014-09-24 | 中国科学院深圳先进技术研究院 | Point cloud three-dimensional model reestablishing method and system |
-
2014
- 2014-10-30 CN CN201410595963.0A patent/CN104408762A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101853521A (en) * | 2010-04-22 | 2010-10-06 | 武汉微目科技有限公司 | Three-dimensional digital modeling method of cultural relics with rotating structured light |
CN104063894A (en) * | 2014-06-13 | 2014-09-24 | 中国科学院深圳先进技术研究院 | Point cloud three-dimensional model reestablishing method and system |
Non-Patent Citations (5)
Title |
---|
HE BINGWEI ET AL.: "An automatic registration algorithm for the scattered point clouds based on the curvature feature", 《OPTICS AND LASER TECHNOLOGY》 * |
何炳蔚 等: "基于单目视觉可视空间的视点规划方法", 《仪器仪表学报》 * |
何炳蔚: "未知对象自动三维重建过程自终止判别方法研究", 《工程图学学报》 * |
胡民政: "结构光三维测量系统集成的两轴转台标定及视点规划", 《中国优秀硕士学位论文全文数据库 工程科技II辑》 * |
陈云浩 等: "《空间测量与制图》", 28 February 2011 * |
Cited By (19)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106548516B (en) * | 2015-09-23 | 2021-05-14 | 清华大学 | Three-dimensional roaming method and device |
CN106548516A (en) * | 2015-09-23 | 2017-03-29 | 腾讯科技(深圳)有限公司 | Three-dimensional range method and apparatus |
CN106552412A (en) * | 2015-09-30 | 2017-04-05 | 捷荣科技集团有限公司 | Auxiliary fitness method and system based on human body model self-correction |
CN106552412B (en) * | 2015-09-30 | 2019-03-26 | 捷荣科技集团有限公司 | Auxiliary fitness method and system based on human body model self-correction |
CN105547188A (en) * | 2015-12-07 | 2016-05-04 | 中国科学院地球环境研究所 | Three-dimensional scanning system and three-dimensional scanning method for measuring volume of loose sediment block sample |
WO2018049843A1 (en) * | 2016-09-14 | 2018-03-22 | 杭州思看科技有限公司 | Three-dimensional sensor system and three-dimensional data acquisition method |
US10309770B2 (en) | 2016-09-14 | 2019-06-04 | Hangzhou Scantech Co., Ltd | Three-dimensional sensor system and three-dimensional data acquisition method |
CN106895795A (en) * | 2017-02-16 | 2017-06-27 | 上海理工大学 | Monocular vision measurement apparatus and its 3 d modeling system |
CN109977466A (en) * | 2019-02-20 | 2019-07-05 | 深圳大学 | A kind of 3-D scanning viewpoint planning method, apparatus and computer readable storage medium |
CN110516564A (en) * | 2019-08-06 | 2019-11-29 | 深兰科技(上海)有限公司 | Pavement detection method and apparatus |
WO2021097843A1 (en) * | 2019-11-22 | 2021-05-27 | 驭势科技(南京)有限公司 | Three-dimensional reconstruction method and device, system and storage medium |
US12211162B2 (en) | 2019-11-22 | 2025-01-28 | Uisee Technologies (Zhejiang) Ltd. | Method for 3D reconstruction, apparatus, system, and storage medium |
CN111754462A (en) * | 2020-05-28 | 2020-10-09 | 新拓三维技术(深圳)有限公司 | A method and system for visual inspection of three-dimensional pipe bends |
CN112013792B (en) * | 2020-10-19 | 2021-02-02 | 南京知谱光电科技有限公司 | Surface scanning three-dimensional reconstruction method for complex large-component robot |
CN113689558A (en) * | 2021-08-04 | 2021-11-23 | 广州市运通水务有限公司 | Three-dimensional reconstruction system based on three-dimensional laser scanner and PCL point cloud base |
CN113701664A (en) * | 2021-08-04 | 2021-11-26 | 广州市运通水务有限公司 | Underground target feature rapid extraction method based on three-dimensional laser scanning technology |
CN113890955A (en) * | 2021-12-08 | 2022-01-04 | 天远三维(天津)科技有限公司 | Scanning method, device and system of multiple sets of photographing scanners |
CN117523106A (en) * | 2023-11-24 | 2024-02-06 | 广州市斯睿特智能科技有限公司 | Three-dimensional reconstruction method, system, equipment and medium for monocular structured light |
CN117523106B (en) * | 2023-11-24 | 2024-06-07 | 广州市斯睿特智能科技有限公司 | Three-dimensional reconstruction method, system, equipment and medium for monocular structured light |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104408762A (en) | Method for obtaining object image information and three-dimensional model by using monocular unit and two-dimensional platform | |
CN107767442B (en) | Foot type three-dimensional reconstruction and measurement method based on Kinect and binocular vision | |
CN103971409B (en) | Measuring method for foot three-dimensional foot-type information and three-dimensional reconstruction model by means of RGB-D camera | |
CN107945268B (en) | A kind of high-precision three-dimensional method for reconstructing and system based on binary area-structure light | |
CN105066909B (en) | A kind of many laser stripe quick three-dimensional measuring methods of hand-held | |
CN104126989B (en) | A kind of based on the foot surfaces 3 D information obtaining method under multiple stage RGB-D pick up camera | |
CN100561120C (en) | An Imaging Method for a Three-Dimensional Measuring System | |
CN106969706A (en) | Workpiece sensing and three-dimension measuring system and detection method based on binocular stereo vision | |
CN103535960B (en) | Human body three-dimensional measurement method based on digital images | |
CN109579695B (en) | Part measuring method based on heterogeneous stereoscopic vision | |
CN104567728A (en) | Laser vision profile measurement system, measurement method and three-dimensional target | |
CN105574812B (en) | Multi-angle three-dimensional data method for registering and device | |
CN106289099B (en) | A kind of single camera vision system and the three-dimensional dimension method for fast measuring based on the system | |
CN104596439A (en) | Speckle matching and three-dimensional measuring method based on phase information aiding | |
CN104132613A (en) | Noncontact optical volume measurement method for complex-surface and irregular objects | |
CN104392488A (en) | Automatic point cloud data rectification method aiming at laser scanner and three-coordinate measuring arm | |
CN105547189A (en) | Mutative scale-based high-precision optical three-dimensional measurement method | |
CN107633518A (en) | A kind of product design detection method based on Kinect | |
CN110108236A (en) | A kind of high-temperature forging line reconstruct size fast vision measuring system and method | |
CN104794717A (en) | Depth information comparison method based on binocular vision system | |
CN101329163A (en) | 3D surface modeling system based on binocular | |
JP7353757B2 (en) | Methods for measuring artifacts | |
Kahn et al. | Hand-eye calibration with a depth camera: 2D or 3D? | |
CN107687821B (en) | Calibration method of multi-camera light knife system for shape measurement of deep hole rotating parts | |
CN106767433B (en) | A kind of method and system measuring foot sizing |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20150311 |