Two-dimensional calibration method, projector and the calibration system of projectorTechnical field
The present invention relates to two-dimensional calibration method, projector and the calibration systems of a kind of projector.
Background technique
Three-dimensional reconstruction refers to the mathematical model established to three-dimension object and be suitble to computer representation and processing, is in computer ringThe basis of its property is handled it, operated and analyzed under border, and establishes the virtual of expression objective world in a computerThe key technology of reality.
It is a kind of three-dimensional reconstruction mode that optical grating projection, which carries out three-dimensional reconstruction, and grating is projected to reference planes respectively and is testedBody surface, what it is due to reference planes selection is horizontal plane, and the reference grating projected to above will not deform;Work as gratingWhen projecting to testee surface, grating can generate different degrees of deformation, be that measured object body surface is received due to projection gratingThe modulation of face height.The testee height placed is different, and the phase change degree of grating is also different therewith, and two-dimensional surface becomesThe three-dimensional appearance information of body surface is carried in the phase change of shape striped.It therefore, can be with by seeking the changing value of phaseHeight of the object at respective point is obtained, to obtain the chamfered shape of three-dimension object.
Existing optical grating projection exist in three-dimensional reconstruction it is higher to projection arrangement required precision, civilian projector becauseDistortion phenomenon can not obtain the defect of accurately 3D model.
Summary of the invention
The technical problem to be solved by the present invention is to exist to overcome in optical grating projection progress three-dimensional reconstruction in the prior artHigher to projection arrangement required precision, civilian projector provides one because distortion phenomenon can not obtain the defect of accurate 3D modelKind can be improved the fidelity factor of projector projects image, promotes drop shadow effect, it is more quasi- to establish 3D model using projector gratingTwo-dimensional calibration method, projector and the calibration system of true projector.
The present invention is to solve above-mentioned technical problem by following technical proposals:
A kind of two-dimensional calibration method of projector, it is characterized in that, the two-dimensional calibration method includes:
The projector successively projects several grayscale images according to brightness value, and each grayscale image is equipped with a brightness value;
The grayscale image of the projector projects is shot to obtain filmed image, each filmed image and measurement image are one by oneIt is corresponding;
The corresponding relationship for obtaining the brightness value of grayscale image and the luminance information of filmed image, wherein the luminance information packetInclude the related information between at least two brightness values and brightness value;
The projector obtains a measurement image using one target image of inversion process of the corresponding relationship.
Preferably, the corresponding relationship of the luminance information of the brightness value for obtaining grayscale image and filmed image includes:
For a target filmed image, the corresponding filmed image of target filmed image is divided into several imagery zones;
Obtain the brightness value of each imagery zone and the location information of imagery zone;
The luminance information is obtained according to the brightness value of imagery zone and location information;
Obtain the corresponding relationship of the brightness value of grayscale image and the luminance information of filmed image.
Preferably, the corresponding relationship is the mapping table of the brightness value of grayscale image and the luminance information of filmed image, instituteIt states projector and successively projects several grayscale images according to brightness value and include:
Obtain the image of a n-bit;
The image of the n-bit is divided into 2nThe gray level image of/m brightness degree, any two neighboring gradation imageBrightness value difference be m.
Preferably, the grayscale image of the shooting projector projects includes: to obtain filmed image
The grayscale image of the projector projects is shot to obtain initial image;
The projection of the projector in the initial image is obtained by comparing the difference section in adjacent initial imageArea image;
The image of a pre-set dimension is intercepted in view field's image as the filmed image.
Preferably, the two-dimensional calibration method includes:
Identify view field's image of the projector in the initial image;
Obtain the background video in addition to view field's image;
Obtain the average brightness of background area;
A background luminance offset is obtained according to average brightness;
The corresponding relationship of the brightness value of grayscale image and the optimization brightness value of filmed image is obtained, the optimization brightness value isThe filmed image is in conjunction with the brightness value after the background luminance offset.
Preferably, the two-dimensional calibration method includes:
The projector obtains a grating measurement image using one raster image of inversion process of the corresponding relationship;
The projector projects the grating measurement image to a target object;
The projection image for shooting the grating measurement image has generated feedback image;
According to the 3D model of target object described in the feedback video generation.
The present invention also provides a kind of projectors, it is characterized in that, the projector includes a projection module, an acquisition moduleAnd a calibration module,
The projection module is equipped with a brightness for successively projecting several grayscale images, each grayscale image according to brightness valueValue;
The corresponding relationship for obtaining module and being used to obtain the brightness value of grayscale image and the luminance information of filmed image,Described in luminance information include related information between at least two brightness values and brightness value, the filmed image is described in shootingFilmed image acquired in the grayscale image of projector projects, each filmed image and measurement image correspond;
The calibration module is used to obtain a measurement image using one target image of inversion process of the corresponding relationship.
Preferably, the corresponding relationship is the mapping table of the brightness value of grayscale image and the luminance information of filmed image, instituteProjection module is stated for obtaining the image of a n-bit, and the image of the n-bit is divided into 2nThe gray scale of/m brightness degreeImage, the difference of the brightness value of any two neighboring gradation image are m.
Preferably, pair for obtaining module and being used to obtain the brightness value of grayscale image and the optimization brightness value of filmed imageIt should be related to, the optimization brightness value is the brightness value after the filmed image combination background luminance offset, the background luminanceOffset is obtained by the average brightness of the background video in the filmed image in addition to view field's image.
The present invention also provides a kind of calibration systems, it is characterized in that, the calibration system includes that a projector and one clapDevice is taken the photograph, the calibration system is for realizing two-dimensional calibration method as described above.
On the basis of common knowledge of the art, above-mentioned each optimum condition, can any combination to get each preferable reality of the present inventionExample.
The positive effect of the present invention is that:
Two-dimensional calibration method, projector and the calibration system of projector of the invention can make to improve projector projects shadowThe fidelity factor of picture promotes drop shadow effect, it is more accurate to establish 3D model using projector grating.
Detailed description of the invention
Fig. 1 is the flow chart of the two-dimensional calibration method of the projector of the embodiment of the present invention 1.
Fig. 2 is the flow chart of the two-dimensional calibration method of the projector of the embodiment of the present invention 2.
Specific embodiment
The present invention is further illustrated below by the mode of embodiment, but does not therefore limit the present invention to the realityIt applies among a range.
Embodiment 1
The present embodiment provides a kind of calibration system, the calibration system includes a projector and a filming apparatus.
The projector includes a projection module, an acquisition module and a calibration module.
The projection module is equipped with a brightness for successively projecting several grayscale images, each grayscale image according to brightness valueValue.
Specifically, the projection module is used to obtain the image of a n-bit, and the image of the n-bit is divided into 2n/The gray level image of m brightness degree, the difference of the brightness value of any two neighboring gradation image are m.
In the present embodiment, the n value is that 8, m value is 2.
The filming apparatus is used to shoot the grayscale image of the projector projects to obtain filmed image, each shooting shadowAs being corresponded with measurement image;
The calibration system of the present embodiment further includes a processing end, the processing end be used to generate the brightness value of grayscale image withThe corresponding relationship of the luminance information of filmed image.Wherein the luminance information includes between at least two brightness values and brightness valueRelated information.
The acquisition module is for obtaining the corresponding relationship.
The calibration module is used to obtain a measurement image using one target image of inversion process of the corresponding relationship.
Specifically, in the present embodiment:
For a target filmed image, processing end is used to the corresponding filmed image of target filmed image being divided into several shadowsAs region, and obtain the brightness value of each imagery zone and the location information of imagery zone;Then according to the bright of imagery zoneAngle value and location information obtain the luminance information, ultimately produce the brightness value of grayscale image and the luminance information of filmed imageCorresponding relationship.
Since area grayscale value different in filmed image is different, the application is according to the gray value of different zones to calibrateProjector is stated, projector can be made to obtain higher fidelity.
3D model can also be generated using the calibration system, comprising:
The projector is also used to be obtained a grating using one raster image of inversion process of the corresponding relationship and be calibratedImage.
The projector is also used to project the grating measurement image to a target object.
The projection image that the filming apparatus is used to shoot the grating measurement image has generated feedback image;
The processing end is used for the 3D model of the target object according to the feedback video generation.
In the prior art, 3D is rebuild needs to calculate the phase shift of each point according to the grating that projects, it is to capturingThe linearity of image is highly sensitive.When doing projection grating with consumer projection, the brightness of projection have passed through Gamma variation, projectionThe nonuniformity of apparatus body, when capturing projection grating with industrial camera, the original image tonal gradation of projection and the ash of candid photographSpending grade, there are non-linear relations.General approach is the gamma parameter of preparatory estimation projection output, is subtracted to the image of candid photographAfter going a background luminance, the gamma that then negates transformation obtains the tonal gradation of approximate projection image, throwing is calculated with thisThe algorithm of shadow grating.
The method has the disadvantage that
The method of passive type correction needs to estimate background value under different luminance backgrounds.Background luminance may be in real timeVariation, therefore 3D reconstruction requires to re-evaluate background luminance every time, and system real time is caused to be deteriorated.If disposable estimation,System robustness is deteriorated, and system accuracy is caused to be deteriorated.
Since background luminance is not uniformly, in order to estimate the brightness of entire projector space in projector projects area of spaceThere are larger problems for value, and as time change or the shadow change, will lead to background luminance and changing, cause veryBackground luminance be it is unstable, it is not high so as to cause 3D reconstruction precision.
Existing active disadvantage: exist with polynomial curve fitting is non-linear and cannot restore completely linear.
The present embodiment is able to solve drawbacks described above, realizes the fidelity factor for improving projector projects image, promotes drop shadow effect,It is more accurate that 3D model is established using projector grating
First find out the linear relationship of projector brightness and projection input greyscale level.By the ash for projecting different brightness degreesDegree figure, the central part of view field is captured using advanced camera, analyzes the non-thread of projection image tonal gradation and brightness degreeSexual intercourse indicates received filmed image with function representation LCD_out=f (input_level), LCD_out, above-mentioned non-linearRelationship (corresponding relationship) can in tabular form or curve coefficients expression way, it is ensured that the entirety of function representation can notReach minimum, if function representation is inaccurate, can indicate non-linear conversion relationship according to table corresponding relationship.
It is nonlinear in order to solve the problems, such as, before picture projection, picture according to the gamma of LCD, inverse transformation is carried out,When reprojection, Gamma variation (Gamma correction) is being carried out, the brightness projected in this way is exactly linear.It solves and hasThe nonlinear problem of gamma projection.
Referring to Fig. 1, using above-mentioned calibration system, the present embodiment provides a kind of two-dimensional calibration methods, comprising:
Step 100, the image for obtaining a n-bit;
The image of the n-bit is divided into 2 by step 101nThe gray level image of/m brightness degree, each grayscale imageEquipped with a brightness value, the difference of the brightness value of any two neighboring gradation image is m;
Step 102 shoots the grayscale image of the projector projects to obtain filmed image, each filmed image and calibrationImage corresponds;
Step 103, for a target filmed image, the corresponding filmed image of target filmed image is divided into several imagesRegion;
The location information of step 104, the brightness value for obtaining each imagery zone and imagery zone;
Step 105 obtains the luminance information according to the brightness value and location information of imagery zone;
The corresponding relationship of the luminance information of step 106, the brightness value for obtaining grayscale image and filmed image.
In the present embodiment, the number of the imagery zone is 12, and the area in each region is identical, wherein the brightnessInformation includes at least 12 related informations between brightness value and brightness value, the related information refer to the brightness value in region withPosition in filmed image is associated.
Step 107, the projector obtain a calibration shadow using one target image of inversion process of the corresponding relationshipPicture.
In the present embodiment, the n value is that 8, m value is 2.
128 gray level images are obtained, the brightness value of each image is successively 0,2,4,6 ..., it is corresponding, the present embodimentFilmed image obtain view field luminance information be respectively corresponding to 0 one include 12 brightness values and location informationList, corresponding to 2 one include the list of 12 brightness values and location information, corresponding to 4 one include 12 brightThe list of angle value and location information, corresponding to 6 one include 12 brightness values and location information list ....
Mapping form is established using the luminance information of above-mentioned gray level image and filmed image.
The measurement image of more fidelity can be obtained come processing target image using the inverse transformation of the mapping.
It can be realized 3D modeling using above-mentioned two-dimensional calibration method, comprising:
The projector obtains a grating measurement image using one raster image of inversion process of the corresponding relationship;
The projector projects the grating measurement image to a target object;
The projection image for shooting the grating measurement image has generated feedback image;
According to the 3D model of target object described in the feedback video generation.
Two-dimensional calibration method, projector and the calibration system of the projector of the present embodiment can make to improve projector projectsThe fidelity factor of image promotes drop shadow effect, it is more accurate to establish 3D model using projector grating.
Embodiment 2
The present embodiment is substantially the same manner as Example 1, the difference is that only:
The filming apparatus is used to shoot the grayscale image of the projector projects to obtain initial image;
View field's image of the processing end projector in the initial image for identification specifically leads toCross the view field's image for comparing the projector that the difference section in adjacent initial image obtains in the initial image.
The processing end is also used to intercept the image of a pre-set dimension in view field's image as the filmed image.
The processing end is also used to identify view field's image of the projector in the initial image, and obtains and removeThen background video other than view field's image obtains the average brightness of background area, finally average according to brightnessValue obtains a background luminance offset;
The acquisition module of the projector is used to obtain the brightness value of grayscale image and the optimization brightness value of filmed imageCorresponding relationship, the optimization brightness value are the filmed image in conjunction with the brightness value after the background luminance offset.
Corresponding, the two-dimensional calibration method of the present embodiment includes:
Step 200 shoots the grayscale image of the projector projects to obtain initial image;
View field's image of step 201, the projector in the identification initial image, it is adjacent initial by comparingDifference section in image obtains view field's image of the projector in the initial image.
Step 202 intercepts the image of a pre-set dimension as the filmed image in view field's image.
View field's image of step 203, the projector in the identification initial image;
The background video of step 204, acquisition in addition to view field's image;
Step 205, the average brightness for obtaining background area;
Step 206 obtains a background luminance offset according to average brightness;
The corresponding relationship of the optimization brightness value of step 207, the brightness value for obtaining grayscale image and filmed image, the optimizationBrightness value is the filmed image in conjunction with the brightness value after the background luminance offset.
Although specific embodiments of the present invention have been described above, it will be appreciated by those of skill in the art that theseIt is merely illustrative of, protection scope of the present invention is defined by the appended claims.Those skilled in the art is not carrying on the backUnder the premise of from the principle and substance of the present invention, many changes and modifications may be made, but these are changedProtection scope of the present invention is each fallen with modification.