CN103973997B - A kind of image processing method and device - Google Patents
A kind of image processing method and device Download PDFInfo
- Publication number
- CN103973997B CN103973997B CN201310045565.7A CN201310045565A CN103973997B CN 103973997 B CN103973997 B CN 103973997B CN 201310045565 A CN201310045565 A CN 201310045565A CN 103973997 B CN103973997 B CN 103973997B
- Authority
- CN
- China
- Prior art keywords
- block
- pixels
- pixel
- designated
- condition
- 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.)
- Active
Links
Landscapes
- Color Television Image Signal Generators (AREA)
- Image Processing (AREA)
Abstract
The embodiments of the invention provide a kind of image processing method and device, this method includes:The current image frame of input is divided into multiple block of pixels;For each block of pixels after division, according to the order and preparatory condition of setting, judge whether the block of pixels is located in current image frame on the false color edge of moving object successively, and whether be located at annular section;If judging, the block of pixels is located on false color edge, and it is not in annular section, then according to the block of pixels is neighbouring and the Pixel Information of block of pixels that has judged, the color component of pixel where false color in the block of pixels is repaired, continue to judge next block of pixels after to be repaired, until all block of pixels judges to terminate, the picture frame after being repaired.The embodiment of the present invention is handled the wide dynamic images frame including moving object by preparatory condition, using the false color phenomenon repaired in algorithm suppression picture frame on moving object edge, and this processing mode is simple and easy to apply, and difficulty is smaller.
Description
Technical field
The present invention relates to image processing field, more particularly to a kind of image processing method and device.
Background technology
Requirement with people to video camera is improved constantly, and wide dynamic technique has become indispensable in video monitoring
One of technology.The either DV of daily use, or the monitoring device that safety-security area is applied, wide dynamic technique is all
Especially paid close attention to.
So-called wide dynamic technique is a kind of characteristic for allowing video camera to see more images under contrast strongly and
The technology of utilization.Specifically, when in intense light source(Daylight, light fixture or reflective etc.)High-brightness region and shade, backlight under irradiation
Deng the relatively low region of relative luminance in the picture simultaneously in the presence of, the output image of video camera occurs bright areas because exposed
White is presented in degree, and dark area is presented black because of under-exposure, can thus have a strong impact on picture quality, so, video camera exists
The scope brightest area and most dark areas that can see clearly in Same Scene simultaneously between is known as dynamic range.
In order to improve the dynamic range of video camera, current common practice is to carry out multiexposure, multiple exposure to Same Scene, such as
One vice-minister exposure, short exposure, an once ultrashort exposure, so, long exposure can see dark place details clearly, and short exposure can be with
Limpid place's details is seen, ultrashort exposure can see super bright place's details clearly, then synthesize the image of three exposures, form frame tool
There is the image of HDR.The method of foregoing this multiexposure, multiple exposure fusion can improve the dynamic range of video camera really, but
It is, if there is moving object in scene, can occur green or purple (normally referred to as false color) on the edge of moving object, this
It is due to that moving object position in multiexposure, multiple exposure produced by each exposure is different, in synthesis, tri- kinds of Color Channels of R, G, B are each
Different targets are derived from, so as to produce false color phenomenon.
For there is a situation where to occur false color phenomenon on the edge of moving object in wide dynamic images, some suppressions are had at present
There is the end time pair of the processing method of false color, such as motion compensation method, multiexposure, multiple exposure in the edge of imaged middle moving object
Neat method etc..
Above-mentioned motion compensation method, the content in two picture frames is mainly matched, then estimate image each other
The position of moving object in frame, so that rgb value during composograph is taken from same target image frame, so as to weaken image
There is false color phenomenon in the edge of moving object in frame.
The end time alignment method of above-mentioned multiexposure, multiple exposure, is mainly to try to ensure that being exposed on synchronization each time terminates, from
And make it that the position of moving object in picture frame is tried one's best unanimously, to weaken the edge of moving object in picture frame, false color occur existing
As.
It can be seen that from above two image procossing mode and use motion compensation method, it mainly passes through between picture frame
The mode being mutually matched determines the position of moving object in picture frame, to avoid the edge of moving object in picture frame from going out as far as possible
Existing green or purple, but be sometimes easy to the stroboscopic phenomenon of exposure to be handled as moving object, so allow for
When suppressing false color phenomenon on the edge of moving object, difficulty is larger;The processing mode alignd using the end time of multiexposure, multiple exposure,
Although can ensure that being exposed on synchronization each time terminates as far as possible, the initial time that exposes for each time also phase still can not be ensured
Together, inconsistent situation still occurs in the position that so may result in moving object in picture frame, it is seen then that use this processing side
The formula difficulty that operates is larger.
The content of the invention
The embodiments of the invention provide a kind of image processing method and device, moved to solve to suppress in conventional images frame
The problem of false color phenomenon difficulty is big on object edge.
Based on above mentioned problem, a kind of image processing method provided in an embodiment of the present invention, including:
The current image frame of input is divided into multiple block of pixels, the current image frame is the bag after multiexposure, multiple exposure is merged
Include the wide dynamic images frame of moving object;
For each block of pixels after division, according to the order and preparatory condition of setting, the block of pixels is judged successively whether
On the false color edge of moving object in the current image frame, and whether it is located at annular section, the annular section is
First trip, footline after division, first and terminal column block of pixels area defined;
If judging, the block of pixels is located in the current image frame on the false color edge of moving object, and is not in ring-type
Region, then according to the block of pixels is neighbouring and the Pixel Information of block of pixels that has judged, to pixel where false color in the block of pixels
The color component of point is repaired, and rear continuation to be repaired judges next block of pixels, until all block of pixels judge to terminate, obtains
Picture frame after to reparation.
A kind of image processing apparatus provided in an embodiment of the present invention, including:
Division module, for the current image frame of input to be divided into multiple block of pixels, the current image frame is multiple
The wide dynamic images frame including moving object after exposure fusion;
Judge module, for for each block of pixels after division, according to the order and preparatory condition of setting, judging successively
Whether the block of pixels is located in the current image frame on the false color edge of moving object, and whether is located at annular section, institute
Annular section is stated for the first trip after dividing, footline, first and terminal column block of pixels area defined;
Repair module, for judging the block of pixels positioned at moving object in the current image frame in judge module
On false color edge, and be not in annular section, according to the block of pixels is neighbouring and the Pixel Information of block of pixels that has judged, to this
The color component of pixel is repaired where false color in block of pixels, and rear continuation to be repaired judges next block of pixels, Zhi Daosuo
Some block of pixels judge to terminate, the picture frame after being repaired.
The beneficial effect of the embodiment of the present invention includes:Image processing method and device provided in an embodiment of the present invention, at this
In method, the current image frame of input is first divided into multiple block of pixels, herein, current image frame refers to that multiexposure, multiple exposure melts
The wide dynamic images frame including moving object after conjunction;Then, can be according to the suitable of setting for each block of pixels after division
Sequence and preparatory condition, judge whether the block of pixels is located in current image frame and (are moved on the false color edge of moving object successively
There is green or purple edge in object), and whether positioned at annular section, (block of pixels in this usual region will not be located at motion
On the false color edge of object);Judging to be located at false color edge and in the case of being not in annular section, can according to and the pixel
Block is neighbouring and the Pixel Information of block of pixels that has judged, and the color component of pixel where false color in the block of pixels is repaired
Operation, it is to be repaired after may proceed to judge next block of pixels, until all block of pixels judges to terminate, finally give after reparation
Picture frame (picture frame after reparation preferably inhibits moving object the phenomenon of false color occur).In embodiments of the present invention, lead to
Cross and picture frame is divided into multiple block of pixels, judgement processing is carried out to these block of pixels according to preparatory condition successively, so as to relatively hold
Change places the block of pixels searched out on the false color edge of moving object, then it is entered using the Pixel Information of neighborhood pixels block
Row repairs operation, to play a part of suppressing at the false color phenomenon in picture frame on the edge of moving object, foregoing this scheme
Reason gets up relatively simple, that is, the difficulty operated is smaller.
Brief description of the drawings
Fig. 1 is the flow chart of image processing method provided in an embodiment of the present invention;
Fig. 2 is the schematic diagram of the block of pixels after division provided in an embodiment of the present invention;
Fig. 3 be pointed on the green of moving object in current image frame or purple edge to be provided in an embodiment of the present invention and
It is not located at one of reparation flow chart of block of pixels of annular section;
Fig. 4 be pointed on the green of moving object in current image frame or purple edge to be provided in an embodiment of the present invention and
It is not located at the two of the reparation flow chart of the block of pixels of annular section;
Fig. 5 is the structure chart of image processing apparatus provided in an embodiment of the present invention.
Embodiment
In wide dynamic technique, using the end time alignment method of existing motion compensation method and multiexposure, multiple exposure, to image
There is green side in the edge of moving object in frame or purple boundary (is referred to as " false color ") phenomenon and suppressed, although can play certain
Inhibition, but the difficulty that operates is larger.In view of the above-mentioned problems, the embodiment of the present invention provides a kind of processing side of image
Method and device, can be found in place by preparatory condition from each block of pixels in the wide dynamic images frame including moving object
Block of pixels on false color (i.e. green or purple) edge of the moving object in picture frame, then using reparation algorithm to these pictures
Plain block is repaired, so as to preferably inhibit moving object in picture frame the phenomenon at false color edge occur, is operated and is compared
Easily, i.e., difficulty is smaller.
With reference to Figure of description, to a kind of specific reality of image processing method and device provided in an embodiment of the present invention
The mode of applying is illustrated.
A kind of image processing method provided in an embodiment of the present invention, as shown in figure 1, specifically including following steps:
S101:The current image frame of input is divided into multiple block of pixels;
Herein, current image frame actually refers to include the wide dynamic images of moving object after multiexposure, multiple exposure fusion
Frame;
S102:For each block of pixels after division, according to the order and preparatory condition of setting, the block of pixels is judged successively
Whether it is located in current image frame on the false color edge of moving object;If so, step S103 is performed, if it is not, performing step S104;
S103:Judge whether the block of pixels is located at annular section;If so, step S104 is performed, if it is not, performing step
S105;
Herein, annular section refers to the first trip after dividing, footline, first and terminal column block of pixels area defined,
Block of pixels in this usual region will not be located in current image frame on the false color edge of moving object, based on this, for this area
Block of pixels in domain, even if on the false color edge of moving object, can also ignore, not repaired to it;
S104:The block of pixels is not repaired;
S105:According to the block of pixels is neighbouring and the Pixel Information of block of pixels that has judged, to false color institute in the block of pixels
Repaired in the color component of pixel, rear continuation to be repaired judges next block of pixels, step S102 is performed, until all
Block of pixels judge terminate, the picture frame after being repaired.
In embodiments of the present invention, when successively judging each block of pixels after division, it is not limited in above-mentioned sentencing
The journey that stops (step S102-S104), can also first judge whether the block of pixels is located at annular section, then according still further to the suitable of setting
Sequence and preparatory condition, judge whether the block of pixels is located at and state on the false color edge of moving object in current image frame.
In above-mentioned steps S101, when current image frame is divided into the operation of multiple block of pixels by execution, it can use
A variety of dividing modes, for example, can be divided according to the least unit of block of pixels, i.e., it is big current image frame to be divided into 2 × 2
Small block of pixels (as shown in Figure 2), naturally it is also possible to be divided into the block of pixels of 4 × 4 sizes, 8 × 8 sizes can also be divided into
Block of pixels etc..
It should be noted that the pixel dot characteristics based on wide dynamic images frame, the i.e. block of pixels for least unit come
(such as the block of pixels A in Fig. 2) is said, the pixel that it is generally respectively Gr, rr, bb and Gb by mark constitutes (as shown in Figure 2),
Like this, the block of pixels after division is bigger, and the pixel that it includes is more, and this adds increased the meter in follow-up processing flow
Calculate difficulty.Thus, the embodiment of the present invention is preferred to use enters in the way of the least unit of block of pixels is divided to current image frame
Row is divided, i.e., current image frame is divided into the block of pixels of 2 × 2 sizes.
Alternatively, in above-mentioned steps S102, due to needing to be pointed to moving object in current image frame in follow-up process
Block of pixels on the false color edge of body carries out reparation operation, and need to refer to when performing and repairing operation with block of pixels it is neighbouring and
It is determined that the Pixel Information of block of pixels later, could be repaired to it, thus, in this step 102, to many after division
Individual block of pixels (each block of pixels is the block of pixels of 2 × 2 sizes), it usually needs serial number first is carried out to it, so subsequently pressed
Order according to numbering is judged successively, for example, (as shown in table 1 below) is numbered successively according to Arabic numerals.Certainly, it is preceding
Stating the mode of numbering can have a variety of, no longer enumerate one by one herein.
Table 1
1 | 2 | 3 | 4 | 5 | 6 |
7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 |
Further, in above-mentioned steps 102, preparatory condition can be accomplished in the following manner:
For each block of pixels after division, judge whether the block of pixels meets any bar in following condition A~condition F
Part:
Condition A:Grr>First threshold, rr<First threshold and rr × fTr1<Grr;
Condition B:rr>=first threshold and rr × fTr2<Grr;
Condition C:Gbb>First threshold, bb<First threshold and bb × fTb1<Gbb;
Condition D:bb>=first threshold and bb × fTb2<Gbb;
Condition E:rr>Second Threshold and rr × fTr3>Grr;
Condition F:bb>Second Threshold and bb × fTb3>Gbb;
Wherein, Grr be the block of pixels in be designated rr pixel green channel value;
Rr be the block of pixels in be designated rr pixel red color channel value;
Gbb be the block of pixels in be designated bb pixel green channel value;
Bb be the block of pixels in be designated bb pixel blue channel value;
FTr1, fTr2, fTb1, fTb2, fTr3 and fTb3 are adjustable parameters;
In the case of either condition in meeting above-mentioned condition, just the block of pixels is defined as being located in current image frame and transported
Block of pixels on the false color edge of animal body.
Specifically, in the case where meeting any of above-mentioned condition A~condition D condition, the block of pixels can be determined
For the block of pixels in current image frame on the green edge of moving object;
In the case where meeting any of condition E~condition F condition, the block of pixels is defined as to be located at current image frame
Block of pixels on the purple edge of middle moving object.
In embodiments of the present invention, above-mentioned first threshold and Second Threshold can be taken according to actual measurement data
Value, and these actual test data are by being designated rr's in false color fringe region on existing wide dynamic images frame
The green channel value and red color channel value of pixel, and be designated the green channel value and blue channel value of bb pixel and enter
Row repeatedly measures what is obtained.That is, above-mentioned first threshold and the value of Second Threshold can be with identical, can also be different.Example
First threshold in such as above-mentioned condition can be 4096, and Second Threshold can be 2048;Certain first threshold and Second Threshold
It can be other numerical value, no longer enumerate one by one herein.
Inserted in addition, above-mentioned Grr can carry out bilinearity to the green channel value for the pixel that Gr is designated in the block of pixels
Value computing is obtained;Gbb can carry out bilinear interpolation computing to the green channel value for the pixel that Gb is designated in the block of pixels
Obtain.In embodiments of the present invention, above-mentioned fTr1, fTb1, fTr2, fTb2fTr3 and fTb3 can be measured by experiment, example
If fTr1 and fTb1 can be that 2.5, fTr2 and fTb2 can be that 3, fTr3 and fTb3 can be 1.1.Herein, bilinear interpolation
Computing is prior art, be will not be repeated here.
Alternatively, in above-mentioned steps S105, it is assumed that each block of pixels after division is carried out in the way of above-mentioned table 1
Numbering, then, the block of pixels can be repaired by following two ways:
1st kind of mode:If the block of pixels meets either condition in condition A, condition B and condition E, according to the block of pixels
The red gain value of rr pixel is designated in upper left side, top, the block of pixels of upper right side and left, the block of pixels is got the bid
The red component for knowing the pixel for rr is repaired;
2nd kind of mode:If the block of pixels meets either condition in condition C, condition D and condition F, according to the block of pixels
The blue gain value of bb pixel is designated in upper left side, top, the block of pixels of upper right side and left, the block of pixels is got the bid
Know and repaired for bb pixel.
Specifically, in above-mentioned 1st kind of mode, as shown in figure 3, repairing for the block of pixels can be completed by following flows
It is multiple:
S301:According to saturation arithmetic function clip (a, b), calculate respectively the upper left side of the block of pixels, top, upper right side and
The red gain value of rr pixel is designated in the block of pixels of left;
Herein, a be with the block of pixels is neighbouring and the block of pixels that has judged in be designated rr pixel red channel
Value and the ratio of green channel value, b are the red color channel value and green channel value for the pixel that rr is designated in the block of pixels
Ratio;
S302:Computing of averaging is carried out to the red gain value calculated, and red gain value will be obtained replacing the picture
The current red gain value of rr pixel is designated in plain block;
S303:By the red gain value after replacement, the green channel value progress quadrature fortune with being designated rr in the block of pixels
Calculate, retrieve the red component for the pixel that rr is designated in the block of pixels, complete to repair.
In fact, being first, according to saturation arithmetic function, such as block of pixels to be calculated respectively left in embodiments of the present invention
The red gain value that rr pixel is designated in the block of pixels of top is r_gain1:
r_gain1=clip(rr1/Grr1,rr/Grr);
The red gain value for calculating the pixel that rr is designated in the block of pixels above the block of pixels is r_gain2:
r_gain2=clip(rr2/Grr2,rr/Grr);
The red gain value that rr pixel is designated in the block of pixels for calculating the block of pixels upper right side is r_gain3:
r_gain3=clip(rr3/Grr3,rr/Grr);
The red gain value that rr pixel is designated in the block of pixels for calculating the block of pixels left is r_gain4:
r_gain4=clip(rr4/Grr4,rr/Grr);
Wherein, rr1 refer to being designated in the upper left block of pixels of the block of pixels red color channel value of rr pixel with
The ratio of green channel value, Grr1 refers to being designated the red channel of rr pixel in the upper left block of pixels of the block of pixels
The ratio of value and green channel value, rr refers to being designated the red color channel value and green channel of rr pixel in the block of pixels
The ratio of value, Grr refers to being designated ratio of the red color channel value with green channel value of rr pixel in the block of pixels;
Rr2 refers to being designated the red color channel value and green channel of rr pixel in the block of pixels above the block of pixels
The ratio of value, Grr2 refers to that the red color channel value that rr pixel is designated in the block of pixels above the block of pixels is led to green
The ratio of road value;
Rr3 refers to that the red color channel value that rr pixel is designated in the block of pixels in the block of pixels upper right side is led to green
The ratio of road value, Grr3 refer to being designated in the block of pixels in the block of pixels upper right side red color channel values of rr pixels with it is green
The ratio of chrominance channel value;Rr4 refer to being designated in the block of pixels of the block of pixels left red color channel value of rr pixel with
The ratio of green channel value, Grr4 refers to being designated the red color channel value of rr pixel in the block of pixels of the block of pixels left
With the ratio of green channel value.
Then, following formula are recycled to recalculate the red component rr ' for the pixel for being designated rr in the block of pixels
(completing to repair):
rr’=Grr*(r_gain1+r_gain2+r_gain3+r_gain4)/4。
Specifically, in above-mentioned 2nd kind of mode, as shown in figure 4, can specifically complete to repair by following flows:
S401:According to saturation arithmetic function clip (a, b), calculate respectively the upper left side of the block of pixels, top, upper right side and
The blue gain value of bb pixel is designated in the block of pixels of left;
Herein, a be with the block of pixels is neighbouring and the block of pixels that has judged in be designated bb pixel blue channel
Value and the ratio of green channel value, b are the blue channel value and green channel value for the pixel that bb is designated in the block of pixels
Ratio;
S402:Computing of averaging is carried out to the blue gain value calculated, and blue gain value will be obtained replacing the picture
The current blue gain value of bb pixel is designated in plain block;
S403:By the blue gain value after replacement, the green channel value progress quadrature fortune with being designated bb in the block of pixels
Calculate, retrieve the blue component for the pixel that bb is designated in the block of pixels, complete to repair.
In embodiments of the present invention, the block of pixels still to 2 × 2 sizes after division in the way of above-mentioned table 1 is numbered,
And assume to be currently located at the false color edge of moving object in current image frame and be not in the numbering of block of pixels of annular section and be
9, then when the red component for the pixel for being designated rr in using above-mentioned 1st kind of mode to the block of pixels is repaired, ginseng
Examine be numbering be 2 (upper left sides of numbering 9), numbering be 3 (tops of numbering 9), number be 4 (upper right side of numbering 9) and compile
Number to be designated rr red gain value in the block of pixels of 8 (lefts of numbering 9), these numberings is 2, numbering be 3, to number be 4
The block of pixels for being 8 with numbering is the block of pixels judged, reparation success rate can be improved using this processing mode, so that more
There is false color phenomenon in the edge for suppressing moving object in picture frame well.
Based on same inventive concept, the embodiment of the present invention additionally provides a kind of image processing apparatus, by the device is solved
Certainly the principle of problem is similar to foregoing image processing method, therefore the implementation of the device may refer to the implementation of preceding method, weight
Multiple part is repeated no more.
The embodiment of the present invention provides a kind of image processing apparatus, as shown in figure 5, specifically including:
Division module 501, for the current image frame of input to be divided into multiple block of pixels;
Herein, current image frame is the wide dynamic images frame including moving object after multiexposure, multiple exposure is merged;
Judge module 502, for for each block of pixels after division, according to the order and preparatory condition of setting, successively
Judge whether the block of pixels is located in current image frame on the false color edge of moving object, and whether be located at annular section;
Herein, annular section is the first trip after dividing, footline, first and terminal column block of pixels area defined;
Repair module 503, for judging the block of pixels positioned at moving object in current image frame in judge module 502
False color edge on, and when being not in annular section, according to the block of pixels is neighbouring and the Pixel Information of block of pixels that has judged,
The color component of pixel where false color in the block of pixels is repaired, rear continuation to be repaired judges next block of pixels, directly
Judge to terminate to all block of pixels, the picture frame after being repaired.
It is preferred that above-mentioned division module 501, the pixel specifically for current image frame to be divided into multiple 2 × 2 sizes
Block.
It is preferred that above-mentioned judge module 502, each block of pixels after being additionally operable to for dividing, judge the picture after dividing
Whether plain block meets either condition in following condition A~condition F:
Condition A:Grr>First threshold, rr<First threshold and rr × fTr1<Grr;
Condition B:rr>=first threshold and rr × fTr2<Grr;
Condition C:Gbb>First threshold, bb<First threshold and bb × fTb1<Gbb;
Condition D:bb>=first threshold and bb × fTb2<Gbb;
Condition E:rr>Second Threshold and rr × fTr3>Grr;
Condition F:bb>Second Threshold and bb × fTb3>Gbb;
Wherein, Grr be the block of pixels in be designated rr pixel green channel value;
Rr be the block of pixels in be designated rr pixel red color channel value;
Gbb be the block of pixels in be designated bb pixel green channel value;
Bb be the block of pixels in be designated bb pixel blue channel value;
FTr1, fTr2, fTb1, fTb2, fTr3 and fTb3 are adjustable parameters;
In the case of either condition in meeting above-mentioned condition, the block of pixels is defined as being located in current image frame and moved
Block of pixels on the false color edge of object.
In embodiments of the present invention, fTr1 and fTTb1 can be that 2.5, fTr2 and fTb2 can be that 3, fTr3 and fTb3 can
Think 1.1.
It is preferred that above-mentioned repair module 503, if meeting any in condition A, condition B and condition E specifically for the block of pixels
Condition, then according to the red for the pixel that rr is designated in the block of pixels of the upper left side of the block of pixels, top, upper right side and left
Yield value, the red component of the pixel to being designated rr in the block of pixels is repaired;If the block of pixels meets condition C, bar
Either condition in part D and condition F, then be designated according in the block of pixels of the upper left side of the block of pixels, top, upper right side and left
The blue gain value of bb pixel, the blue component of the pixel to being designated bb in the block of pixels is repaired.
It is preferred that above-mentioned repair module 503, is specifically additionally operable to according to saturation arithmetic function clip (a, b), calculating respectively should
The red gain value of rr pixel, wherein a are designated in the upper left side of block of pixels, top, the block of pixels of upper right side and left
For with the block of pixels is neighbouring and the block of pixels that has judged in be designated rr pixel red color channel value and green channel value
Ratio, b is the ratio of red color channel value and the green channel value for the pixel that rr is designated in the block of pixels;It is red to what is calculated
Color yield value average computing, and will obtain red gain value and replace being designated rr pixel in the block of pixels and working as
Preceding red gain value;By the red gain value after replacement, the green channel value progress quadrature fortune with being designated rr in the block of pixels
Calculate, retrieve the red component for the pixel that rr is designated in the block of pixels, complete to repair.
It is preferred that above-mentioned repair module 503, is specifically additionally operable to according to saturation arithmetic function clip (a, b), calculating respectively should
The blue gain value of bb pixel is designated in the upper left side of block of pixels, top, the block of pixels of upper right side and left, wherein
A be with the block of pixels is neighbouring and the block of pixels that has judged in be designated bb pixel blue channel value and green channel value
Ratio, b is the ratio of blue channel value and the green channel value for the pixel that bb is designated in the block of pixels;To the indigo plant calculated
Color yield value average computing, and will obtain blue gain value and replace being designated bb pixel in the block of pixels and working as
Preceding blue gain value;By the blue gain value after replacement, the green channel value progress quadrature fortune with being designated bb in the block of pixels
Calculate, retrieve the blue component for the pixel that bb is designated in the block of pixels, complete to repair.
Image processing method and device provided in an embodiment of the present invention, in the method, first by the current image frame of input
Multiple block of pixels are divided into, herein, current image frame refers to including the width dynamic of moving object after multiexposure, multiple exposure fusion
Picture frame;Then for divide after each block of pixels, can according to setting order and preparatory condition, the pixel is judged successively
Whether block is located in current image frame (i.e. green or purple edge occurs in moving object) on the false color edge of moving object, and
Whether it is located at annular section (block of pixels in this usual region will not be located on the false color edge of moving object);Judging position
In false color edge and in the case of being not in annular section, can according to the block of pixels is neighbouring and the pixel of block of pixels that has judged
Information, carries out reparation operation to the color component of pixel where false color in the block of pixels, it is to be repaired after may proceed to judge next
Individual block of pixels, until all block of pixels judge to terminate, finally giving the picture frame after repairing, (picture frame after reparation is preferable
Moving object is inhibited the phenomenon of false color occur).In embodiments of the present invention, by the way that picture frame is divided into multiple block of pixels,
Judgement processing is carried out to these block of pixels according to preparatory condition successively, so as to relatively easily search out the false color positioned at moving object
Block of pixels on edge, then carries out reparation operation using the Pixel Information of neighborhood pixels block to it, to play suppression picture frame
The effect of false color phenomenon on the edge of middle moving object, foregoing this scheme deals with relatively simple, that is, operate difficulty
It is smaller.
Obviously, those skilled in the art can carry out the essence of various changes and modification without departing from the present invention to the present invention
God and scope.So, if these modifications and variations of the present invention belong to the scope of the claims in the present invention and its equivalent technologies
Within, then the present invention is also intended to comprising including these changes and modification.
Claims (12)
1. a kind of image processing method, it is characterised in that including:
The current image frame of input is divided into multiple block of pixels, the current image frame is to include fortune after multiexposure, multiple exposure is merged
The wide dynamic images frame of animal body;
For each block of pixels after division, according to the order and preparatory condition of setting, judge whether the block of pixels is located at successively
On the false color edge of moving object in the current image frame, and whether it is located at annular section, the annular section is division
Rear first trip, footline, first and terminal column block of pixels area defined;
If judging, the block of pixels is located in the current image frame on the false color edge of moving object, and is not in ring-shaped area
Domain, then according to the block of pixels is neighbouring and the Pixel Information of block of pixels that has judged, to pixel where false color in the block of pixels
Color component repaired, it is to be repaired after continue to judge next block of pixels, until all block of pixels judgements terminate, obtain
Picture frame after reparation;
Wherein, the false color edge is to occur green or purple on the edge of the moving object.
2. the method as described in claim 1, it is characterised in that the current image frame is divided into the picture of multiple 2 × 2 sizes
Plain block.
3. method as claimed in claim 2, it is characterised in that the preparatory condition is accomplished in the following manner:
For each block of pixels after division, judge whether the block of pixels meets either condition in following condition A~condition F:
Condition A:Grr>First threshold, Rrr<First threshold and Rrr × fTr1<Grr;
Condition B:Rrr>=first threshold and Rrr × fTr2<Grr;
Condition C:Gbb>First threshold, Bbb<First threshold and Bbb × fTb1<Gbb;
Condition D:Bbb>=first threshold and Bbb × fTb2<Gbb;
Condition E:Rrr>Second Threshold and Rrr × fTr3>Grr;
Condition F:Bbb>Second Threshold and Bbb × fTb3>Gbb;
Wherein, Grr be the block of pixels in be designated rr pixel green channel value;
Rrr be the block of pixels in be designated rr pixel red color channel value;
Gbb be the block of pixels in be designated bb pixel green channel value;
Bbb be the block of pixels in be designated bb pixel blue channel value;
FTr1, fTr2, fTb1, fTb2, fTr3 and fTb3 are adjustable parameters;
If meeting, the block of pixels is defined as to be located at the block of pixels in the current image frame on the false color edge of moving object.
4. method as claimed in claim 3, it is characterised in that according to the block of pixels is neighbouring and the picture of block of pixels that has judged
Prime information, repairs to the color component of pixel where false color in the block of pixels, specifically includes:
If the block of pixels meets either condition in the condition A, condition B and condition E, according to the upper left side of the block of pixels, on
The red gain value of rr pixel is designated in the block of pixels of side, upper right side and left, to being designated rr's in the block of pixels
The red component of pixel is repaired;
If the block of pixels meets either condition in the condition C, condition D and condition F, according to the upper left side of the block of pixels, on
The blue gain value of bb pixel is designated in the block of pixels of side, upper right side and left, to being designated bb's in the block of pixels
The blue component of pixel is repaired;
Wherein, according to the red of the pixel that rr is designated in the block of pixels of the upper left side of the block of pixels, top, upper right side and left
Color yield value, the red component of the pixel to being designated rr in the block of pixels is repaired, and is specifically included:
According to saturation arithmetic function clip (a, b), the picture of upper left side, top, upper right side and the left of the block of pixels is calculated respectively
The red gain value of rr pixel is designated in plain block, wherein a is the block of pixels that the described and block of pixels is neighbouring and has judged
In be designated rr pixel red color channel value and green channel value ratio, b is the pixel that rr is designated in the block of pixels
The red color channel value of point and the ratio of green channel value;
Computing of averaging is carried out to the red gain value calculated, and red gain value will be obtained replacing mark in the block of pixels
For the current red gain value of rr pixel;
By the red gain value after replacement, the green channel value progress quadrature computing with being designated rr in the block of pixels, again
The red component of rr pixel is designated into the block of pixels, completes to repair.
5. method as claimed in claim 4, it is characterised in that according to the upper left side of the block of pixels, top, upper right side and left
Block of pixels in be designated bb pixel blue gain value, the blue component of the pixel to being designated bb in the block of pixels
Repaired, specifically included:
According to saturation arithmetic function clip (a, b), the picture of upper left side, top, upper right side and the left of the block of pixels is calculated respectively
The blue gain value of bb pixel is designated in plain block, wherein a is the block of pixels that the described and block of pixels is neighbouring and has judged
In be designated bb pixel blue channel value and green channel value ratio, b is the pixel that bb is designated in the block of pixels
The blue channel value of point and the ratio of green channel value;
Computing of averaging is carried out to the blue gain value calculated, and blue gain value will be obtained replacing mark in the block of pixels
For the current blue gain value of bb pixel;
By the blue gain value after replacement, the green channel value progress quadrature computing with being designated bb in the block of pixels, again
The blue component of bb pixel is designated into the block of pixels, completes to repair.
6. the method as described in any one of claim 1-5 claim, it is characterised in that fTr1=fTb1=2.5, fTr2
=fTb2=3, fTr3=fTb3=1.1.
7. a kind of image processing apparatus, it is characterised in that including:
Division module, for the current image frame of input to be divided into multiple block of pixels, the current image frame is multiexposure, multiple exposure
The wide dynamic images frame including moving object after fusion;
Judge module, for for each block of pixels after division, according to the order and preparatory condition of setting, the picture to be judged successively
Whether plain block is located in the current image frame on the false color edge of moving object, and whether is located at annular section, the ring
Shape region is the first trip after dividing, footline, first and terminal column block of pixels area defined;
Repair module, for judging false color of the block of pixels positioned at moving object in the current image frame in judge module
On edge, and be not in annular section, according to the block of pixels is neighbouring and the Pixel Information of block of pixels that has judged, to the pixel
The color component of pixel is repaired where false color in block, and rear continuation to be repaired judges next block of pixels, until all
Block of pixels judges to terminate, the picture frame after being repaired;
Wherein, the false color edge is to occur green or purple on the edge of the moving object.
8. device as claimed in claim 7, it is characterised in that the division module, specifically for by the current image frame
It is divided into the block of pixels of multiple 2 × 2 sizes.
9. device as claimed in claim 8, it is characterised in that the judge module, each picture after being additionally operable to for dividing
Plain block, judges whether the block of pixels after dividing meets either condition in following condition A~condition F:
Condition A:Grr>First threshold, Rrr<First threshold and Rrr × fTr1<Grr;
Condition B:Rrr>=first threshold and Rrr × fTr2<Grr;
Condition C:Gbb>First threshold, Bbb<First threshold and Bbb × fTb1<Gbb;
Condition D:Bbb>=first threshold and Bbb × fTb2<Gbb;
Condition E:Rrr>Second Threshold and Rrr × fTr3>Grr;
Condition F:Bbb>Second Threshold and Bbb × fTb3>Gbb;
Wherein, Grr be the block of pixels in be designated rr pixel green channel value;
Rrr be the block of pixels in be designated rr pixel red color channel value;
Gbb be the block of pixels in be designated bb pixel green channel value;
Bbb be the block of pixels in be designated bb pixel blue channel value;
FTr1, fTr2, fTb1, fTb2, fTr3 and fTb3 are adjustable parameters;
If meeting, the block of pixels is defined as to be located at the block of pixels in the current image frame on the false color edge of moving object.
10. device as claimed in claim 9, it is characterised in that the repair module, if meeting institute specifically for the block of pixels
Either condition in condition A, condition B and condition E is stated, then according to the pixel of the upper left side of the block of pixels, top, upper right side and left
The red gain value of rr pixel is designated in block, the red component of the pixel to being designated rr in the block of pixels is repaiied
It is multiple;If the block of pixels meets either condition in the condition C, condition D and condition F, according to the upper left side of the block of pixels, on
The blue gain value of bb pixel is designated in the block of pixels of side, upper right side and left, to being designated bb's in the block of pixels
The blue component of pixel is repaired;
Wherein, the repair module, is specifically additionally operable to, according to saturation arithmetic function clip (a, b), the block of pixels be calculated respectively
Be designated the red gain value of rr pixel in upper left side, top, the block of pixels of upper right side and left, wherein a for it is described with
The block of pixels is neighbouring and the block of pixels that has judged in be designated rr pixel red color channel value and green channel value ratio,
B is the ratio of red color channel value and the green channel value for the pixel that rr is designated in the block of pixels;The red calculated is increased
Beneficial value progress is averaged computing, and by obtain red gain value replace be designated in the block of pixels rr pixel it is current red
Color yield value;By the red gain value after replacement, quadrature computing, weight are carried out with being designated rr green channel value in the block of pixels
Newly obtain being designated the red component of rr pixel in the block of pixels, complete to repair.
11. device as claimed in claim 10, it is characterised in that the repair module, is specifically additionally operable to according to saturation arithmetic
Bb is designated in function clip (a, b), the block of pixels of upper left side, top, upper right side and left that the block of pixels is calculated respectively
Pixel blue gain value, wherein a is is designated bb picture in block of pixels that is described neighbouring with the block of pixels and having judged
The blue channel value of vegetarian refreshments and the ratio of green channel value, b are the blue channel value for the pixel that bb is designated in the block of pixels
With the ratio of green channel value;Computing of averaging is carried out to the blue gain value calculated, and blue gain value will be obtained replacing
Change the current blue gain value for the pixel that bb is designated in the block of pixels;By the blue gain value after replacement, with the block of pixels
In be designated bb green channel value and carry out quadrature computing, retrieve the blueness point for the pixel that bb is designated in the block of pixels
Amount, completes to repair.
12. the device as described in any one of claim 7-11 claim, it is characterised in that fTr1=fTb1=2.5,
FTr2=fTb2=3, fTr3=fTb3=1.1.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310045565.7A CN103973997B (en) | 2013-02-05 | 2013-02-05 | A kind of image processing method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310045565.7A CN103973997B (en) | 2013-02-05 | 2013-02-05 | A kind of image processing method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103973997A CN103973997A (en) | 2014-08-06 |
CN103973997B true CN103973997B (en) | 2017-09-26 |
Family
ID=51242984
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310045565.7A Active CN103973997B (en) | 2013-02-05 | 2013-02-05 | A kind of image processing method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103973997B (en) |
Families Citing this family (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9819913B2 (en) * | 2015-08-26 | 2017-11-14 | Stmicroelectronics International N.V. | Image sensor device with macropixel processing and related devices and methods |
CN105389786B (en) * | 2015-10-28 | 2020-03-31 | 努比亚技术有限公司 | Image processing method and device |
CN105335979A (en) * | 2015-10-28 | 2016-02-17 | 努比亚技术有限公司 | Image processing method and apparatus |
CN106657946B (en) | 2017-01-12 | 2019-03-01 | 深圳岚锋创视网络科技有限公司 | System and method are eliminated in image purple boundary |
CN110679140B (en) * | 2017-06-08 | 2021-04-13 | 富士胶片株式会社 | Image pickup apparatus, control method of image pickup apparatus, and storage medium |
CN110418065B (en) * | 2018-04-27 | 2021-03-19 | 北京紫光展锐通信技术有限公司 | High dynamic range image motion compensation method and device and electronic equipment |
CN109636753B (en) * | 2018-12-11 | 2020-09-18 | 珠海奔图电子有限公司 | Image processing method and apparatus, electronic device, and computer-readable storage medium |
CN111815532B (en) * | 2020-07-09 | 2024-07-16 | 浙江大华技术股份有限公司 | Depth map restoration method and related device thereof |
CN113905183B (en) * | 2021-08-25 | 2024-04-16 | 珠海全志科技股份有限公司 | Color difference correction method and device for wide dynamic range image |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1855995A (en) * | 2005-04-21 | 2006-11-01 | 诺日士钢机株式会社 | Image processing method and program for restraining particle noises and particle noises restraining processing module |
JP2008227697A (en) * | 2007-03-09 | 2008-09-25 | Sony Corp | Image processing apparatus, imaging apparatus, image processing method, and computer program |
CN102025918A (en) * | 2009-09-18 | 2011-04-20 | 索尼公司 | Image processing device, imaging apparatus, imaging processing method, and program |
CN102348056A (en) * | 2010-07-23 | 2012-02-08 | 卡西欧计算机株式会社 | Image synthesizing device and image synthesizing method |
WO2012063885A1 (en) * | 2010-11-08 | 2012-05-18 | Canon Kabushiki Kaisha | Image processing apparatus and control method of the same |
CN102474628A (en) * | 2010-03-25 | 2012-05-23 | 富士胶片株式会社 | Image processing method and device, image processing program, and medium having said program recorded thereon |
CN102572245A (en) * | 2011-12-22 | 2012-07-11 | 深圳市赛格导航科技股份有限公司 | Method and device for extending image dynamic ranges |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP4770154B2 (en) * | 2004-11-08 | 2011-09-14 | ソニー株式会社 | Image processing apparatus, image processing method, and computer program |
-
2013
- 2013-02-05 CN CN201310045565.7A patent/CN103973997B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1855995A (en) * | 2005-04-21 | 2006-11-01 | 诺日士钢机株式会社 | Image processing method and program for restraining particle noises and particle noises restraining processing module |
JP2008227697A (en) * | 2007-03-09 | 2008-09-25 | Sony Corp | Image processing apparatus, imaging apparatus, image processing method, and computer program |
CN102025918A (en) * | 2009-09-18 | 2011-04-20 | 索尼公司 | Image processing device, imaging apparatus, imaging processing method, and program |
CN102474628A (en) * | 2010-03-25 | 2012-05-23 | 富士胶片株式会社 | Image processing method and device, image processing program, and medium having said program recorded thereon |
CN102348056A (en) * | 2010-07-23 | 2012-02-08 | 卡西欧计算机株式会社 | Image synthesizing device and image synthesizing method |
WO2012063885A1 (en) * | 2010-11-08 | 2012-05-18 | Canon Kabushiki Kaisha | Image processing apparatus and control method of the same |
CN102572245A (en) * | 2011-12-22 | 2012-07-11 | 深圳市赛格导航科技股份有限公司 | Method and device for extending image dynamic ranges |
Also Published As
Publication number | Publication date |
---|---|
CN103973997A (en) | 2014-08-06 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103973997B (en) | A kind of image processing method and device | |
CN104869377B (en) | A kind of method for correcting colors of projected image and projector | |
KR100916073B1 (en) | Histogram Stretching Device and Method for Improving Image Contrast | |
CN102075688B (en) | Wide dynamic processing method for single-frame double-exposure image | |
CN105069756B (en) | Image enchancing method | |
WO2010116922A1 (en) | Image input device | |
US10397524B1 (en) | Three-dimensional around view monitoring system of vehicle and method thereof | |
CN101571663B (en) | Distributed online regulating method for splicing multiple projectors | |
US7990431B2 (en) | Calculation method for the correction of white balance | |
RU2010107161A (en) | EXTENSION OF DYNAMIC IMAGE RANGE | |
JP2009055610A (en) | Method and apparatus for correcting chromatic aberration of video | |
CN100397477C (en) | Image processing device and method for improving brightness and image quality of display panel | |
CN107403408A (en) | A kind of double fish eye images spliced panoramic image seam fusion methods | |
CN107330872A (en) | Luminance proportion method and apparatus for vehicle-mounted viewing system | |
WO2012153604A1 (en) | Image processing apparatus, program therefor, and image processing method | |
CN104639920A (en) | Wide dynamic fusion method based on single-frame double-pulse exposure mode | |
CN107863060A (en) | A kind of method and device of image color correction | |
CN106570838A (en) | Image brightness optimization method and device | |
JP2008148316A (en) | Apparatus and method for improving sharpness of image | |
TW201335886A (en) | Bird view system and compensating method thereof | |
WO2024031950A1 (en) | Data processing method for high-resolution fluorescence three-dimensional imaging apparatus | |
CN104683780B (en) | The auto white balance method of a kind of video monitoring camera and device | |
CN103780887B (en) | A kind of video signal processing method and device | |
CN105719281B (en) | A Fast Detection and Correction Algorithm for Refractive Chromatic Aberration | |
CN101197911B (en) | Image edge strengthening method and device |
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 |