CN110365949A - A kind of bearing calibration of image color cast, device and electronic equipment - Google Patents
A kind of bearing calibration of image color cast, device and electronic equipment Download PDFInfo
- Publication number
- CN110365949A CN110365949A CN201810252674.9A CN201810252674A CN110365949A CN 110365949 A CN110365949 A CN 110365949A CN 201810252674 A CN201810252674 A CN 201810252674A CN 110365949 A CN110365949 A CN 110365949A
- Authority
- CN
- China
- Prior art keywords
- pixel
- overexposure
- value
- pixel value
- parameter preset
- 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
- 238000000034 method Methods 0.000 claims abstract description 75
- 238000013507 mapping Methods 0.000 claims abstract description 42
- 230000008569 process Effects 0.000 claims abstract description 34
- 238000006243 chemical reaction Methods 0.000 claims abstract description 24
- 238000012545 processing Methods 0.000 claims description 19
- 238000004364 calculation method Methods 0.000 claims description 7
- 230000009466 transformation Effects 0.000 claims description 4
- 230000000717 retained effect Effects 0.000 claims 2
- 238000004422 calculation algorithm Methods 0.000 abstract description 4
- 238000012937 correction Methods 0.000 description 45
- 230000000694 effects Effects 0.000 description 6
- 230000007704 transition Effects 0.000 description 5
- 230000003044 adaptive effect Effects 0.000 description 4
- 238000004458 analytical method Methods 0.000 description 4
- 238000010586 diagram Methods 0.000 description 4
- 230000008859 change Effects 0.000 description 2
- 238000004590 computer program Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000002708 enhancing effect Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 238000012360 testing method Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/10—Cameras or camera modules comprising electronic image sensors; Control thereof for generating image signals from different wavelengths
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/70—Circuitry for compensating brightness variation in the scene
- H04N23/73—Circuitry for compensating brightness variation in the scene by influencing the exposure time
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N23/00—Cameras or camera modules comprising electronic image sensors; Control thereof
- H04N23/80—Camera processing pipelines; Components thereof
- H04N23/84—Camera processing pipelines; Components thereof for processing colour signals
- H04N23/88—Camera processing pipelines; Components thereof for processing colour signals for colour balance, e.g. white-balance circuits or colour temperature control
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N9/00—Details of colour television systems
- H04N9/64—Circuits for processing colour signals
- H04N9/646—Circuits for processing colour signals for image enhancement, e.g. vertical detail restoration, cross-colour elimination, contour correction, chrominance trapping filters
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Image Processing (AREA)
- Color Television Image Signal Generators (AREA)
- Studio Devices (AREA)
Abstract
The present invention provides bearing calibration, device and the electronic equipment of a kind of image color cast, which comprises obtains the overexposure pixel of input picture;Judge the overexposure type of the overexposure pixel;Tone mapping conversion process is carried out according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel or the overexposure pixel is carried out to retain line position tagging of going forward side by side.The present invention is capable of providing a kind of simple image color cast correcting algorithm and to correct image color cast simple and easy, while also reducing hardware resource occupancy, is conducive to hardware realization;And there can also be preferable calibration result to because of colour cast region caused by some channel overexposure, and then enhance picture quality.
Description
Technical field
The present invention relates to technical field of image processing more particularly to a kind of bearing calibrations of image color cast, device and electronics
Equipment.
Background technique
Currently, conventional images system mainly passes through image signal process (ISP:Image Signal Processing) use
To carry out front-end image sensor output signal (Raw data) camera lens shadow correction, white balance, bad point repairing, denoising,
Gamma correction, color interpolation, the processing such as edge enhancing.No matter digital camera or camera mobile phone, obtained in sensor (sensor)
Data are obtained after analog-digital converter (ADC:Analog Digital Converter), require the processing by ISP, but herein
There are following situations in the process leads to overexposure situation:
(1) if phase built-in sensor (sensor) obtain data when exposure parameter it is improper, lead to sensor
(sensor) data obtained are more than the maximum value for the pixel value that sensor unit can accommodate, at this point, need to carry out the data
It cuts (i.e. clip), and then the pixel value of the pixel is caused to change, loss of data.
(2) if exposure parameter when phase built-in sensor (sensor) obtains data is obtaining sensor (sensor)
Not having pixel when data is more than the maximum value that sensor unit can accommodate, and in passing through ISP treatment process, by camera lens yin
Shadow correction, the resume modules such as white balance, the gain compensation of application cause pixel value to be more than open ended on ISP processor pipeline
Therefore maximum value also needs the data being cut (i.e. clip), and then the pixel value of the pixel is caused to change, data
It loses.Wherein, if having pixel by cutting (i.e. clip), overexposure can be occurred, or because of color colour cast caused by clip, it can be straight
Influence picture quality is connect, the experience sense of user is reduced.
But it is existing for passing through camera lens shadow correction, after the overexposure image that the resume modules such as white balance are formed carries out
Processing, but biggish template is generally required, it is iterated calculating, processing is complicated and resources occupation rate is big;Simultaneously for large area
Overexposure region, effect is also undesirable.
Summary of the invention
Bearing calibration, device and the electronic equipment of image color cast provided by the invention are capable of providing a kind of simple image
Colour cast correcting algorithm makes correction image color cast simple and easy, while also reducing hardware resource occupancy, is conducive to hardware realization;And
And there can also be preferable calibration result to because of colour cast region caused by some channel overexposure, and then enhance picture quality.
In a first aspect, the present invention provides a kind of bearing calibration of image color cast, comprising:
Obtain the overexposure pixel of input picture;
Judge the overexposure type of the overexposure pixel;
Tone mapping transformation is carried out according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel
It handles or the overexposure pixel is carried out to retain line position tagging of going forward side by side.
Optionally, described that color is carried out according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel
Tune mapping transformation handles or carries out retaining line position tagging of going forward side by side to the overexposure pixel
When leading to overexposure after the overexposure pixel is handled by gain compensation, then to the pixel value of overexposure pixel into
Row tone mapping conversion process;
When the overexposure pixel is to lead to overexposure by sensor automatic exposure, then the overexposure pixel is protected
Stay line position tagging of going forward side by side.
Optionally, described when leading to overexposure after the overexposure pixel is handled by gain compensation, then to overexposure pixel
The pixel value of point carries out tone mapping conversion process:
According to the overexposure region information threshold value v of input picturemax;
By the first pixel value R of overexposure pixel1Mapping is carried out according to the tone mapping curve that following formula indicates to obtain
Second pixel value R2;
Wherein, A be the first parameter preset and, th2 corresponding with the data area of sensor be the second parameter preset,
Sigma is third parameter preset and is calculated by f (th2)=th2.
Optionally, before the overexposure pixel for obtaining input picture, the method also includes:
Obtain whole pixels of input picture;
The corresponding overexposure degree value of each pixel is obtained according to the calculated for pixel values of each pixel.
Optionally, the calculated for pixel values according to each pixel show that the corresponding overexposure degree value of each pixel includes:
Respectively each pixel is carried out each channel pixel value of the corresponding RGB of each pixel of interpolation calculation acquisition and compared to obtain
Channel maximum value pcmax;
By the channel maximum value pcmaxIt is calculated as follows and obtains overexposure degree value ROE;
Wherein, a is the 4th parameter preset and a > 0, lth1For the 5th parameter preset, hth1For the 6th parameter preset, and lth1
< hth1。
Optionally, it is carried out described according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel
It tone mapping conversion process or the overexposure pixel retain goes forward side by side after line position tagging, the method is also wrapped
It includes:
By the second pixel value R2, pixel overexposure degree RoeWith the first pixel value R of pixel1According to following public affairs
Final pixel value R is calculated in formulaout;
According to final pixel value RoutExport image.
Second aspect, the present invention provide a kind of means for correcting of image color cast, comprising:
First acquisition unit, for obtaining the overexposure pixel of input picture;
Judging unit, for judging the overexposure type of the overexposure pixel;
Control unit, for being carried out according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel
It tone mapping conversion process or the overexposure pixel retain goes forward side by side line position tagging.
Optionally, described control unit includes:
Processing module, when for leading to overexposure after the overexposure pixel is handled by gain compensation, then to overexposure picture
The pixel value of vegetarian refreshments carries out tone mapping conversion process;
Reservation module, for when the overexposure pixel is to lead to overexposure by sensor automatic exposure, then to the mistake
Pixel is exposed to carry out retaining line position tagging of going forward side by side.
Optionally, the processing module includes:
Threshold value determines submodule, for the overexposure region information threshold value v according to input picturemax;
Submodule is handled, for by the first pixel value R of overexposure pixel1The tone mapping indicated according to following formula is bent
Line carries out mapping and obtains the second pixel value R2;
Wherein, A be the first parameter preset and, th2 corresponding with the data area of sensor be the second parameter preset,
Sigma is third parameter preset and is calculated by f (th2)=th2.
Optionally, described device further include:
Second acquisition unit, for obtaining whole pixels of input picture;
First computing unit, for obtaining the corresponding overexposure degree value of each pixel according to the calculated for pixel values of each pixel
Roe;
Second computing unit is used for the second pixel value R2, pixel overexposure degree RoeWith the first of pixel
Pixel value R1Final pixel value R is calculated according to following formulaout;
Wherein, a is the 4th parameter preset and a > 0;
Output unit, for according to final pixel value RoutExport image.
The third aspect, the present invention provide a kind of electronic equipment, and the electronic equipment includes the correction dress of above-mentioned image color cast
It sets.
Bearing calibration, device and the electronic equipment of image color cast provided in an embodiment of the present invention, the method are mainly logical
Cross analysis image overexposure reason, wherein the present embodiment the method can be logical to channel a certain in input picture overexposure or RGB tri-
Road all overexposure the reason of analyzed, the overexposure type of the overexposure pixel is judged, for example, due to exposure sensor parameter
Improper or ISP processing module limitation itself, which is arranged, causes pixel overexposure (such as through camera lens shadow correction or white balance correction
After resume module).The present embodiment the method separately handles the overexposure pixel overexposure of different overexposure types, and adaptive
The color and details of the tone mapping conversion process answered also original image script realize the correction of color of image colour cast.The present embodiment
The method calculates simply, and hardware resource occupancy is small, is especially advantageous for hardware realization;And it can also be led to because of some channel overexposure
There is preferable calibration result in the colour cast region of cause.
Detailed description of the invention
Fig. 1 is the flow chart of the bearing calibration of one embodiment of the invention image color cast;
Fig. 2 is the flow chart of the bearing calibration of another embodiment of the present invention image color cast;
Fig. 3 is the overexposure degree schematic diagram of one embodiment of the invention image slices vegetarian refreshments;
Fig. 4 is tone mapping curve synoptic diagram in one embodiment of the invention tone mapping conversion process;
Fig. 5 is the structural schematic diagram of the means for correcting of one embodiment of the invention image color cast;
Fig. 6 is the structural schematic diagram of the means for correcting of another embodiment of the present invention image color cast.
Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention
In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is only
It is only a part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, ordinary skill
Personnel's every other embodiment obtained without making creative work, shall fall within the protection scope of the present invention.
The embodiment of the present invention provides a kind of bearing calibration of image color cast, as shown in Figure 1, which comprises
S11, the overexposure pixel for obtaining input picture;
S12, the overexposure type for judging the overexposure pixel;
S13, tone mapping is carried out according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel
It conversion process or the overexposure pixel retain goes forward side by side line position tagging.
The bearing calibration of image color cast provided in an embodiment of the present invention mainly passes through analysis image overexposure reason, wherein
The present embodiment the method can to tri- channels of channel a certain in input picture overexposure or RGB all overexposure the reason of analyze,
The overexposure type of the overexposure pixel is judged, for example, since exposure sensor parameter setting is improper or ISP handles mould
Block limitation itself leads to pixel overexposure (such as after camera lens shadow correction or white balance correction resume module).The present embodiment institute
It states method separately to handle the overexposure pixel overexposure of different overexposure types, and adaptive tone mapping conversion process is also
The color and details of original image script realize the correction of color of image colour cast.The present embodiment the method calculates simple, hardware money
Source occupancy is small, is especially advantageous for hardware realization;And there can also be preferable school to because of colour cast region caused by some channel overexposure
Plus effect.
Optionally, as shown in Fig. 2, the picture selected according to the overexposure type of the overexposure pixel to overexposure pixel
Plain value carries out tone mapping conversion process or carries out retaining line position tagging of going forward side by side to the overexposure pixel
When leading to overexposure after the overexposure pixel is handled by gain compensation, then to the pixel value of overexposure pixel into
Row tone mapping conversion process;
When the overexposure pixel is to lead to overexposure by sensor automatic exposure, then the overexposure pixel is protected
Stay line position tagging of going forward side by side.
Specifically, the present embodiment the method mainly will due to will through exposure sensor parameter setting improper and ISP
Processing module limitation itself causes the basic reason of pixel overexposure to be analyzed (such as through camera lens shadow correction or white balance school
After positive resume module) and it separates and is handled using different processing modes, wherein the present embodiment the method on the one hand will be by
In inaccurate, the non-treated necessity of the pixel value through the improper overexposure pixel of exposure sensor parameter setting, therefore,
Only the overexposure pixel is carried out to retain line position tagging of going forward side by side;And it can further utilize marked in the follow-up process
Overexposure pixel by transitions smooth between the pixel of calibrated processing and the pixel of non-correction process, improve color of image
The effect of correction;On the other hand it utilizes through camera lens shadow correction or white balance correction, after gain compensation processing in overexposure pixel
The correlation of interchannel is handled using scaled down and is corrected to the channel of overexposure.For example, in the present embodiment the method
For the raw data of sensor input picture, when by camera lens shadow correction, need multiplied by gain compensation camera lens surrounding due to
The dark angle that insufficient light is formed, and because the colour cast that the optical index difference of different color is formed.So for input picture
Raw data, there is no the pixel of overexposure after automatic exposure, after camera lens shadow correction, multiplied by gain compensation,
Also can make pixel value is more than maximum magnitude, and then by clip, loses information.
Therefore, the present embodiment the method carries out discriminatory analysis by the overexposure reason to overexposure pixel, to through camera lens
Shadow correction, treated that overexposure pixel is corrected compensation for white balance correction;It is passed caused by improper to exposure parameter setting
Just the pixel of overexposure has only been marked without correction process the data that sensor comes out.Thereby reduce the correction course of image color cast
In calculation amount, simplify image color cast correcting algorithm, improve the calibration result in image color cast region.
Optionally, as shown in figure 4, it is described when leading to overexposure after the overexposure pixel is handled by gain compensation, then
Carrying out tone mapping conversion process to the pixel value of overexposure pixel includes:
According to the overexposure region information threshold value v of input picturemax;
By the first pixel value R of overexposure pixel1Mapping is carried out according to the tone mapping curve that following formula indicates to obtain
Second pixel value R2;
Wherein, A be the first parameter preset and, th2 corresponding with the data area of sensor be the second parameter preset,
Sigma is third parameter preset and is calculated by f (th2)=th2.
Specifically, as shown in figure 4, the present embodiment the method is by adaptive tone mapping conversion process by higher bit
The data of position are mapped to the data of low bit position;For example, 14bit data are mapped to 10bit data.
Wherein, if in the present embodiment overexposure pixel the first pixel value R1< th2 then keeps original pixel value constant
(i.e. the second pixel value R2Equal to the first pixel value R1);If the first pixel value th2 < R of overexposure pixel1< vmax, then curve is used
By [th2, vmax] the first pixel value R1It is mapped to the second pixel value R of [th2, A]2;If the first pixel value of overexposure pixel
R1> vmax, then the second pixel value R2=A.
Further, the present embodiment the method can also according to input image information, device information adjustment will [th2,
vmax] the first pixel value R1It is mapped to the second pixel value R of [th2, A]2Curve;Wherein, the curve needs to meet a): single
What tune was incremented by;B): f (th2)=th2;C): f (vmax)=A.
Further, if finding threshold value v by experimental testmaxIt is too small, then it may cause large stretch of overexposure region and still deposit
If threshold value vmaxExcessive, curve is excessively flat, it is likely that causes certain highlight regions color saturations to reduce, and is possible to
The dynamic range of whole image is caused to become smaller.Therefore, the correction of the present embodiment the method image color cast in order to better improve
Effect, the present embodiment can be further according to the overexposure region information threshold value v of input picturemax;For example, statistics is entire defeated
Enter image in the average value v in overexposure (being greater than A) region after white balance gainsmean;vmax=vmean×vratio;vratioIt is
Seven parameter presets simultaneously can be corresponding with scene.
Optionally, before the overexposure pixel for obtaining input picture, the method also includes:
Obtain whole pixels of input picture;
The corresponding overexposure degree value of each pixel is obtained according to the calculated for pixel values of each pixel.
Specifically, since the data Raw data exported by ISP is the raw image data of Bayer (Bayer) format,
And each pixel only has single color channel values therefore to need in the present embodiment the method first to the mistake
The solid color channel value of exposure pixel carries out the corresponding tool of interpolation calculation acquisition pixel, and there are three the first of color channel values
Pixel value;For example, it is assumed that current point be the channel R, typical bayer format is as shown in the table, find out the current channel R other two
The value in a channel, obtains the value in tri- channels overexposure pixel R, G, B, then the B of current point, and the channel G is inserted by its surrounding pixel
Value obtains:
B | G | B |
G | R | G |
B | G | B |
In addition, also 4*4,5*5 ... n*n template can be used to carry out interpolation calculation when seeking RGB triple channel value.
Optionally, as shown in figure 3, the calculated for pixel values according to each pixel obtains the corresponding overexposure journey of each pixel
Angle value includes:
Respectively each pixel is carried out each channel pixel value of the corresponding RGB of each pixel of interpolation calculation acquisition and compared to obtain
Channel maximum value pcmax;
By the channel maximum value pcmaxIt is calculated as follows and obtains overexposure degree value ROE;
Wherein, a is the 4th parameter preset and a > 0, lth1For the 5th parameter preset, hth1For the 6th parameter preset, and lth1
< hth1。
Specifically, the present embodiment the method is in order to enable calibrated handle the mistake between the pixel without correction process
Degree is smooth, indicates that the overexposure degree curve of pixel allows overexposure and non-overexposure region transitions smooth using above-mentioned formula, wherein such as
Smooth transition can be achieved in three curves shown in Fig. 3.
Optionally, it is carried out described according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel
It tone mapping conversion process or the overexposure pixel retain goes forward side by side after line position tagging, the method is also wrapped
It includes:
By the second pixel value R2, pixel overexposure degree RoeWith the first pixel value R of pixel1According to following public affairs
Final pixel value R is calculated in formulaout;
According to final pixel value RoutExport image.
Specifically, by due to the improper caused overexposure picture of exposure sensor parameter setting in the present embodiment the method
Vegetarian refreshments, because it is when generating Raw data, information has been lost, i.e. R, G, and the ratio of B is incorrect, color non-original
This color, so and increase hardware resource occupancy very poor by color correction progress color reduction effect.Therefore, this implementation
Example the method is carried out retaining line position of going forward side by side and be set for leading to overexposure due to sensor automatic exposure to the overexposure pixel
The overexposure pixel of label utilizes overexposure degree RoeWith adjacent the second pixel value R after tone mapping conversion process2It will be through school
Transitions smooth between the pixel of the pixel and non-correction process that are just handling, wherein as the overexposure degree of pixel is more next
It is higher, final pixel value RoutWith original value R1(i.e. the first pixel value, wherein the first pixel value of the pixel includes overexposure
First pixel value of the first pixel value of pixel and non-overexposure pixel) it becomes closer to.
In conclusion the present embodiment the method passes through the overexposure type for judging overexposure pixel, and according to overexposure type
Optimal correcting mode is selected to carry out colour cast correction, on the one hand, the method can be improved after camera lens shadow correction module and be deposited
Storage space is wide, such as increases to 14bit by 10bit, the complete information after retaining camera lens shadow correction.Then after camera lens shadow correction
Color correction is carried out to the overexposure pixel after clip by scaled down mode, restores the color of its script.
Further, the method after camera lens shadow correction, is needing to carry out white balance correction, not homochromy to compensate
Influence of the temperature to object color colour cast.It is also required to when white balance correction to R, G, B is respectively multiplied by a gain.Also, passing through
After the gain compensation of white balance correction, it can also make pixel value that can exceed that maximum magnitude causes the pixel overexposure occur, into
And by clip, lose information.Therefore, the present embodiment the method can also be by utilizing equal proportion to contract after white balance correction
Small mode carries out color correction to the overexposure pixel after clip, restores the color of its script.
Therefore, the present embodiment the method can also to any need multiplied by the module of gain, avoid its multiplied by gain after
Make pixel value be more than the maximum magnitude that is accommodated of ISP processor there is overexposure pixel and by clip, so as to cause information
Loss and color colour cast can carry out color correction to overexposure pixel by the color correction of tone mapping mapping mode.
On the other hand, the present embodiment the method due to the improper caused overexposure pixel of exposure parameter setting for being carried out
Retain line position tagging of going forward side by side, then by utilizing overexposure degree RoeWith adjacent through scaled down treated the second pixel value
RcbBy transitions smooth between processed pixel and untreated pixel, the calibration result in image color cast region is improved.
Therefore, the method for the invention can carry out respectively face to overexposure pixel according to the overexposure type of overexposure pixel
Color correction process not only simplifies image color cast correcting algorithm, reduces hardware resource consumption rate;Figure can also be further increased
As the calibration result in colour cast region.
The embodiment of the present invention also provides a kind of means for correcting of image color cast, as shown in figure 5, described device includes:
First acquisition unit 11, for obtaining the overexposure pixel of input picture;
Judging unit 12, for judging the overexposure type of the overexposure pixel;
Control unit 13, for according to the selection of the overexposure type of the overexposure pixel to the pixel value of overexposure pixel into
It row tone mapping conversion process or the overexposure pixel retain goes forward side by side line position tagging.
The means for correcting of image color cast provided in an embodiment of the present invention mainly passes through analysis image overexposure reason, wherein
The judging unit 12 of the present embodiment described device can be to the original of tri- channels of channel a certain in input picture overexposure or RGB all overexposures
Because being analyzed, judge the overexposure type of the overexposure pixel, for example, due to exposure sensor parameter setting is improper,
Or ISP processing module limitation itself leads to pixel overexposure (such as after camera lens shadow correction or white balance correction resume module).
The control unit 13 of the present embodiment described device separately handles the overexposure pixel overexposure of different overexposure types, and adaptive
The color and details of the tone mapping conversion process answered also original image script realize the correction of color of image colour cast.The present embodiment
Described device calculates simply, and hardware resource occupancy is small, is especially advantageous for hardware realization;And it can also be led to because of some channel overexposure
There is preferable calibration result in the colour cast region of cause.
Optionally, as shown in fig. 6, described control unit 13 includes:
Processing module 131, when for leading to overexposure after the overexposure pixel is handled by gain compensation, then to overexposure
The pixel value of pixel carries out tone mapping conversion process;
Reservation module 132, for when the overexposure pixel is to lead to overexposure by sensor automatic exposure, then to described
Overexposure pixel carries out retaining line position tagging of going forward side by side.
Optionally, the processing module 131 includes:
Threshold value determines submodule 1311, for the overexposure region information threshold value v according to input picturemax;
Submodule 1312 is handled, for by the first pixel value R of overexposure pixel1It is reflected according to the tone that following formula indicates
Penetrate curve carry out mapping obtain the second pixel value R2;
Wherein, A be the first parameter preset and, th2 corresponding with the data area of sensor be the second parameter preset,
Sigma is third parameter preset and is calculated by f (th2)=th2.
Optionally, described device further include:
Second acquisition unit 14, for obtaining whole pixels of input picture;
First computing unit 15, for obtaining the corresponding overexposure degree of each pixel according to the calculated for pixel values of each pixel
Value Roe;
Second computing unit 16 is used for the second pixel value R2, pixel overexposure degree RoeWith the of pixel
One pixel value R1Final pixel value R is calculated according to following formulaout;
Wherein, a is the 4th parameter preset and a > 0;
Output unit 17, for according to final pixel value RoutExport image.
The device of the present embodiment can be used for executing the technical solution of above method embodiment, realization principle and technology
Effect is similar, and details are not described herein again.
The embodiment of the present invention also provides a kind of electronic equipment, and the user equipment includes the correction dress of above-mentioned image color cast
It sets.
Those of ordinary skill in the art will appreciate that realizing all or part of the process in above-described embodiment method, being can be with
Relevant hardware is instructed to complete by computer program, the program can be stored in a computer-readable storage medium
In, the program is when being executed, it may include such as the process of the embodiment of above-mentioned each method.Wherein, the storage medium can be magnetic
Dish, CD, read-only memory (Read-Only Memory, ROM) or random access memory (Random Access
Memory, RAM) etc..
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any
In the technical scope disclosed by the present invention, any changes or substitutions that can be easily thought of by those familiar with the art, all answers
It is included within the scope of the present invention.Therefore, protection scope of the present invention should be subject to the protection scope in claims.
Claims (11)
1. a kind of bearing calibration of image color cast characterized by comprising
Obtain the overexposure pixel of input picture;
Judge the overexposure type of the overexposure pixel;
According to the selection of the overexposure type of the overexposure pixel to the pixel value of overexposure pixel carry out tone mapping conversion process,
Or the overexposure pixel is carried out to retain line position tagging of going forward side by side.
2. the method according to claim 1, wherein described select according to the overexposure type of the overexposure pixel
Tone mapping conversion process is carried out to the pixel value of overexposure pixel or the overexposure pixel is carried out to retain line position of going forward side by side
Tagging includes:
When leading to overexposure after the overexposure pixel is handled by gain compensation, then color is carried out to the pixel value of overexposure pixel
Adjust mapping transformation processing;
When the overexposure pixel is to lead to overexposure by sensor automatic exposure, then the overexposure pixel is retained simultaneously
Carry out position mark.
3. according to the method described in claim 2, it is characterized in that, described when the overexposure pixel is handled by gain compensation
After when leading to overexposure, then carrying out tone mapping conversion process to the pixel value of overexposure pixel includes:
According to the overexposure region information threshold value v of input picturemax;
By the first pixel value R of overexposure pixel1Mapping, which is carried out, according to the tone mapping curve that following formula indicates obtains the second picture
Plain value R2;
Wherein, A is the first parameter preset and, th2 corresponding with the data area of sensor is the second parameter preset, sigma is
Third parameter preset is simultaneously calculated by f (th2)=th2.
4. method according to claim 1 to 3, which is characterized in that in the overexposure pixel for obtaining input picture
Before, the method also includes:
Obtain whole pixels of input picture;
The corresponding overexposure degree value of each pixel is obtained according to the calculated for pixel values of each pixel.
5. according to the method described in claim 4, it is characterized in that, the calculated for pixel values according to each pixel obtains each picture
The corresponding overexposure degree value of vegetarian refreshments includes:
Each pixel is carried out each channel pixel value of the corresponding RGB of each pixel of interpolation calculation acquisition and compared respectively to obtain channel
Maximum value pcmax;
By the channel maximum value pcmaxIt is calculated as follows and obtains overexposure degree value ROE;
Wherein, a is the 4th parameter preset and a > 0, lth1For the 5th parameter preset, hth1For the 6th parameter preset, and lth1<
hth1。
6. according to the method described in claim 5, it is characterized in that, being selected described according to the overexposure type of the overexposure pixel
It selects and tone mapping conversion process is carried out to the pixel value of overexposure pixel or the overexposure pixel is retained and carried out
After position mark, the method also includes:
By the second pixel value R2, pixel overexposure degree RoeWith the first pixel value R of pixel1According to following formula meter
Calculation obtains final pixel value Rout;
According to final pixel value RoutExport image.
7. a kind of means for correcting of image color cast characterized by comprising
First acquisition unit, for obtaining the overexposure pixel of input picture;
Judging unit, for judging the overexposure type of the overexposure pixel;
Control unit, for carrying out tone according to pixel value of the overexposure type of the overexposure pixel selection to overexposure pixel
Mapping transformation handles or carries out retaining line position tagging of going forward side by side to the overexposure pixel.
8. device according to claim 7, which is characterized in that described control unit includes:
Processing module, when for leading to overexposure after the overexposure pixel is handled by gain compensation, then to overexposure pixel
Pixel value carry out tone mapping conversion process;
Reservation module, for when the overexposure pixel is to lead to overexposure by sensor automatic exposure, then to the overexposure picture
Vegetarian refreshments carries out retaining line position tagging of going forward side by side.
9. device according to claim 8, which is characterized in that the processing module includes:
Threshold value determines submodule, for the overexposure region information threshold value v according to input picturemax;
Submodule is handled, for by the first pixel value R of overexposure pixel1According to following formula indicate tone mapping curve into
Row mapping obtains the second pixel value R2;
Wherein, A is the first parameter preset and, th2 corresponding with the data area of sensor is the second parameter preset, sigma is
Third parameter preset is simultaneously calculated by f (th2)=th2.
10. according to any device of claim 7-9, which is characterized in that described device further include:
Second acquisition unit, for obtaining whole pixels of input picture;
First computing unit, for obtaining the corresponding overexposure degree value R of each pixel according to the calculated for pixel values of each pixeloe;
Second computing unit is used for the second pixel value R2, pixel overexposure degree RoeWith the first pixel of pixel
Value R1Final pixel value R is calculated according to following formulaout;
Wherein, a is the 4th parameter preset and a > 0;
Output unit, for according to final pixel value RoutExport image.
11. a kind of electronic equipment, which is characterized in that the electronic equipment includes as described in any one of claim 7 to 10
The means for correcting of image color cast.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810252674.9A CN110365949B (en) | 2018-03-26 | 2018-03-26 | Image color cast correction method and device and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810252674.9A CN110365949B (en) | 2018-03-26 | 2018-03-26 | Image color cast correction method and device and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110365949A true CN110365949A (en) | 2019-10-22 |
CN110365949B CN110365949B (en) | 2022-07-26 |
Family
ID=68212150
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810252674.9A Active CN110365949B (en) | 2018-03-26 | 2018-03-26 | Image color cast correction method and device and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110365949B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113132562A (en) * | 2021-04-21 | 2021-07-16 | 维沃移动通信有限公司 | Lens shadow correction method and device and electronic equipment |
CN113472997A (en) * | 2020-03-31 | 2021-10-01 | 北京小米移动软件有限公司 | Image processing method and device, mobile terminal and storage medium |
CN114078168A (en) * | 2020-08-19 | 2022-02-22 | Oppo广东移动通信有限公司 | Image processing model training method, image processing method and electronic device |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20060017855A1 (en) * | 2004-07-21 | 2006-01-26 | Sony Corporation | User interface providing device |
CN110232659A (en) * | 2018-03-06 | 2019-09-13 | 展讯通信(天津)有限公司 | A kind of bearing calibration of image color cast, device and electronic equipment |
-
2018
- 2018-03-26 CN CN201810252674.9A patent/CN110365949B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20060017855A1 (en) * | 2004-07-21 | 2006-01-26 | Sony Corporation | User interface providing device |
CN110232659A (en) * | 2018-03-06 | 2019-09-13 | 展讯通信(天津)有限公司 | A kind of bearing calibration of image color cast, device and electronic equipment |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113472997A (en) * | 2020-03-31 | 2021-10-01 | 北京小米移动软件有限公司 | Image processing method and device, mobile terminal and storage medium |
EP3889883A1 (en) * | 2020-03-31 | 2021-10-06 | Beijing Xiaomi Mobile Software Co., Ltd. | Image processing method and device, mobile terminal, and storage medium |
US11521305B2 (en) | 2020-03-31 | 2022-12-06 | Beijing Xiaomi Mobile Software Co., Ltd. | Image processing method and device, mobile terminal, and storage medium |
CN114078168A (en) * | 2020-08-19 | 2022-02-22 | Oppo广东移动通信有限公司 | Image processing model training method, image processing method and electronic device |
CN114078168B (en) * | 2020-08-19 | 2025-03-14 | Oppo广东移动通信有限公司 | Image processing model training method, image processing method and electronic device |
CN113132562A (en) * | 2021-04-21 | 2021-07-16 | 维沃移动通信有限公司 | Lens shadow correction method and device and electronic equipment |
CN113132562B (en) * | 2021-04-21 | 2023-09-29 | 维沃移动通信有限公司 | Lens shading correction method and device and electronic equipment |
Also Published As
Publication number | Publication date |
---|---|
CN110365949B (en) | 2022-07-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7949185B2 (en) | Method of performing robust auto white balance | |
CN101916431B (en) | Low-illumination image data processing method and system | |
US7227990B2 (en) | Color image processing device and color image processing method | |
KR100621414B1 (en) | Chroma Adaptive Image Enhancer and Method | |
CN109447912B (en) | Fluorescent image self-adaptive enhancement and noise reduction method of fluorescent navigation endoscope system | |
US7421120B2 (en) | Apparatus correcting image by luminance histogram | |
TWI497320B (en) | Automatic tone mapping method and image processing device | |
US8526736B2 (en) | Image processing apparatus for correcting luminance and method thereof | |
US8120670B2 (en) | Apparatus and method for controlling gain of color signal | |
CN111028181B (en) | Image enhancement processing method, device, equipment and storage medium | |
CN110232659A (en) | A kind of bearing calibration of image color cast, device and electronic equipment | |
CN110365949A (en) | A kind of bearing calibration of image color cast, device and electronic equipment | |
CN113824945B (en) | Rapid automatic white balance and color correction method based on deep learning | |
CN112819721A (en) | Method and system for reducing noise of image color noise | |
CN109544467B (en) | Method for enhancing contrast of color image based on LAB model | |
CN113658043A (en) | Image processing method, image processing device, electronic equipment and readable storage medium | |
US8295596B1 (en) | Adaptive histogram-based video contrast enhancement | |
CN113850738B (en) | Correction device and method for purple fringing of image | |
US20100033495A1 (en) | Image processing apparatus and image processing method | |
KR20240163757A (en) | Image processing method | |
CN114187204B (en) | Image processing method and device, equipment and storage medium for black edge optimization | |
CN117635485A (en) | Method, device, equipment and medium for removing purple fringing of image | |
KR101131109B1 (en) | Auto white balance setting method by white detection considering sensor characteristic | |
US11651495B2 (en) | Method and system for image correction | |
CN115330621A (en) | Image processing method, apparatus, device, storage medium, and program product |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |