CN1412537A - Method for Finding Camera Optical Projection Parameters - Google Patents
Method for Finding Camera Optical Projection Parameters Download PDFInfo
- Publication number
- CN1412537A CN1412537A CN 01136401 CN01136401A CN1412537A CN 1412537 A CN1412537 A CN 1412537A CN 01136401 CN01136401 CN 01136401 CN 01136401 A CN01136401 A CN 01136401A CN 1412537 A CN1412537 A CN 1412537A
- Authority
- CN
- China
- Prior art keywords
- camera
- projection
- image
- obtaining
- lens
- 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.)
- Granted
Links
- 230000003287 optical effect Effects 0.000 title claims abstract description 69
- 238000000034 method Methods 0.000 title claims abstract description 52
- 238000012360 testing method Methods 0.000 claims description 37
- 238000004364 calculation method Methods 0.000 claims description 6
- 238000012937 correction Methods 0.000 abstract description 8
- 230000007246 mechanism Effects 0.000 abstract description 7
- 241000251468 Actinopterygii Species 0.000 abstract description 3
- 230000035945 sensitivity Effects 0.000 abstract 1
- 238000005516 engineering process Methods 0.000 description 5
- 238000003702 image correction Methods 0.000 description 5
- 230000008901 benefit Effects 0.000 description 4
- 238000003384 imaging method Methods 0.000 description 4
- 238000013461 design Methods 0.000 description 3
- 238000010586 diagram Methods 0.000 description 3
- 230000008569 process Effects 0.000 description 3
- XEEYBQQBJWHFJM-UHFFFAOYSA-N Iron Chemical compound [Fe] XEEYBQQBJWHFJM-UHFFFAOYSA-N 0.000 description 2
- 238000004519 manufacturing process Methods 0.000 description 2
- 239000011159 matrix material Substances 0.000 description 2
- 230000006978 adaptation Effects 0.000 description 1
- 238000004458 analytical method Methods 0.000 description 1
- 238000013459 approach Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 230000002860 competitive effect Effects 0.000 description 1
- 238000009795 derivation Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000001839 endoscopy Methods 0.000 description 1
- 238000007429 general method Methods 0.000 description 1
- 230000001939 inductive effect Effects 0.000 description 1
- 230000002452 interceptive effect Effects 0.000 description 1
- 229910052742 iron Inorganic materials 0.000 description 1
- 238000013507 mapping Methods 0.000 description 1
- 238000005259 measurement Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012545 processing Methods 0.000 description 1
- 238000003908 quality control method Methods 0.000 description 1
- 238000004088 simulation Methods 0.000 description 1
- 230000006641 stabilisation Effects 0.000 description 1
- 238000011105 stabilization Methods 0.000 description 1
- 238000010998 test method Methods 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
Images
Landscapes
- Image Processing (AREA)
Abstract
本发明为一种求取相机光学投射参数的方法,是利用失真影像具有中心对称的特性,借由一只具有复数个对称且同心的几何图形的校正物件来定出相机镜头的光学轴,进而在光学轴上以试误法找出其投影中心点,并同时求出其等效焦距与归类出其原生的投射模式;由于本发明可以确切地定出相机的内、外部参数,而且校正的方法简单、成本低,可适用于任何一种投射模式,并且影像失真越大敏感度越佳,因此可以轻易地将失真影像转换为符合中心投射机制下的正常影像,更可应用在鉴定鱼眼镜头特性方面与立体影像定位的领域。
The present invention is a method for calculating the optical projection parameters of a camera, which utilizes the center-symmetric characteristic of the distorted image, and determines the optical axis of the camera lens by means of a correction object having a plurality of symmetrical and concentric geometric figures, and then Find out its projection center point by trial and error on the optical axis, and simultaneously find out its equivalent focal length and classify its original projection mode; because the present invention can determine the internal and external parameters of the camera exactly, and correct The method is simple, low-cost, applicable to any projection mode, and the greater the image distortion, the better the sensitivity. Therefore, the distorted image can be easily converted into a normal image that conforms to the center projection mechanism, and it can be applied to identify fish Spectacle lens characteristics and the field of stereoscopic image positioning.
Description
技术领域technical field
本发明是有关于一种数位影像处理与呈现的方法,且特别是一种借助于找出相机镜头的投射中心(viewpoint)与等效焦距(focal length)等光学投射参数,而恢复失真影像为正常透视影像的方法。The present invention relates to a method for digital image processing and presentation, and in particular to a method for recovering distorted images by finding optical projection parameters such as the projection center (viewpoint) and equivalent focal length (focal length) of the camera lens. Method for normal perspective images.
背景技术Background technique
经常一般光学镜头成像,大都希望其符合线性投射的成像结果,使用者在类似镜头下所拍摄到的影像画面会与其实世界非常接近,但是它有一个不足之处一视角小,以标准镜头为例,其视角大约在45度至55度之间,因此,像监视器或内视镜等需要大视角的领域,就改采用广角镜头或是鱼眼镜头等,以便可以一次摄取到大视角的影像画面。Usually the general optical lens is used for imaging, and most of them hope that it conforms to the imaging result of linear projection. The image captured by the user under a similar lens will be very close to the real world, but it has a shortcoming—the angle of view is small, and the standard lens is used as the For example, the angle of view is about 45 degrees to 55 degrees. Therefore, in fields that require a large angle of view, such as monitors or endoscopes, wide-angle lenses or fisheye lenses are used instead, so that images with a large angle of view can be captured at one time. .
其中,鱼眼镜头是应用于捕捉非常广角的影像,通常装有鱼眼镜头的相机可以摄取到180度、甚至以上的视野且只要攫取一次影像,无须移动相机本身多次拍摄,但是伴随著视角的增加,其原始影像也有严重的失真问题,故通常需要经由影像校正技术,以输出较接近真实世界的透视影像。而影像校正的精确度影响到鱼眼镜头可以应用到的范围;以一般的监视系统来说,若只要求能够看到监视范围内的人或物的动向即可,那么还可以忍受画面部分失真的情况;若是为拍摄虚拟实境(Virtual Reality)的图片,则只要影像“看起来”正常清晰即可;但若是要应用到影像定位的领域,例如,内视镜或机器人视觉,则在目前鱼眼镜头许多光学参数未明的情况之下,难以精确地定出影像于空间中的真实位置。Among them, the fisheye lens is used to capture very wide-angle images. Usually, a camera equipped with a fisheye lens can capture a field of view of 180 degrees or even more, and only needs to capture an image once, without moving the camera itself for multiple shots, but with the angle of view The original image also has serious distortion problems, so image correction technology is usually required to output a perspective image that is closer to the real world. The accuracy of image correction affects the range that the fisheye lens can be applied to; for a general surveillance system, if it is only required to be able to see the movement of people or objects within the surveillance range, then partial distortion of the picture can also be tolerated If it is to take pictures of virtual reality (Virtual Reality), as long as the image "looks" normal and clear; but if it is to be applied to the field of image positioning, such as endoscopy or robot vision, at present Under the condition that many optical parameters of the fisheye lens are unknown, it is difficult to accurately determine the real position of the image in space.
无论如何,对于消费者而言,若是镜头能够兼具大视角、影像正确清晰又能精确地定位就最有市场竞争力。况且鱼眼镜头又其有无限景深的优点,这是其他种类镜头所无法比拟的,因此如何对鱼眼镜头所产生的影像进行校正,更是一个重要的课题。In any case, for consumers, if the lens can have a large viewing angle, accurate and clear images, and precise positioning, it will be the most competitive in the market. Moreover, the fisheye lens has the advantage of infinite depth of field, which is unmatched by other types of lenses. Therefore, how to correct the image produced by the fisheye lens is an important issue.
现有的公知技术中,已出现许多校正失真影像的方法。R.Y.Tsai(1987)利用空间中已知不共面的五个点以及一旋转矩阵与一转换矩阵的操作,来求取镜头的投影中心(viewpoint)与焦距(focal length)等参数,虽然经由其模拟所计算出来的结果已经相当地准确,但因其理论推导的基础是线性投射,应用在象鱼眼镜头这种严重非线性投射机制时,运算等效焦距的误差相当地大,所以无法直接沿用而成为一通用的校正方式。之后,出现一种针对鱼眼镜头的简单校正方式,请参照图1A与图1B,其中图1B是对应图1A的半球体空间投射模式,假设影像平面1为椭圆形(或圆形)的情形下,其长轴11与短轴12的交点13刚好是影像中心(图中C点),此外也相信鱼眼镜头摄取到的视野刚好是180度,基于上述的几个前提之下,推断影像平面1边缘处的入射方位角(zenithal angle)为π/2,中心点13的方位角为0,其余的点依照其与C点13和边缘间的相对位置而个别推测其方位角θ。例如,图1A中的A点,应该对应于图1B中的A点。上述这种鱼眼镜头影像的校正方式,简单且不需额外的校正物件(calibration target)辅助。这是许多直接以平面影像校正鱼眼相机所使用的相机描述模式。但是它的假设前提具有相当的不确定性,首先实际上画面的失真中心点13未必刚好是影像实际的中心点,而且鱼眼镜头影像边缘处模糊,难以定出所谓180度的边界;最重要的是无法定位半球体的半径和中心,这种以影像为基础的解析模式其校正影像的传真度很难评估。很明显地,这样的校正方式不适用于立体影像定位的领域。In the prior art, there are many methods for correcting distorted images. R.Y.Tsai (1987) used five known non-coplanar points in space and the operation of a rotation matrix and a transformation matrix to obtain the projection center (viewpoint) and focal length (focal length) of the lens. The results calculated by the simulation are quite accurate, but because the theoretical derivation is based on linear projection, when it is applied to a severe nonlinear projection mechanism such as a fisheye lens, the error in calculating the equivalent focal length is quite large, so it cannot be directly Continue to use and become a common correction method. Afterwards, a simple correction method for fisheye lens appears, please refer to Figure 1A and Figure 1B, where Figure 1B is the hemispherical space projection mode corresponding to Figure 1A, assuming that the
在专利的揭露上,TeleRobotic International Inc.提出几个关于鱼眼镜头相机的专利(美国专利号5185667、5313306、5359363、5384588),大体上来说,其技术内容是根据前述的相机模式,利用一个鱼眼镜头拍摄整个半球形视野,然后利用电脑控制一专门设计的电子线路,以数字转换的方式将原始的失真影像转换为正常的透视影像,并将其显示于荧光屏中,该技术被应用在全方位显示、监视、内视镜与远端控制等方面。之后,Interactive Pictures Corporation根据前述TeleRoboticInternational Inc.的技术,更提出一系列改良后的新方案(美国专利号5764276、5877801、5903319、5990941、6002430、6147709、6201574B1)。但是,无论是上述哪一种技术内容,皆是利用固定的投射模式来校正影像,并没有确切地定出鱼眼镜头相机的参数-投影中心(viewpoint)与焦距(focal length),对于投射模式也都假设是如图1A与图1B描述的投射模式-“等距离投射”(EquidistantProjection)-最常见的鱼眼镜头投射模式。在这种精确的参数未定、投射模式未明的情形下,只能将原始影像展开与还原,无法考虑校正影像的准确度,应用在立体影像定位的领域必受限制。In terms of patent disclosure, TeleRobotic International Inc. proposed several patents on fisheye lens cameras (US Patent No. 5185667, 5313306, 5359363, 5384588). Generally speaking, the technical content is based on the aforementioned camera mode, using a fish The spectacle lens shoots the entire hemispherical field of view, and then uses a computer to control a specially designed electronic circuit to digitally convert the original distorted image into a normal perspective image and display it on the fluorescent screen. This technology is applied in the whole world Position display, surveillance, endoscope and remote control, etc. Later, Interactive Pictures Corporation proposed a series of improved new solutions based on the aforementioned TeleRobotic International Inc. technology (US Patent No. 5764276, 5877801, 5903319, 5990941, 6002430, 6147709, 6201574B1). However, no matter which of the above-mentioned technical contents, they all use a fixed projection mode to correct the image, and have not exactly determined the parameters of the fisheye lens camera - the projection center (viewpoint) and the focal length (focal length). For the projection mode It is also assumed that the projection mode described in FIG. 1A and FIG. 1B - "Equidistant Projection" - the most common fisheye lens projection mode. In the situation where the precise parameters are not determined and the projection mode is not clear, the original image can only be unfolded and restored, and the accuracy of the corrected image cannot be considered. The application in the field of stereoscopic image positioning is bound to be limited.
事实上,目前公知的鱼眼镜头投射模式,除了“等距离投射”(Equidistant Projection)之外,还有“立体影像投射”(Stereographic Projection)与“直角投射”(OrthographicProjection)等,其光学投射的数学关系式分别表示如下:In fact, currently known fisheye lens projection modes, in addition to "Equidistant Projection", also include "Stereographic Projection" and "Orthographic Projection". The mathematical relations are expressed as follows:
1.等距离投射:IH=fθ1. Equidistant projection: IH=fθ
2.立体影像投射:IH=2f×tan(θ/2)2. Stereoscopic image projection: IH=2f×tan(θ/2)
3.直角投射:IH=f×sinθ3. Right-angle projection: IH=f×sinθ
其中,in,
IH:影像点与镜头光学轴的距离(像高);IH: the distance between the image point and the optical axis of the lens (image height);
f:鱼眼镜头的等效焦距;f: equivalent focal length of the fisheye lens;
θ:物体点对于焦平面的入射角,即为入射光与光学轴的夹角。θ: The incident angle of the object point to the focal plane, that is, the angle between the incident light and the optical axis.
理论上,“立体影像投射”是最佳的鱼眼镜头投射模式;但是由于光学上设计的原因,符合“等距离投射”理论的鱼眼镜头是最容易生产制造的,这也使得目前公知的校正技术都有一假说:所有鱼眼镜头的投射模式都是“等距离投射”,但事实上并非必然。Theoretically, "stereoscopic image projection" is the best fisheye lens projection mode; but due to optical design reasons, the fisheye lens that conforms to the "equidistant projection" theory is the easiest to manufacture, which also makes the currently known There is a hypothesis in the correction technology: the projection mode of all fisheye lenses is "equidistant projection", but in fact it is not necessary.
从另一方面来说,虽然镜头在制造时是依照一定的设计,但在制造完成后是否还是原设计的规格则难以验证;此外,鱼眼镜头在组装入一个真实系统(如照相机)之后,其有效焦距与可观察视角更可能会跟着变动,因此若是能有一简单又通用的技术,可以检验鱼眼镜头或是其组成影像攫取装置的规格,使得其出货时有较确定的规格,则可以大幅地增加鱼眼镜头的附加价值。On the other hand, although the lens is manufactured according to a certain design, it is difficult to verify whether it is still the original design specification after the manufacture is completed; in addition, after the fisheye lens is assembled into a real system (such as a camera), Its effective focal length and observable angle of view are more likely to change accordingly. Therefore, if there is a simple and universal technology that can test the specifications of fisheye lenses or their image capture devices, so that they have more definite specifications when they are shipped, then It can greatly increase the added value of the fisheye lens.
对于鱼眼镜头,本领域普通技术人员认为没有“实际”投影中心,这是以直线投射的观点而言。如能归纳出其对应的投影模式且找到其投射中心与等效焦距等光学投射参数,不但可以轻易地校正出正确的投射影像、应用于立体影像定位的领域,更可应用在产品质量管理方面。For fisheye lenses, those of ordinary skill in the art believe that there is no "actual" projection center, which is from the point of view of rectilinear projection. If the corresponding projection mode can be summarized and the optical projection parameters such as the projection center and equivalent focal length can be found, not only can the correct projected image be easily corrected, it can be applied to the field of stereoscopic image positioning, and it can also be applied to product quality management. .
发明内容Contents of the invention
有鉴于此,本发明的目的为针对严重非线性投射机制的影像校正问题,提供一种以鉴定镜头原生光学投射模式为基础的本质上的解决方法。In view of this, the object of the present invention is to provide an essential solution based on the identification of the original optical projection mode of the lens for the image correction problem of the severe nonlinear projection mechanism.
本发明的另一目的为定出相机的投影中心与有效焦距,使之可以更精确地校正影像及应用在立体影像定你的领域。本发明的又一目的为提供一种可以检验鱼眼镜头或其取影装置的空间投射机制的方法,以做为订定产品规格或出货前的质量管理。Another object of the present invention is to determine the projection center and effective focal length of the camera, so that the image can be corrected more accurately and applied in the field of stereoscopic image stabilization. Another object of the present invention is to provide a method for inspecting the spatial projection mechanism of the fisheye lens or its imaging device, so as to make product specifications or quality control before shipment.
根据上述本发明的目的,提供一种求取相机光学投射参数的方法。首先,将一具有测试图案的平面形式的校正物件放置于鱼眼镜头相机视野,调整校正物件的方向及位置,使得其形成的对应影像亦是相似的几何图案,此时连接测试图案与对应影像的中心,可以定出该鱼眼镜头的光学轴;之后,以试误法沿着光学轴寻找一定点,使得测试图案的对应影像像高以及被寻找到的定点至测试图案的方向角(zenithal angle)之间,符合一投射模式(projection mode)。According to the purpose of the present invention above, a method for calculating optical projection parameters of a camera is provided. First, place a calibration object in the form of a plane with a test pattern in the field of view of the fisheye camera, adjust the direction and position of the calibration object so that the corresponding image formed by it is also a similar geometric pattern, and then connect the test pattern and the corresponding image center of the fisheye lens, the optical axis of the fisheye lens can be determined; after that, a certain point is found along the optical axis by trial and error, so that the corresponding image height of the test pattern and the direction angle (zenithal angle), conform to a projection mode (projection mode).
上述的投射模式可以是“等距离投射”(EquidistantProjection)、“立体影像投射”(Stereographic Projection)或“直角投射”(Orthographic Projection)等目前已知的鱼眼镜头投射模式的其中之一。找到的该定点即为该鱼眼镜头相机的投影中心(viewpoint),至于其等效焦距可以由其投射模式的数学关系式得到。The above-mentioned projection mode may be one of currently known fisheye lens projection modes such as "Equidistant Projection", "Stereographic Projection" or "Orthographic Projection". The fixed point found is the projection center (viewpoint) of the fisheye camera, and its equivalent focal length can be obtained from the mathematical relationship of its projection mode.
由于本发明可以精确地定出鱼眼镜头相机的投影中心与等效焦距,且可找到其原生的投射模式,因此可以轻易地校正失真影像并找出其视野空间的投射曲线。Because the present invention can accurately determine the projection center and equivalent focal length of the fisheye lens camera, and can find its original projection mode, it can easily correct the distorted image and find out the projection curve of its view space.
为让本发明的上述和其他目的、特征、和优点能更明显易懂,下文特举一较佳实施例,并配合附图,作详细说明如下。In order to make the above and other objects, features, and advantages of the present invention more comprehensible, a preferred embodiment will be described in detail below together with the accompanying drawings.
附图说明Description of drawings
图1A、图1B表示公知一种以平面影像为基础的鱼眼镜头影像校正方法以及其空间投射的转换示意图;FIG. 1A and FIG. 1B show a known fisheye lens image correction method based on a planar image and a schematic diagram of its spatial projection conversion;
图2表示本发明中定出鱼眼镜头的光学轴的光路示意图;Fig. 2 shows the optical path schematic diagram of determining the optical axis of the fisheye lens in the present invention;
图3A~图3D表示本发明中校正物件上的测试图案的四个实施例;Figures 3A to 3D represent four embodiments of the test pattern on the calibration object in the present invention;
图4表示本发明中以“等距离投射”模式为例,找出投影中心与等效焦距的光路示意图;Fig. 4 shows the optical path schematic diagram of finding the projection center and the equivalent focal length by taking the "equidistant projection" mode as an example in the present invention;
图5表示本发明实际测试时求取投影中心的渐近曲线图;以及Fig. 5 shows the asymptotic graph of obtaining projection center when the present invention is actually tested; and
图6表示本发明中解决大于180度视角的校正物件的实施例。FIG. 6 shows an embodiment of the correction object of the present invention that addresses viewing angles greater than 180 degrees.
具体实施方式Detailed ways
虽然象鱼眼镜头这种具有轴对称非线性失真的镜头所投射出的影像有严重的失真问题,不过其失真现象具有以下特性:其影像在焦平面上呈中心对称,此中心点称为失真中心,在空间中光学投射光路则对称于其光学轴,这是本领域技术人员所熟知的现象,本发明首先便是利用这样的现象来定出鱼眼镜头的光学轴,之后更以该光学轴为参考,进而找到鱼眼镜头相机的投影中心,且可运算出其焦距与归纳出其投射模式。Although the image projected by a lens with axisymmetric nonlinear distortion such as a fisheye lens has serious distortion problems, its distortion phenomenon has the following characteristics: its image is center-symmetric on the focal plane, and this center point is called distortion Center, the optical projection light path in space is symmetrical to its optical axis, which is a phenomenon well known to those skilled in the art. The present invention first uses this phenomenon to determine the optical axis of the fisheye lens, and then uses the optical axis The axis is used as a reference to find the projection center of the fisheye lens camera, and its focal length can be calculated and its projection mode can be summarized.
请参照图2,欲实现本发明方法必须利用一校正物件(calibrationtarget)22,而且该校正物件22上必须具有至少一个几何图形,如果几何图形为多个,则须同心且对称,例如图中表示的同心圆,称之为测试图案(test pattern)220。进行校正时,将校正物件22放置于一鱼眼镜头相机的视野,此时测试图案220会在鱼眼镜头24后一影像平面23处形成一对应影像230。根据失真影像是中心对称的特性,若是测试图案220和影像平面23平行且中心点已经对准了鱼眼镜头24的光学轴21,那么对应影像230也一定是和测试图案220一样由同心圆组成,因此只要适当地调整校正物件22的位置与方向,直到所形成的对应影像230变成由同心圆轨迹组成时,连接测试图案220与对应影像230的圆中心,即是鱼眼镜头24的光学轴21。Please refer to Fig. 2, a calibration object (calibration target) 22 must be utilized in order to realize the method of the present invention, and there must be at least one geometric figure on the
可供利用于本发明方法中的测试图案220,并不只限定于如图3A所表示的同心圆,测试图案220若是由同心且对称的几何图形所组成会是较佳的实施例,除同心圆外,亦可利用如图3B的同心方形、如图3C的同心三角形、或是如图3D的同心六边形等,都是可应用于本发明方法中的测试图案220;甚至组合任意数目的同心且对称的圆形、方形、三角形与多边形,亦是另一种可行的实施例。但是在实际测试时,考虑到影像230有筒状失真的问题,因此除了圆形之外,需要设定几何图形(如三角形或方形等)的顶点为特征坐标点(featured coordinates),以作为校正过程的参考点。The
请参照图4,定出鱼眼镜头24的光学轴21之后,根据光学理论可知:镜头24的投影中心一定位于光学轴21上的某一点,而且往往就在鱼眼镜头24之内,如此一来,便大幅度缩减了寻找范围,因此,本发明就以试误法沿着鱼眼镜头24内的光学轴21一一测试,以找出鱼眼镜头24的投影中心点。至于其测试的方式,也是利用校正物件22上的测试图案220,若以“等距离投射”(Equidistant Projection)模式为例,假设已经确定光学轴21上的一定点241为光学原点,就可以量测得到该定点241至每一个同心圆上的物体点221的连线偏离光学轴21的方向角θi以及对应该物体点221的影像点231至光学轴21(此时也是影像中心)的距离IHi(或称为像高),有了这些数据,便可由每一个同心圆下的θi,与IHi的关系而得到fi。如果相机完全符合“等距离投射”的关系式,则失真由不同半径同心圆运算得到的fi为一常数。Please refer to Fig. 4, after determining the
本发明方法在实际施行时,是将测试图案280设定为二十个同心圆,且每相邻的同心圆之间相隔5mm。为了描述方便,假设校正物件22中心点与光学轴21垂直相交处是(0,0,0),且光学轴为z轴,可用(0,0,z)表示之,若投影中心与校正物件22的距离为D,设定校正物件22上各同心圆的半径为ri,其对应每一影像高度IHi,由于IHi与θi都是D的函数,因此“等距离投射”可改为以下的型式IHi(D)=fθi(D),其中i=1-20,可以取最外围圆形图样为基准,IH20(D)=fθ20(D),经过简单运算后可得以下等式:When the method of the present invention is actually implemented, the test pattern 280 is set as twenty concentric circles, and the distance between each adjacent concentric circle is 5 mm. For the convenience of description, it is assumed that the center point of the
IHi(D)/IH20(D)-θi(D)/θ20(D)=0IH i (D)/IH 20 (D)-θ i (D)/θ 20 (D)=0
此时若将(O,O,D)改为z轴上的一任意点,则可得一误差关系式如下:At this time, if (O, O, D) is changed to an arbitrary point on the z-axis, an error relationship can be obtained as follows:
ei(z)=IHi(z)/IH20(z)-θi(z)/θ20(z)e i (z) = IH i (z)/IH 20 (z)-θ i (z)/θ 20 (z)
根据上式,测试点在(O,O,D)时,ei(z)为最小值,校正物件22的距离便可被固定。According to the above formula, when the test point is at (O, O, D), e i (z) is the minimum value, and the distance of the
但是上式只是取两只同心圆,所计算出来的结果,为考虑到测试范围涵盖相机的有效的视野,且观察同心圆成像沿着半径方向的失真,所以参考每一圆形轨迹的涵盖范围,设一权重函数wi(D)=(IHi(D)-IHi-i(D))/IH20(D),其中IH0(D)=0,以公平地对待各轨迹的成效。因此,本发明在光学轴21上寻找投影中心的配适过程中,应用的误差函数为:
其中z为光学轴21上的任意点,若能找出唯一一点使得ε(z)最小、或是趋近于0时,则该点即为鱼眼镜头相机的投影中心。至于焦距f,根据量测到的IHi(D)及其相对的θi(D)为基础,利用下式计算之:
其中,fi(D)=IHi(D)/θi(D),若镜头完全符合投射模式、测量无误差且D值求得准确,那么f(D)应等于任一fi(D),这就是镜头的焦距f。事实上,得到的每一个fi(D)的统计标准偏差,更可以利用来估算投射模式的准确性,也就是说,可以用下列式子作为与“等距离投射”模式适配程度的指标:
请参照图5,图中显示以欧普罗公司出产的BV-7112型相机进行测试时,沿着z轴找寻D值的渐近曲线,该相机中安装了Daiwon Optical(Korea)公司的DW9813型鱼眼镜头,由制造商提供的规格焦距为1.78mm、对角线视野角有170度。图中以实线表现了最初一次的测试结果,更以该测试下的D值为基准(dD=0),将校正物件22分别往外移动5mm(dD=5)、10mm(dD=10)、15mm(dD=15)、20mm(dD=20)与25mm(dD=25)进行同样的测试,发现在该六种情形下,都有一很明显的ε(z)最小值,这证明了鱼眼镜头的确有投影中心,且本发明可以很准确地将它找出。与图5相关的测试数据如表1所示:Please refer to Figure 5, which shows the asymptotic curve of finding the D value along the z-axis when the BV-7112 camera produced by Opro Corporation is used for testing, and the DW9813 fish of Daiwon Optical (Korea) company is installed in this camera. The spectacle lens, provided by the manufacturer, has a focal length of 1.78mm and a diagonal viewing angle of 170 degrees. In the figure, the first test result is represented by a solid line, and the
表1测试的参数与结果
(单位:mm)(unit: mm)
观察表1中的数据,不论校正物件22是在六个位置中的哪一个,所计算出来的焦距落点(f(D)±σ(D))很接近,而且σ(D)相当小,显示本发明方法具有相当优良的准确度与精确度。Observing the data in Table 1, no matter which of the six positions the
当推导出鱼眼镜头相机的投影中心与焦距后,影像校正便会变得非常容易。若是以符合“等距离投射”模式的鱼眼镜头相机为例,请再次参照图4,该投射模式中半球体视野的物体点221与所对应影像点231间的映射关系很直接,可把影像平面以由焦距为半径长度的圆球面25来表示。如此在逻辑上,更可以象线性投射一样,入射光线对焦平面拥有相同的入射角和折射角。而任一视野线的投射影像长度,则可直接可用其入射角(即是反射角)的弧长来表示。所以在入射角为(就是反射角)θ时其像长为IH=fθi,而其校正后影像点231’的像高为IH’=f×tanθ。由图4中可以清楚地看出,ΔOPQ相似于ΔOP’Q’,因此校正出来的每一IH’都与其对应的ri成等比例,故通过本发明方法,可以非常准确地将失真影像还原。After deriving the projection center and focal length of the fisheye camera, image correction becomes very easy. If taking a fisheye camera conforming to the “equidistant projection” mode as an example, please refer to FIG. 4 again. In this projection mode, the mapping relationship between the
由于本发明方法于测试过程中,会同时检验所得到的数据在哪一种投射模式下使得误差值ε(z)最小,因此,本发明中的求取投影中心与焦距的方法,并不只限定应用于符合“等距离投射”模式下的鱼眼镜头相机,亦可应用于符合“立体影像投射”(IH=2f×tan(θ/2))或“直角投射”(IH=f×sinθ)模式下的相机,甚至说可以鉴定任何已知投射函数的非线性镜头,具有归纳与确定各个相机的真实投射模式的功能。至于可以应用本发明的相机种类包含有CCD相机、CMOS相机、数字相机或是一传统使用底片的相机皆可。Since the method of the present invention will simultaneously check which projection mode of the obtained data makes the error value ε(z) the smallest during the test process, therefore, the method for calculating the projection center and focal length in the present invention is not limited to Applied to the fisheye lens camera in the "equidistance projection" mode, and can also be applied to the "stereoscopic image projection" (IH=2f×tan(θ/2)) or "right-angle projection" (IH=f×sinθ) A camera in the mode, even a nonlinear lens that can identify any known projection function, has the function of inducing and determining the true projection mode of each camera. As for the types of cameras to which the present invention can be applied, there are CCD cameras, CMOS cameras, digital cameras, or a traditional film camera.
上述平面形式的校正物件22不可能达到180度的视野角,当视野角为180度时其所需校正物件22的半径为无限大,但这往往鱼眼镜头可摄取到的视野角度。至于如何解决此问题,本发明也提供了解决的办法,请参照图6,只要将校正物件22延伸成中空圆柱状即可达成,就像一个一端开放的铁罐,罐子的底面绘制如前面所描述的平面形式校正物件22,并用以校正得到相机方位及距离。当其已经定位出相机距离D后,此时光学轴21和圆枉中心轴线一致,而由圆柱周围环绕面22a向镜头延伸距离D即到达鱼眼镜头相机水平线,如图中表示位于由投影中心241所定义的水平面上的物体点222,其对应的影像点232即位于影像180度的边界。这种延伸方式更可以应用于视野角度大于180度的镜头。It is impossible for the above-mentioned
由于本发明可以确切地定出鱼眼镜头相机的投影中心与等效焦距,如果参考校正物件22的方位(校正物件22的方位是可以得到的),可相对定位多数组相机组成立体视觉系统,并且此系统将可以比一般镜头有更大的可操作视角。以三角学运算定位物件的三维方位,已为本领域普通技术人员所熟悉,故在此不对其详细的技术内容多做描述。然而本发明可经由投射公式,很快地由“所谓的”失真像高得到焦平面入射角(因为求取被定位点,对组成立体视觉系统相机组的入射角,是立体视觉三维定位的必要步骤),这比一般先以非线性高阶函数来校正符合于线性投射的像高后,再结合线性等效焦距的反正切函数求取入射角的方法减少了许多计算步骤。所以用原生投射模式来描述象鱼眼镜头这种严重非线性投射机制,有绝对的优势。Since the present invention can accurately determine the projection center and equivalent focal length of the fisheye lens camera, if the orientation of the
本发明提出的定位鱼眼镜头相机及求取其等效焦距的方法具有以下优点:The method for locating the fisheye lens camera proposed by the present invention and obtaining its equivalent focal length has the following advantages:
1.能够确切地定出鱼眼镜头相机的投影中心且求出其焦距,因此可以轻易地将失真影像复原为中心投射机制下的正常影像。1. The projection center of the fisheye lens camera can be determined exactly and its focal length can be calculated, so the distorted image can be easily restored to the normal image under the center projection mechanism.
2.可以归纳或找出鱼眼镜头相机的真实的投射模式。2. It is possible to generalize or find out the real projection mode of the fisheye lens camera.
3.可以应用到立体影像定位的领域,具有更简单与更快速的入射角运算方式。3. It can be applied to the field of stereoscopic image positioning, and has a simpler and faster calculation method of incident angle.
4.校正的方法简单且成本低,适用于任何一种投射模式的鱼眼镜头或非线性投射机制的相机。4. The correction method is simple and low-cost, and is applicable to any kind of projection mode fisheye lens or camera with nonlinear projection mechanism.
虽然本发明已以一较佳实施例揭露如上,然其并非用以限定本发明,任何本领域的普通技术人员,在不脱离本发明的精神和范围内,当可作些许的更动与润饰,因此本发明的保护范围当视后附的权利要求书所限定的范围为准。Although the present invention has been disclosed as above with a preferred embodiment, it is not intended to limit the present invention. Anyone skilled in the art may make some changes and modifications without departing from the spirit and scope of the present invention. , so the scope of protection of the present invention shall prevail as defined by the appended claims.
Claims (21)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 01136401 CN1203297C (en) | 2001-10-15 | 2001-10-15 | Method for Finding Camera Optical Projection Parameters |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 01136401 CN1203297C (en) | 2001-10-15 | 2001-10-15 | Method for Finding Camera Optical Projection Parameters |
Publications (2)
Publication Number | Publication Date |
---|---|
CN1412537A true CN1412537A (en) | 2003-04-23 |
CN1203297C CN1203297C (en) | 2005-05-25 |
Family
ID=4673641
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN 01136401 Expired - Fee Related CN1203297C (en) | 2001-10-15 | 2001-10-15 | Method for Finding Camera Optical Projection Parameters |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN1203297C (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101319896B (en) * | 2007-06-08 | 2010-10-13 | 中国科学院沈阳应用生态研究所 | Method for measuring three-dimensional structure of forest gap |
CN101726855B (en) * | 2009-11-13 | 2011-05-11 | 河北工业大学 | Correction method of fisheye image distortion on basis of cubic projection |
CN102256053A (en) * | 2010-05-18 | 2011-11-23 | 鸿富锦精密工业(深圳)有限公司 | Image correcting system and method |
CN102316242A (en) * | 2010-07-06 | 2012-01-11 | 鸿富锦精密工业(深圳)有限公司 | Image correcting system and correcting method thereof |
CN108734666A (en) * | 2017-04-13 | 2018-11-02 | 杭州海康威视数字技术股份有限公司 | A kind of fisheye image correcting method and device |
-
2001
- 2001-10-15 CN CN 01136401 patent/CN1203297C/en not_active Expired - Fee Related
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101319896B (en) * | 2007-06-08 | 2010-10-13 | 中国科学院沈阳应用生态研究所 | Method for measuring three-dimensional structure of forest gap |
CN101726855B (en) * | 2009-11-13 | 2011-05-11 | 河北工业大学 | Correction method of fisheye image distortion on basis of cubic projection |
CN102256053A (en) * | 2010-05-18 | 2011-11-23 | 鸿富锦精密工业(深圳)有限公司 | Image correcting system and method |
CN102316242A (en) * | 2010-07-06 | 2012-01-11 | 鸿富锦精密工业(深圳)有限公司 | Image correcting system and correcting method thereof |
CN108734666A (en) * | 2017-04-13 | 2018-11-02 | 杭州海康威视数字技术股份有限公司 | A kind of fisheye image correcting method and device |
CN108734666B (en) * | 2017-04-13 | 2021-03-26 | 杭州海康威视数字技术股份有限公司 | Fisheye image correction method and device |
Also Published As
Publication number | Publication date |
---|---|
CN1203297C (en) | 2005-05-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107248178B (en) | Fisheye camera calibration method based on distortion parameters | |
US6985183B2 (en) | Method for exploring viewpoint and focal length of camera | |
CN112562014B (en) | Camera calibration method, system, medium and device | |
CN107103625B (en) | Method and apparatus for imaging system | |
CN104374338B (en) | Single-axis rotation angle vision measurement method based on fixed camera and single target | |
WO2021212978A1 (en) | Calibration method, calibration apparatus, and non-volatile computer-readable storage medium | |
CN108921901A (en) | A kind of big visual field camera calibration method based on accurate two-axis platcform and laser tracker | |
CN106500596B (en) | The measurement method of structure light panorama measuring system | |
Ying et al. | Fisheye lenses calibration using straight-line spherical perspective projection constraint | |
CN115830103A (en) | Monocular color-based transparent object positioning method, device and storage medium | |
CN107767420A (en) | A kind of scaling method of underwater stereoscopic vision system | |
CN112465915A (en) | Vehicle-mounted panoramic system calibration method | |
CN107507244A (en) | Camera calibration method, proving operation method and the caliberating device of a kind of single-frame images | |
CN108182708B (en) | Calibration method and calibration device of binocular camera and terminal equipment | |
CN111429531A (en) | Calibration method, calibration device and non-volatile computer-readable storage medium | |
CN107527336A (en) | Relative position of lens scaling method and device | |
CN110738608A (en) | A kind of plane image correction method and system | |
CN110766763A (en) | Camera calibration method based on vanishing point operation | |
CN110163922B (en) | Fisheye camera calibration system, fisheye camera calibration method, fisheye camera calibration device, electronic equipment and storage medium | |
CN113963067B (en) | A calibration method using a small target to calibrate a vision sensor with a large field of view | |
CN1412537A (en) | Method for Finding Camera Optical Projection Parameters | |
JP3704494B2 (en) | How to check camera viewpoint and focal length | |
CN111754584A (en) | Remote large-field-of-view camera parameter calibration system and method | |
US9584715B2 (en) | Vision system with swappable camera having an alignment indicator, and methods of making and using the same | |
TWI788838B (en) | Method for coordinate transformation from spherical to polar |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
C19 | Lapse of patent right due to non-payment of the annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |