CN105333818A - 3D space measurement method based on monocular camera - Google Patents
3D space measurement method based on monocular camera Download PDFInfo
- Publication number
- CN105333818A CN105333818A CN201410339869.9A CN201410339869A CN105333818A CN 105333818 A CN105333818 A CN 105333818A CN 201410339869 A CN201410339869 A CN 201410339869A CN 105333818 A CN105333818 A CN 105333818A
- Authority
- CN
- China
- Prior art keywords
- point
- axis
- tested point
- camera
- subtest
- 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
Landscapes
- Other Investigation Or Analysis Of Materials By Electrical Means (AREA)
- Length Measuring Devices By Optical Means (AREA)
Abstract
The invention provides a 3D space measurement method based on a monocular camera. The method comprises the following steps of focusing a point to be measured on the ground and an auxiliary test point and acquiring a corresponding imaging parameter, wherein the auxiliary test point is located on a projection line of a camera optical axis on the ground; object distances of the point to be measured and the auxiliary test point are different and installation parameters of a camera of twice imaging are not changed; according to imaging parameters of the point to be measured and the auxiliary test point, carrying out association calculating on the twice imaging and acquiring a relative coordinate of the point to be measured, wherein a reference coordinate system of the relative coordinate is that a projection of an installation fulcrum of the camera on the ground is taken as an original point; a vertical line of the fulcrum and the ground is taken as a Y axis; a projection of the camera optical axis along the ground is taken as an X axis and a direction which is vertical to the X axis and the Y axis is taken as an Z axis. In the invention, an internal parameter of the monocular camera is used to calculate a space coordinate of the point to be measured; the installation parameter of the camera does not need to be measured and a calibration object does not need to be calibrated; cost is saved and operation is simplified.
Description
Technical field
The present invention relates to field of video monitoring, particularly relate to a kind of 3d space measuring method based on monocular-camera.
Background technology
Monocular-camera cannot form 3D vision by single shot.Not having the Reference of pre-principal dimensions to carry out subsidiary, when also not knowing the angle on video camera antenna height and camera lens axis and ground, the relative coordinate between subject and video camera mounting points cannot be measured.
In prior art, during monocular-camera single shot, by taking the Reference of pre-principal dimensions, the angle on the pixel shared by the Reference be taken in image, actual object size, video camera and ground, calculates the proportionate relationship between pixel that dimension of object and video camera take image.Then, in follow-up shooting, do not change the installation parameter of video camera, only need the physical size calculating object according to the number of pixels shared by subject.By the angle on video camera and ground and the height setting up bar, the relative coordinate between subject and video camera can be calculated.
Can be found out by said process, monocular-camera single shot needs to possess a lot of external condition, needs video camera installation data, as the angle on erection bar height, video camera and ground; Need to use and demarcate thing, manually carry out auxiliary calibration and calculate reduced parameter; Can not change video camera installation parameter in follow-up use, otherwise must again demarcate, adaptability is bad.
Or prior art takes same object by eyes video camera, or monocular-camera is at two different positions and the same object of angle shot, by diverse location in the picture, realizes 3D visually-perceptible.But must use two video cameras, or provide guide rail and the drive unit of movement for single camera, cost is higher.
Summary of the invention
In view of this, the invention provides a kind of 3d space measuring method based on monocular-camera, the method comprises:
Respectively to ground tested point and the focusing of subtest point, obtain corresponding imaging parameters, wherein, described subtest point is positioned at camera optical axis on the projection line on ground, described tested point is different from described subtest point object distance, and the video camera installation parameter of twice imaging is constant;
According to the imaging parameters of described tested point and described subtest point, carry out association to twice imaging to calculate, obtain the relative coordinate of described tested point, the reference coordinate of described relative coordinate is, with video camera, fulcrum is installed and is projected as initial point on ground, with the vertical line on this fulcrum and ground for Y-axis, be projected as X-axis, with the direction vertical with Y-axis with X-axis for Z axis with camera optical axis along ground.
Present invention also offers a kind of 3d space measurement mechanism based on monocular-camera, this device comprises:
Imaging parameters acquiring unit, for focusing to ground tested point and subtest point respectively, obtain corresponding imaging parameters, wherein, described subtest point is positioned at camera optical axis on the projection line on ground, described tested point is different from described subtest point object distance, and the video camera installation parameter of twice imaging is constant;
Relative coordinate computing unit, for the imaging parameters according to described tested point and described subtest point, carry out association to twice imaging to calculate, obtain the relative coordinate of described tested point, the reference coordinate of described relative coordinate is, installs fulcrum be projected as initial point on ground with video camera, with the vertical line on this fulcrum and ground for Y-axis, X-axis is projected as, with the direction vertical with Y-axis with X-axis for Z axis along ground with camera optical axis.
The present invention utilizes the inner parameter of monocular-camera to calculate the space relative coordinate of tested point, and without the need to the installation parameter of measuring video camera and demarcate demarcation thing, saves human and material resources and time cost, the operating process of simplification.
Accompanying drawing explanation
Fig. 1 is the schematic diagram of logical organization and the underlying hardware environment thereof measured based on the 3d space of monocular-camera in one embodiment of the present invention.
Fig. 2 is the process flow diagram based on the 3d space measuring method of monocular-camera in one embodiment of the present invention.
Fig. 3 is monocular-camera scheme of installation.
Fig. 4 is optical imagery schematic diagram in one embodiment of the present invention.
Fig. 5 be in one embodiment of the present invention imaging point at the image height schematic diagram of the Y direction of image acquiring sensor.
Fig. 6 is lens imaging principle schematic.
Fig. 7 be in one embodiment of the present invention imaging point at the image height schematic diagram of the Z-direction of image acquiring sensor.
Embodiment
Below in conjunction with accompanying drawing, the present invention is described in detail.
The invention provides a kind of 3d space measurement mechanism based on monocular-camera, be described for software simulating below, but the present invention does not get rid of other implementations such as such as hardware or logical device etc.As shown in Figure 1, the hardware environment of this plant running comprises CPU, internal memory, nonvolatile memory and other hardware.This device is as the virtual bench of a logic level, and it is run by CPU.This device comprises imaging parameters acquiring unit and relative coordinate computing unit.Please refer to Fig. 2, use and the operational process of this device comprise the following steps:
Step 101, imaging parameters acquiring unit is respectively to ground tested point and the focusing of subtest point, obtain corresponding imaging parameters, wherein, described subtest point is positioned at camera optical axis on the projection line on ground, described tested point is different from described subtest point object distance, and the video camera installation parameter of twice imaging is constant;
Step 102, relative coordinate computing unit is according to the imaging parameters of described tested point and described subtest point, carry out association to twice imaging to calculate, obtain the relative coordinate of described tested point, the reference coordinate of described relative coordinate is, installs fulcrum be projected as initial point on ground with video camera, with the vertical line on this fulcrum and ground for Y-axis, X-axis is projected as, with the direction vertical with Y-axis with X-axis for Z axis along ground with camera optical axis.
The present invention is not when changing monocular-camera installation parameter (position, highly, The Cloud Terrace angle etc.), imaging is carried out to tested point and subtest point, and according to imaging parameters, association calculating is carried out to twice imaging, obtain the volume coordinate of tested point.Concrete processing procedure is as follows.
As shown in Figure 3, monocular-camera is installed vertically on E point by vertical rod.With E point for initial point sets up reference frame, calculate the position coordinates of tested point relative to this coordinate system.The X-axis of this coordinate system is the projection of camera light direction of principal axis on ground, and Y-axis is vertical rod direction, and Z axis is perpendicular to XY plane.In figure, the intersection point A on object AD and ground is tested point, and ground B point is subtest point, in the projection of camera optical axis along ground.
As shown in Figure 4, the easy structure of video camera is given in figure, wherein, the virtual optics center that lens optical center is formed for the many eyeglasses of camera lens, the distance (along camera light direction of principal axis) that fulcrum installed by lens optical center and video camera is r, and twice imaging in front and back may change to some extent.For the angle on camera optical axis and ground.
When not changing video camera installation parameter (highly, optical axis angle, direction), utilizing monocular-camera respectively to A point and the focusing of B point, obtaining corresponding imaging parameters.A point imaging point is on the image sensor a point, and B point imaging point is on the image sensor b point, all projects in the plane vertical with optical axis as with thing, derives so that calculate.P
1for Polaroid object plane, i.e. A point place object plane; P
2for secondary imaging object plane, i.e. B point place object plane.Obtain thus, Polaroid image distance V
1, focal length F
1and the distance r of lens optical center and installation fulcrum
1; The image distance V of secondary imaging
2, focal length F
2and the distance r of lens optical center and installation fulcrum
2.
According to imaging point position calculation image height in the image sensor, as shown in Figure 5.In figure, the imaging point of top is b point, and below imaging point is a point.According to physical size with proportional along physical size direction corresponding pixel points quantity, be calculated to be the physical size (image height) of picture point along XY plane.In figure, S is the physical size of imageing sensor along XY plane valid pixel scope; S
1for the vertical range of a point range image sensor central horizontal line, i.e. the image height of A point; S
2for the vertical range of b point range image sensor central horizontal line, i.e. the image height of B point.
By said process, obtain the image distance V that A point is corresponding
1, focal length F
1, image height S
1and the distance r of lens optical center and installation fulcrum
1; Obtain the image distance V that B point is corresponding
2, focal length F
2, image height S
2and the distance r of lens optical center and installation fulcrum
2.Carry out association according to above-mentioned imaging parameters to twice imaging to calculate, obtain the relative coordinate of tested point A.Specifically computation process is introduced below in conjunction with Fig. 4.
According to Gaussian imaging equation
Calculate the object distance U of A point respectively
1with the object distance U of B point
2
Thus the distance (along optical axis direction) between the object plane obtaining twice imaging is:
Lens imaging principle according to Fig. 6
Ask A point and B point relative to the object height of camera optical axis respectively, the value of n and k namely in Fig. 4
According to the geometric relationship in Fig. 4, can draw
Formula (4), formula (6) and formula (7) are substituted into formula (8), draws
In like manner, can draw according to geometric relationship
Formula (4), formula (6) and formula (7) are substituted into formula (10), draws
Therefore,
L is the X-axis coordinate of tested point A, is designated as A
x.
A point is at object plane P
1the distance of the plane of upper distance optical axis vertical ground is A
z, the distance of the plane as a point distance optical axis vertical ground of A point is a
z, then
In like manner, according to physical size with proportional along physical size direction corresponding pixel points quantity, physical size (the image height a of picture point a along Z-direction is calculated to be
z).In Fig. 7, Q is the physical size of imageing sensor along Z-direction valid pixel scope.
Formula (2) is substituted into formula (13) draw
A
zfor the Z axis coordinate of tested point A; The Y-axis coordinate A of A point
ybe 0.Coordinate (the A of A point
x, A
y, A
z) be coordinate relative to E point preset coordinate system, if the physical coordinates of E point is known, then the actual geographic position coordinates of A point adds that by E point coordinate the relative coordinate of the A point calculated calculates.
As can be seen here, by twice or repeatedly imaging of monocular-camera, and utilize the internal data of monocular-camera, as information such as image distance, focal length and image sensor size, carry out imaging parameters associating the position measurement calculating and can realize tested point.In the process, without the need to measuring the installation parameter of video camera and demarcating demarcation thing, human and material resources and time cost is saved, the operating process of simplification.
The foregoing is only preferred embodiment of the present invention, not in order to limit the present invention, within the spirit and principles in the present invention all, any amendment made, equivalent replacement, improvement etc., all should be included within the scope of protection of the invention.
Claims (8)
1., based on a 3d space measuring method for monocular-camera, it is characterized in that, the method comprises:
Respectively to ground tested point and the focusing of subtest point, obtain corresponding imaging parameters, wherein, described subtest point is positioned at camera optical axis on the projection line on ground, described tested point is different from described subtest point object distance, and the video camera installation parameter of twice imaging is constant;
According to the imaging parameters of described tested point and described subtest point, carry out association to twice imaging to calculate, obtain the relative coordinate of described tested point, the reference coordinate of described relative coordinate is, with video camera, fulcrum is installed and is projected as initial point on ground, with the vertical line on this fulcrum and ground for Y-axis, be projected as X-axis, with the direction vertical with Y-axis with X-axis for Z axis with camera optical axis along ground.
2. the method for claim 1, is characterized in that:
X-axis coordinate A in described tested point relative coordinate
xfor:
Wherein,
V
1for the image distance of described tested point;
F
1for the focal length of described tested point;
S
1for described tested point is along the image height of XY plane;
R
1for the distance (along camera optical axis) of fulcrum installed by the lens optical center of described tested point and video camera;
V
2for the image distance of described subtest point;
F
2for the focal length of described subtest point;
S
2for described subtest point is along the image height of XY plane;
R
2for the distance (along camera optical axis) of fulcrum installed by the lens optical center of described subtest point and video camera.
3. the method for claim 1, is characterized in that:
Z axis coordinate A in described tested point relative coordinate
zfor:
Wherein,
V
1for the image distance of described tested point;
F
1for the focal length of described tested point;
A
zfor described tested point is along the image height of Z-direction.
4. method as claimed in claim 2, is characterized in that:
Described A
xconcrete computation process be:
The object distance U of described tested point
1with the object distance U of described subtest point
2be respectively:
Thus obtain the object plane P of twice imaging
1and P
2between distance (along optical axis direction) j+m be:
Ask described tested point perpendicular to the object height n of camera optical axis and the described subtest point object height k perpendicular to camera optical axis respectively:
Above-mentioned parameter is substituted into geometric formula respectively
with
Can obtain
A
x=L
1+L
2。
5. based on a 3d space measurement mechanism for monocular-camera, it is characterized in that, this device comprises:
Imaging parameters acquiring unit, for focusing to ground tested point and subtest point respectively, obtain corresponding imaging parameters, wherein, described subtest point is positioned at camera optical axis on the projection line on ground, described tested point is different from described subtest point object distance, and the video camera installation parameter of twice imaging is constant;
Relative coordinate computing unit, for the imaging parameters according to described tested point and described subtest point, carry out association to twice imaging to calculate, obtain the relative coordinate of described tested point, the reference coordinate of described relative coordinate is, installs fulcrum be projected as initial point on ground with video camera, with the vertical line on this fulcrum and ground for Y-axis, X-axis is projected as, with the direction vertical with Y-axis with X-axis for Z axis along ground with camera optical axis.
6. device as claimed in claim 5, is characterized in that:
Described relative coordinate computing unit calculates the X-axis coordinate A of described tested point
xfor:
Wherein,
V
1for the image distance of described tested point;
F
1for the focal length of described tested point;
S
1for described tested point is along the image height of XY plane;
R
1for the distance (along camera optical axis) of fulcrum installed by the lens optical center of described tested point and video camera;
V
2for the image distance of described subtest point;
F
2for the focal length of described subtest point;
S
2for described subtest point is along the image height of XY plane;
R
2for the distance (along camera optical axis) of fulcrum installed by the lens optical center of described subtest point and video camera.
7. device as claimed in claim 5, is characterized in that:
Described relative coordinate computing unit calculates the Z axis coordinate A of described tested point
zfor:
Wherein,
V
1for the image distance of described tested point;
F
1for the focal length of described tested point;
A
zfor described tested point is along the image height of Z-direction.
8. device as claimed in claim 6, is characterized in that:
Described relative coordinate computing unit calculates described A
xdetailed process be:
The object distance U of described tested point
1with the object distance U of described subtest point
2be respectively:
Thus obtain the object plane P of twice imaging
1and P
2between distance (along optical axis direction) j+m be:
Ask described tested point perpendicular to the object height n of camera optical axis and the described subtest point object height k perpendicular to camera optical axis respectively:
Above-mentioned parameter is substituted into geometric formula respectively
with
Can obtain
A
x=L
1+L
2。
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410339869.9A CN105333818B (en) | 2014-07-16 | 2014-07-16 | 3d space measuring method based on monocular-camera |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410339869.9A CN105333818B (en) | 2014-07-16 | 2014-07-16 | 3d space measuring method based on monocular-camera |
Publications (2)
Publication Number | Publication Date |
---|---|
CN105333818A true CN105333818A (en) | 2016-02-17 |
CN105333818B CN105333818B (en) | 2018-03-23 |
Family
ID=55284479
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410339869.9A Active CN105333818B (en) | 2014-07-16 | 2014-07-16 | 3d space measuring method based on monocular-camera |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105333818B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109931906A (en) * | 2019-03-28 | 2019-06-25 | 杭州华雁云态信息技术有限公司 | Video camera distance measuring method, device and electronic equipment |
CN110225400A (en) * | 2019-07-08 | 2019-09-10 | 北京字节跳动网络技术有限公司 | A kind of motion capture method, device, mobile terminal and storage medium |
CN113115017A (en) * | 2021-03-05 | 2021-07-13 | 上海炬佑智能科技有限公司 | 3D imaging module parameter inspection method and 3D imaging device |
Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101183206A (en) * | 2006-11-13 | 2008-05-21 | 华晶科技股份有限公司 | Method for calculating distance and actuate size of shot object |
CN101344376A (en) * | 2008-08-28 | 2009-01-14 | 上海交通大学 | Measuring method for spacing circle geometric parameter based on monocular vision technology |
KR20110025724A (en) * | 2009-09-05 | 2011-03-11 | 백상주 | Method for measuring height of a subject using camera module |
CN102168954A (en) * | 2011-01-14 | 2011-08-31 | 浙江大学 | Monocular-camera-based method for measuring depth, depth field and sizes of objects |
CN102661717A (en) * | 2012-05-09 | 2012-09-12 | 河北省电力建设调整试验所 | Monocular vision measuring method for iron tower |
CN103033132A (en) * | 2012-12-20 | 2013-04-10 | 中国科学院自动化研究所 | Plane measuring method and plane measuring device based on monocular vision |
CN103049918A (en) * | 2011-10-17 | 2013-04-17 | 天津市亚安科技股份有限公司 | Method for accurately calculating size of actual target in video frequency monitoring |
CN103206919A (en) * | 2012-07-31 | 2013-07-17 | 广州三星通信技术研究有限公司 | Device and method used for measuring object size in portable terminal |
CN103292695A (en) * | 2013-05-10 | 2013-09-11 | 河北科技大学 | Monocular stereoscopic vision measuring method |
CN103471500A (en) * | 2013-06-05 | 2013-12-25 | 江南大学 | Conversion method of plane coordinate and space three-dimensional coordinate point in vision of monocular machine |
-
2014
- 2014-07-16 CN CN201410339869.9A patent/CN105333818B/en active Active
Patent Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101183206A (en) * | 2006-11-13 | 2008-05-21 | 华晶科技股份有限公司 | Method for calculating distance and actuate size of shot object |
CN101344376A (en) * | 2008-08-28 | 2009-01-14 | 上海交通大学 | Measuring method for spacing circle geometric parameter based on monocular vision technology |
KR20110025724A (en) * | 2009-09-05 | 2011-03-11 | 백상주 | Method for measuring height of a subject using camera module |
CN102168954A (en) * | 2011-01-14 | 2011-08-31 | 浙江大学 | Monocular-camera-based method for measuring depth, depth field and sizes of objects |
CN103049918A (en) * | 2011-10-17 | 2013-04-17 | 天津市亚安科技股份有限公司 | Method for accurately calculating size of actual target in video frequency monitoring |
CN102661717A (en) * | 2012-05-09 | 2012-09-12 | 河北省电力建设调整试验所 | Monocular vision measuring method for iron tower |
CN103206919A (en) * | 2012-07-31 | 2013-07-17 | 广州三星通信技术研究有限公司 | Device and method used for measuring object size in portable terminal |
CN103033132A (en) * | 2012-12-20 | 2013-04-10 | 中国科学院自动化研究所 | Plane measuring method and plane measuring device based on monocular vision |
CN103292695A (en) * | 2013-05-10 | 2013-09-11 | 河北科技大学 | Monocular stereoscopic vision measuring method |
CN103471500A (en) * | 2013-06-05 | 2013-12-25 | 江南大学 | Conversion method of plane coordinate and space three-dimensional coordinate point in vision of monocular machine |
Non-Patent Citations (2)
Title |
---|
李荣明 等: "单目视觉定位方法研究综述", 《现代计算机(专业版)》 * |
武德臣 等: "单目视觉定位模型及其参数辨识", 《中国人工智能学会第12届全国学术年会论文集(上) 中国人工智能进展(2007)》 * |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109931906A (en) * | 2019-03-28 | 2019-06-25 | 杭州华雁云态信息技术有限公司 | Video camera distance measuring method, device and electronic equipment |
CN109931906B (en) * | 2019-03-28 | 2021-02-23 | 华雁智科(杭州)信息技术有限公司 | Camera ranging method and device and electronic equipment |
CN110225400A (en) * | 2019-07-08 | 2019-09-10 | 北京字节跳动网络技术有限公司 | A kind of motion capture method, device, mobile terminal and storage medium |
CN110225400B (en) * | 2019-07-08 | 2022-03-04 | 北京字节跳动网络技术有限公司 | Motion capture method and device, mobile terminal and storage medium |
CN113115017A (en) * | 2021-03-05 | 2021-07-13 | 上海炬佑智能科技有限公司 | 3D imaging module parameter inspection method and 3D imaging device |
CN113115017B (en) * | 2021-03-05 | 2022-03-18 | 上海炬佑智能科技有限公司 | 3D imaging module parameter inspection method and 3D imaging device |
Also Published As
Publication number | Publication date |
---|---|
CN105333818B (en) | 2018-03-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101825431B (en) | Reference image techniques for three-dimensional sensing | |
CN102509261B (en) | Distortion correction method for fisheye lens | |
CN109489620B (en) | Monocular vision distance measuring method | |
CN111210468B (en) | Image depth information acquisition method and device | |
WO2018196391A1 (en) | Method and device for calibrating external parameters of vehicle-mounted camera | |
CN105424006B (en) | Unmanned plane hovering accuracy measurement method based on binocular vision | |
CN105451012B (en) | 3-D imaging system and three-D imaging method | |
CN104155765B (en) | The method and apparatus of revision for 3-D image in spliced integration imaging display | |
CN111192235B (en) | Image measurement method based on monocular vision model and perspective transformation | |
CN110996082B (en) | Projection adjusting method and device, projector and readable storage medium | |
ES2762867T3 (en) | Procedure and apparatus for the compensation of static image distortions introduced by a windshield into an ADAS camera | |
CN102810205A (en) | Method for calibrating camera shooting or photographing device | |
CN103292710A (en) | Distance measuring method applying binocular visual parallax error distance-measuring principle | |
CN109862345B (en) | Method and system for testing field angle | |
JP6791341B2 (en) | Calibration method, calibration equipment, and program | |
CN111508027A (en) | Method and device for calibrating external parameters of camera | |
JP2015163866A (en) | Stereocamera calibration method, parallax calculation device and stereocamera | |
CN105025284A (en) | Method and device for calibrating display error of integral imaging display device | |
CN104807405A (en) | Three-dimensional coordinate measurement method based on light ray angle calibration | |
RU2602729C2 (en) | Method of distance to object determining by means of camera (versions) | |
CN105333818A (en) | 3D space measurement method based on monocular camera | |
JP6376809B2 (en) | Projection device and imaging device used in three-dimensional shape measurement system | |
JP2018179577A (en) | Position measuring device | |
RU2592711C1 (en) | Method and system for calibration of complex for measurement of vehicle speed | |
CN109945840B (en) | Three-dimensional image shooting method and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |