CN107392870A - Image processing method, device, mobile terminal and computer-readable recording medium - Google Patents

Image processing method, device, mobile terminal and computer-readable recording medium Download PDF

Info

Publication number
CN107392870A
CN107392870A CN201710625428.9A CN201710625428A CN107392870A CN 107392870 A CN107392870 A CN 107392870A CN 201710625428 A CN201710625428 A CN 201710625428A CN 107392870 A CN107392870 A CN 107392870A
Authority
CN
China
Prior art keywords
image
pending image
defogging
brightness value
rgb
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
Application number
CN201710625428.9A
Other languages
Chinese (zh)
Other versions
CN107392870B (en
Inventor
袁全
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201710625428.9A priority Critical patent/CN107392870B/en
Publication of CN107392870A publication Critical patent/CN107392870A/en
Application granted granted Critical
Publication of CN107392870B publication Critical patent/CN107392870B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/73Deblurring; Sharpening
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Processing (AREA)

Abstract

The present embodiments relate to a kind of image processing method, device, mobile terminal and computer-readable recording medium.The above method, including:Determine the exposure of the first pending image;When the exposure is more than predetermined threshold value, then the brightness value of the described first pending image is reduced, obtains the second pending image;The defogging parameter of the second pending image is calculated according to the brightness value after reduction;Defogging processing is carried out to the described first pending image according to the defogging parameter.Above-mentioned image processing method, device, mobile terminal and computer-readable recording medium, image that can be high to exposure carry out defogging, improve the defog effect of image.

Description

Image processing method, device, mobile terminal and computer-readable recording medium
Technical field
The present invention relates to field of computer technology, more particularly to a kind of image processing method, device, mobile terminal and meter Calculation machine readable storage medium storing program for executing.
Background technology
When there is greasy weather gas, imaging device by suspended particulate in air due to being influenceed, so as to cause to gather image Color, Texture eigenvalue are by serious weak, therefore the definition of such image is often relatively low, and the overall tone of image can tend to Grey albefaction.In order that the image containing mist is relatively sharp, defogging processing can be carried out to the image containing mist.Traditional defogging algorithm can wrap Dark primary elder generation checking method etc. is included, when the exposure of image is high, the checking method failure of dark primary elder generation, the defogging effect of image may be caused Fruit is poor.
The content of the invention
The embodiment of the present invention provides a kind of image processing method, device, mobile terminal and computer-readable recording medium, can To carry out defogging to the high image of exposure, the defog effect of image is improved.
A kind of image processing method, including:
Determine the exposure of the first pending image;
When the exposure is more than predetermined threshold value, then the brightness value of the described first pending image is reduced, obtains second Pending image;
The defogging parameter of the second pending image is calculated according to the brightness value after reduction;
Defogging processing is carried out to the described first pending image according to the defogging parameter.
In one of the embodiments, the brightness value for reducing by the first pending image, it is pending to obtain second Image, including:
Extract the characteristics of image of the described first pending image;
Described image feature is analyzed by the graphical analysis model pre-established, determines the described first pending figure The image type of picture;
Obtain the reference brightness value with described image type matching;
By the luminance-value reduction of the described first pending image to the reference brightness value, the second pending image is obtained.
In one of the embodiments, the brightness value according to after reduction calculates the defogging of the second pending image Parameter, including:
Air light value is determined according to the brightness value after reduction;
Original transmissivity is asked for according to the air light value;
Wave band corresponding with tri- wave bands difference of RGB in the second pending image according to the original transmittance calculation Transmissivity.
In one of the embodiments, in the second pending image according to the original transmittance calculation with Wavelength region rate corresponding to tri- wave bands difference of RGB, including:
Obtain adjustment factor corresponding with tri- wave bands difference of RGB in the described second pending image;
It is saturating that wave band corresponding with described tri- wave bands of RGB is calculated according to the original transmissivity and the adjustment factor respectively Penetrate rate.
In one of the embodiments, it is described that the described first pending image is carried out at defogging according to the defogging parameter Reason, including:
RGB tri- according to the wavelength region rate corresponding with tri- wave bands difference of RGB to the described first pending image Individual wave band carries out defogging processing.
A kind of image processing apparatus, including:
Exposure determining module, for determining the exposure of the first pending image;
Module is reduced, for when the exposure is more than predetermined threshold value, then reducing the bright of the described first pending image Angle value, obtain the second pending image;
Computing module, for calculating the defogging parameter of the second pending image according to the brightness value after reduction;
Defogging module, for carrying out defogging processing to the described first pending image according to the defogging parameter.
In one of the embodiments, the reduction module, including:
Extraction unit, for extracting the characteristics of image of the described first pending image;
Analytic unit, for being analyzed by the graphical analysis model pre-established described image feature, determine institute State the image type of the first pending image;
Reference brightness value acquiring unit, for obtaining the reference brightness value with described image type matching;
Unit is reduced, for by the luminance-value reduction of the described first pending image to the reference brightness value, obtaining the Two pending images.
In one of the embodiments, the computing module, including:
Air light value determining unit, for determining air light value according to the brightness value after reduction;
Unit is asked for, for asking for original transmissivity according to the air light value;
Wavelength region rate computing unit, in the second pending image according to the original transmittance calculation with Wavelength region rate corresponding to tri- wave bands difference of RGB;
The wavelength region rate computing unit, including:
Adjustment factor obtains subelement, corresponding respectively with tri- wave bands of RGB in the described second pending image for obtaining Adjustment factor;
Computation subunit, for being calculated respectively and the RGB tri- according to the original transmissivity and the adjustment factor Wavelength region rate corresponding to wave band;
The defogging module, it is additionally operable to distinguish corresponding wavelength region rate with tri- wave bands of RGB to described the according to described Tri- wave bands of RGB of one pending image carry out defogging processing.
A kind of mobile terminal, including memory, processor and storage are on a memory and the meter that can run on a processor Calculation machine program, method as described above is realized during the computing device described program.
A kind of computer-readable recording medium, is stored thereon with computer program, it is characterised in that the computer program Method as described above is realized when being executed by processor.
Above-mentioned image processing method, device, mobile terminal and computer-readable recording medium, when the first pending image When exposure is more than predetermined threshold value, the brightness value of the first pending image is reduced, obtains the second pending image, and according to reduction Brightness value afterwards calculates the defogging parameter of the second pending image, recycles defogging parameter to carry out defogging to the first pending image Processing, image that can be high to exposure carry out defogging, improve the defog effect of image.
Brief description of the drawings
Fig. 1 is the block diagram of each mobile terminal of one embodiment;
Fig. 2 is the schematic flow sheet of image processing method in one embodiment;
Fig. 3 is the schematic flow sheet for the brightness value that the first pending image is reduced in one embodiment;
Fig. 4 is the flow for the defogging parameter for calculating the second pending image in one embodiment according to the brightness value after reduction Schematic diagram;
Fig. 5 is that wavelength region corresponding with tri- wave bands difference of RGB in the second pending image is calculated in one embodiment The schematic flow sheet of rate;
Fig. 6 is the block diagram of image processing apparatus in one embodiment;
Fig. 7 is the block diagram that module is reduced in one embodiment;
Fig. 8 is the block diagram of computing module in one embodiment;
Fig. 9 is the schematic diagram of image processing circuit in one embodiment.
Embodiment
In order to make the purpose , technical scheme and advantage of the present invention be clearer, it is right below in conjunction with drawings and Examples The present invention is further elaborated.It should be appreciated that specific embodiment described herein is only to explain the present invention, not For limiting the present invention.
It is appreciated that term " first " used in the present invention, " second " etc. can be used to describe various elements herein, But these elements should not be limited by these terms.These terms are only used for distinguishing first element and another element.Citing comes Say, without departing from the scope of the invention, the first client can be referred to as the second client, and similarly, can incite somebody to action Second client is referred to as the first client.First client and the second client both clients, but it is not same visitor Family end.
Fig. 1 is the block diagram of mobile terminal in one embodiment.As shown in figure 1, the mobile terminal includes passing through system bus Processor, non-volatile memory medium, built-in storage and the network interface of connection, display screen and input unit.Wherein, it is mobile whole The non-volatile memory medium at end is stored with operating system and computer executable instructions, and the computer executable instructions are processed A kind of image processing method that device is provided when performing with realizing in the embodiment of the present invention.The processor, which is used to provide, to be calculated and controls Ability, support the operation of whole mobile terminal.Built-in storage in mobile terminal is the computer in non-volatile memory medium The operation of readable instruction provides environment.Network interface is used to carry out network service with server.The display screen of mobile terminal can be with LCDs or electric ink display screen etc., input unit can be the touch layer that is covered on display screen or Button, trace ball or the Trackpad or the external keyboard that are set on mobile terminal case, Trackpad or mouse etc..Should Mobile terminal can be mobile phone, tablet personal computer or personal digital assistant or Wearable etc..Those skilled in the art can be with Understand, the block diagram of the structure, the only part-structure related to application scheme that are shown in Fig. 1, do not form to the application The restriction for the mobile terminal that scheme is applied thereon, specific mobile terminal can include more more or less than shown in figure Part, either combine some parts or arranged with different parts.
As shown in Fig. 2 in one embodiment, there is provided a kind of image processing method, comprise the following steps:
Step 210, the exposure of the first pending image is determined.
In the present embodiment, the first pending image refers to the image containing mist, in having the weather of mist, water droplet in air More Deng particle, object to imaging device, such as the distance of camera, video camera etc. are more remote, and influence of the atmospheric particles to imaging is got over Greatly, image containing mist is due to the influence of atmospheric particles, generally has that contrast is low, saturation degree is low and the problems such as hue shift.It is mobile Terminal can obtain the first pending image, and determine the exposure of the first pending image, and exposure is typically referred in photographic process The middle light quantity being radiated at into camera lens on photo-sensitive cell, it can be controlled by the combination of aperture, shutter, sensitivity.
In one embodiment, mobile terminal can be first according to the first pending Image Rendering histogram, the transverse axis of histogram Brightness value can be represented, the longitudinal axis can represent the quantity of pixel.By the histogram, can intuitively obtain in the first pending image It is distributed in the population size of the pixel of each brightness section.Mobile terminal can obtain the first pending image institute according to histogram There are the information such as average brightness and the brightness median of pixel, and is determined according to the information such as average brightness and brightness median The exposure of one pending image, wherein, average brightness refers to the equal of the brightness value of the first pending image all pixels Value, after brightness median then can be by the way that the brightness value of the first pending image all pixels be arranged from small to large, takes most middle Numerical value obtained.
In other examples, mobile terminal also can be according to aperture size during the first pending image of shooting and exposure Time etc. calculates exposure of the first pending image etc., however it is not limited to aforesaid way.
Step 220, when exposure is more than predetermined threshold value, then the brightness value of the first pending image is reduced, obtains second Pending image.
Mobile terminal can determine whether the exposure of the first pending image is more than predetermined threshold value, when more than the predetermined threshold value When, it is believed that the first pending image exposure spends height, and the predetermined threshold value can be set according to the actual requirements.Wait to locate when first When the exposure of reason image is too high, illustrate that the brightness value of the first pending image is too high, calculated in defoggings such as dark primary elder generation checking methods In method, air light value need to be calculated according to the brightness value of the first pending image,, may when brightness value is too high so as to carry out defogging Cause the air light value inaccuracy asked for, cause the defogging algorithms such as dark primary elder generation checking method to fail, make the defog effect of image poor. Therefore, when the exposure of the first pending image is more than predetermined threshold value, the brightness value of the first pending image is can adjust, by the The luminance-value reduction of one pending image obtains having the second of default reference brightness value to wait to locate to default reference brightness value Manage image.
Step 230, the defogging parameter of the second pending image is calculated according to the brightness value after reduction.
In the present embodiment, mobile terminal can be carried out at defogging by dark primary elder generation checking method to the first pending image Reason, wherein, dark primary elder generation checking method belongs to a kind of defogging algorithm based on image restoration.Air is used in dark primary elder generation checking method Image containing mist is described scattering model, and the atmospherical scattering model can be as shown in formula (1):
I (x)=J (x) t (x)+A (1-t (x)) (1);
Wherein, I (x) represents to need the image containing mist for carrying out defogging processing, and J (x) represents to carry out at defogging image containing mist The fog free images obtained after reason, x represent the locus of a certain pixel in image, and t (x) represents transmissivity, and A represents atmosphere light Value.For fog free images, always there is at least one color in three passages of RGB (red, green, blue color space) and lead in some pixels Road has a very low value, and the value of the Color Channel is close to zero.Therefore, can be such as formula (2) for arbitrary image, its dark channel image It is shown:
Wherein, Jdark(x) dark channel image, J are representedc(y) value of Color Channel is represented, Ω (x) is represented using pixel x in One window of the heart.According to formula (1) and formula (2), it can derive that the calculation formula such as formula (3) of transmissivity is shown:
And in actual life, can also there are some particles even fine day white clouds, in air, see the object of distant place still The presence of mist can be experienced, and the presence of mist allows the mankind to feel the presence of the depth of field, therefore, can introduce one between [0,1] The transmissivity that factor pair is asked for is adjusted, then the calculating of transmissivity can be modified to formula (4) by formula (3) after the introducing factor:
Wherein, ω represent to transmissivity regulation the factor, in the present embodiment, ω can value be 0.95 or its It is worth, however it is not limited to which this, ω is smaller to represent that defogging degree is smaller, and ω is bigger to represent that defogging degree is bigger.
Mobile terminal can calculate the defogging parameter of the second pending image according to the brightness value after reduction, wherein, defogging ginseng Number may include air light value, transmissivity of the second pending image etc..Mobile terminal can ask for the second pending figure according to formula (2) The dark channel image of picture, and air light value is obtained, wherein, mobile terminal can be by the picture of the dark channel image of the second pending image Vegetarian refreshments is ranked up according to brightness, and extracts preceding 0.1% pixel from big to small according to brightness, then in the second pending image The brightness value of middle determination position corresponding with the pixel of extraction, the brightness value of the pixel wherein with highest brightness value is made For air light value.After acquisition for mobile terminal air light value, the transmissivity of the second pending image can be calculated according to formula (4).
Step 240, defogging processing is carried out to the first pending image according to defogging parameter.
, can be according to meter after the defogging parameters such as air light value and the transmissivity of the second pending image are calculated in mobile terminal Obtained defogging parameter carries out defogging processing to the first pending image.Using the first pending image as the I in formula (1) (x), and by air light value and transmissivity formula (1) is substituted into, you can ask for obtaining the image J (x) after defogging processing.For exposure Too high image containing mist, first reduces brightness value, and defogging parameter is asked for further according to the brightness value after reduction, can prevent because containing mist The defogging parameters such as the too high air light value asked for of the exposure of image, transmissivity are inaccurate, cause dark primary elder generation checking method etc. to go The problem of mist algorithm fails, carried out further according to the defogging parameter calculated after reduction brightness value containing the mist image too high to the exposure Defogging, the defog effect of the too high image containing mist of exposure can be effectively improved.
Above-mentioned image processing method, when the exposure of the first pending image is more than predetermined threshold value, reduces by first and wait to locate The brightness value of image is managed, obtains the second pending image, and going for the second pending image is calculated according to the brightness value after reduction Mist parameter, recycle defogging parameter to carry out defogging processing to the first pending image, can the image high to exposure go Mist, improve the defog effect of image.
As shown in figure 3, in one embodiment, step 220 then reduces by first and waits to locate when exposure is more than predetermined threshold value The brightness value of image is managed, the second pending image is obtained, comprises the following steps:
Step 302, the characteristics of image of the first pending image is extracted.
Mobile terminal can carry out image recognition to the first pending image, and the first pending image can be split, will First pending image such as is divided at big some regions, and the characteristics of image that detection regional is included one by one.Image is special Sign may include shape facility, space characteristics and edge feature etc., wherein, shape facility refers to local in the first pending image Shape, space characteristics refer to mutual locus between multiple regions for being split in the first pending image or Relative direction relation, edge feature refer to forming boundary pixel between two regions etc. in the first pending image.
Step 304, characteristics of image is analyzed by the graphical analysis model pre-established, determines the first pending figure The image type of picture.
The characteristics of image of extractable the first pending image detected of mobile terminal, and the image by pre-establishing point Analysis model is analyzed characteristics of image.The graphical analysis model can be the decision model built beforehand through machine learning, move Dynamic terminal can determine the image type of the first pending image by the graphical analysis model, wherein, image type may include people Thing image containing mist, unmanned landscape image containing mist etc., but not limited to this.When building graphical analysis model, it can obtain and largely carry The sample image of image type label, the input using sample image as graphical analysis model, image is determined by machine learning Each characteristics of image corresponding to branch node in analysis model, and image type corresponding to each leafy node.
Step 306, the reference brightness value matched with image type is obtained.
Mobile terminal is analyzed the characteristics of image of the first pending image of extraction by graphical analysis model, can be true Leafy node where fixed first pending image, so that it is determined that the image type of the first pending image, and can be from image point The reference brightness value matched with the leafy node is obtained in analysis model.Reference brightness value can be used for the figure for representing correspondence image type The overall brightness value of picture, when reference brightness value can be structure graphical analysis model, the leaf that is divided into where the first pending image The average brightness value of all sample images of node.Matched it is to be appreciated that can also use other modes to obtain with image type Reference brightness value, such as pre-establish image type and the corresponding relation of reference brightness value, the reference brightness value is default Empirical value etc., however it is not limited to aforesaid way.
Step 308, by the luminance-value reduction of the first pending image to reference brightness value, the second pending image is obtained.
Mobile terminal can adjust the first pending image brightness value, by the luminance-value reduction of the first pending image to The reference brightness value of affiliated image type matching, obtains the second pending image, and the second pending image is first to wait to locate Managing image reduces the image after brightness value.
In the present embodiment, image type can be determined according to the characteristics of image of the first pending image, and first is waited to locate The luminance-value reduction of image is managed to the reference brightness value matched with the image type, may be such that the defogging parameter of calculating is more accurate Really, the defog effect of image is effectively improved.
As shown in figure 4, in one embodiment, step 230 calculates the second pending image according to the brightness value after reduction Defogging parameter, comprise the following steps:
Step 402, air light value is determined according to the brightness value after reduction.
Step 404, original transmissivity is asked for according to air light value.
Mobile terminal reduces the brightness value of the first pending image, after obtaining the second pending image, can calculate second and treat The air light value of image is handled, and the original transmissivity of the second pending image is calculated according to the air light value.In the present embodiment In, original transmissivity refers to the overall transmissivity of the second pending image.
Step 406, according to wave band corresponding with tri- wave bands difference of RGB in original the second pending image of transmittance calculation Transmissivity.
Because influence of the mist to tri- wave bands of RGB is different, if being done to tri- wave bands of RGB at the defogging of same degree Reason, may cause the mist of green wave band and blue wave band not remove completely, and the image for causing defogging to be obtained after handling is partially blue, color occurs The problem of color distortion.For tri- wave bands of RGB, adjustment factor corresponding with tri- wave bands of RGB can be introduced respectively, and according to regulation It is t (r), t (g), t that coefficient, which recalculates wavelength region rate corresponding with tri- wave bands difference of RGB in the second pending image, (b)。
In one embodiment, step 240 carries out defogging processing according to defogging parameter to the first pending image, including: According to corresponding wavelength region rate is carried out at defogging to tri- wave bands of RGB of the first pending image respectively with tri- wave bands of RGB Reason.
For the mist of same concentrations, influence to tri- wave bands of RGB it is incremental, therefore, mobile terminal calculates second and treated Handle in image in wavelength region rate corresponding with tri- wave bands difference of RGB, the wavelength region rate t (r) of R wave bands is more than G-band Wavelength region rate t (g), the wavelength region rate t (g) of G-band is more than the wavelength region rate t (b) of B wave bands, and different wave bands is saturating Penetrate rate and represent that defogging processing intensity is different.Mobile terminal can be according to corresponding respectively with tri- wave bands of RGB in the second pending image Wavelength region rate, tri- wave bands of RGB of the first pending image are carried out with different degrees of defogging respectively and is handled.Can will be with Wavelength region rate t (r), t (g), t (b) corresponding to tri- wave bands difference of RGB bring formula (1) into respectively, try to achieve wait to locate to first respectively Value J (r), J (g), J (b) of the fog free images that reason image obtained after defogging processing on tri- passages of RGB, wherein, RGB What the defogging processing intensity of three wave bands was incremented by, that is, the defogging processing that the defogging processing intensity of R wave bands is less than G-band is strong Degree, the defogging processing intensity of G-band are less than the defogging processing intensity of B wave bands.Mobile terminal is respectively to the first pending image After tri- wave bands of RGB carry out defogging processing, value J (r), J (g), the J (b) of tri- passages of RGB are closed after can defogging be handled Into obtaining fog free images J (x).
In the present embodiment, the defogging that can tri- wave bands of RGB of the first pending image be carried out with varying strength is handled, both The mist in image can be effectively removed, while can solve, color partially blue using image after traditional defogging algorithm progress defogging The problem of distortion, make the color more natural reality of the image after defogging.
As shown in figure 5, in one embodiment, step 406 according in original the second pending image of transmittance calculation with Wavelength region rate corresponding to tri- wave bands difference of RGB, comprises the following steps:
Step 502, adjustment factor corresponding with tri- wave bands difference of RGB in the second pending image is obtained.
Mobile terminal can obtain default adjustment factor corresponding with tri- wave bands difference of RGB in the second pending image, Wherein, the adjustment factor of R wave bands is more than the adjustment factor of G-band, and the adjustment factor of G-band is more than the adjustment factor of B wave bands. In one embodiment, the adjustment factor W of R wave bandsrCan be 1, the adjustment factor W of G-bandgAnd the adjustment factor W of B wave bandsbCan basis Formula (5) and formula (6) are calculated:
Wg=(0.9+0.1*t)2(5);
Wb=(0.7+0.3*t)2(6);
Wherein, t represents the original transmissivity of the second pending image.
Step 504, wavelength region corresponding with tri- wave bands of RGB is calculated according to original transmissivity and adjustment factor respectively Rate.
Adjustment factor corresponding with tri- wave bands difference of RGB can be multiplied by mobile terminal with original transmissivity, you can calculate Wavelength region rate corresponding to obtaining, the wavelength region rate for calculating tri- wave bands of RGB can be as shown in formula (7):
T (r)=Wr*t
T (g)=Wg*t
T (b)=Wb*t (7)。
It is to be appreciated that the adjustment factor of tri- wave bands of RGB is not limited in the calculation of above-mentioned formula (5) and formula (6), The calculation for being also not limited to above-mentioned formula (7) of wavelength region rate or other calculations.
In the present embodiment, adjustment factor corresponding with tri- wave bands of RGB is introduced respectively, is calculated respectively according to adjustment factor Wavelength region rate corresponding to tri- wave bands of RGB, waits to locate further according to the wavelength region rate of calculating to first in second pending image Tri- wave bands of RGB for managing image carry out the defogging processing of varying strength, can effectively remove the mist in image, while can solve Image is partially blue after certainly carrying out defogging using traditional defogging algorithm, the problem of cross-color, makes the color of the image after defogging more For natural reality.
As shown in fig. 6, in one embodiment, there is provided a kind of image processing apparatus 600, including exposure determining module 610th, module 620, computing module 630 and defogging module 640 are reduced.
Exposure determining module 610, for determining the exposure of the first pending image.
Module 620 is reduced, for when exposure is more than predetermined threshold value, then reducing the brightness value of the first pending image, Obtain the second pending image.
Computing module 630, for calculating the defogging parameter of the second pending image according to the brightness value after reduction.
Defogging module 640, for carrying out defogging processing to the first pending image according to defogging parameter.
Above-mentioned image processing apparatus, when the exposure of the first pending image is more than predetermined threshold value, reduces by first and wait to locate The brightness value of image is managed, obtains the second pending image, and going for the second pending image is calculated according to the brightness value after reduction Mist parameter, recycle defogging parameter to carry out defogging processing to the first pending image, can the image high to exposure go Mist, improve the defog effect of image.
As shown in fig. 7, in one embodiment, reducing module 620 includes extraction unit 622, analytic unit 624, reference Brightness value acquiring unit 626 and reduction unit 628.
Extraction unit 622, for extracting the characteristics of image of the first pending image.
Analytic unit 624, for being analyzed by the graphical analysis model pre-established characteristics of image, determine first The image type of pending image.
Reference brightness value acquiring unit 626, for obtaining the reference brightness value matched with image type.
Unit 628 is reduced, for by the luminance-value reduction of the first pending image to reference brightness value, obtaining second and waiting to locate Manage image.
In the present embodiment, image type can be determined according to the characteristics of image of the first pending image, and first is waited to locate The luminance-value reduction of image is managed to the reference brightness value matched with the image type, may be such that the defogging parameter of calculating is more accurate Really, the defog effect of image is effectively improved.
As shown in figure 8, in one embodiment, computing module 630 includes air light value determining unit 632, asks for unit 634 and wavelength region rate computing unit 636.
Air light value determining unit 632, for determining air light value according to the brightness value after reduction.
Unit 634 is asked for, for asking for original transmissivity according to air light value.
Wavelength region rate computing unit 636, for according in original the second pending image of transmittance calculation with RGB tri- Wavelength region rate corresponding to wave band difference.
In one embodiment, defogging module 640, it is additionally operable to according to wavelength region corresponding with tri- wave bands difference of RGB Rate carries out defogging processing to tri- wave bands of RGB of the first pending image.
In the present embodiment, the defogging that can tri- wave bands of RGB of the first pending image be carried out with varying strength is handled, both The mist in image can be effectively removed, while can solve, color partially blue using image after traditional defogging algorithm progress defogging The problem of distortion, make the color more natural reality of the image after defogging.
In one embodiment, wavelength region rate computing unit 636, including adjustment factor obtain subelement and calculate son list Member.
Adjustment factor obtains subelement, for obtaining corresponding with tri- wave bands difference of RGB in the second pending image adjust Save coefficient.
Computation subunit, for calculating ripple corresponding with tri- wave bands of RGB respectively according to original transmissivity and adjustment factor Section transmissivity.
In the present embodiment, adjustment factor corresponding with tri- wave bands of RGB is introduced respectively, is calculated respectively according to adjustment factor Wavelength region rate corresponding to tri- wave bands of RGB, waits to locate further according to the wavelength region rate of calculating to first in second pending image Tri- wave bands of RGB for managing image carry out the defogging processing of varying strength, can effectively remove the mist in image, while can solve Image is partially blue after certainly carrying out defogging using traditional defogging algorithm, the problem of cross-color, makes the color of the image after defogging more For natural reality.
The embodiment of the present invention also provides a kind of mobile terminal.Above-mentioned mobile terminal includes image processing circuit, at image Managing circuit can utilize hardware and/or component software to realize, it may include define ISP (Image SignalProcessing, image Signal transacting) pipeline various processing units.Fig. 9 is the schematic diagram of image processing circuit in one embodiment.As shown in figure 9, For purposes of illustration only, the various aspects of the image processing techniques related to the embodiment of the present invention are only shown.
As shown in figure 9, image processing circuit includes ISP processors 940 and control logic device 950.Imaging device 910 is caught View data handled first by ISP processors 940, ISP processors 940 view data is analyzed with catch can be used for it is true The image statistics of fixed and/or imaging device 910 one or more control parameters.Imaging device 910 may include there is one The camera of individual or multiple lens 912 and imaging sensor 914.Imaging sensor 914 may include colour filter battle array (such as Bayer Filter), imaging sensor 914 can obtain the luminous intensity and wavelength information caught with each imaging pixel of imaging sensor 914, And provide the one group of raw image data that can be handled by ISP processors 940.Sensor 920 can be based on the interface type of sensor 920 Raw image data is supplied to ISP processors 940.The interface of sensor 920 can utilize SMIA (Standard Mobile Imaging Architecture, Standard Mobile Imager framework) interface, other serial or parallel camera interfaces or above-mentioned connect The combination of mouth.
ISP processors 940 handle raw image data pixel by pixel in various formats.For example, each image pixel can Bit depth with 8,10,12 or 14 bits, ISP processors 940 can be carried out at one or more images to raw image data Reason operation, statistical information of the collection on view data.Wherein, image processing operations can be by identical or different bit depth precision Carry out.
ISP processors 940 can also receive pixel data from video memory 930.For example, from the interface of sensor 920 by original Beginning pixel data is sent to video memory 930, and the raw pixel data in video memory 930 is available to ISP processors 940 is for processing.Video memory 930 can be independent in a part, storage device or electronic equipment for storage arrangement Private memory, and may include DMA (Direct Memory Access, direct direct memory access (DMA)) feature.
When receiving the raw image data from the interface of sensor 920 or from video memory 930, ISP processing Device 940 can carry out one or more image processing operations, such as time-domain filtering.View data after processing can be transmitted to be stored to image Device 930, to carry out other processing before shown.ISP processors 940 can also be from the reception processing of video memory 930 Data, the image real time transfer in original domain and in RGB and YCbCr color spaces is carried out to above-mentioned processing data.After processing View data may be output to display 980, for user watch and/or by graphics engine or GPU (Graphics Processing Unit, graphics processor) further processing.In addition, the output of ISP processors 940 also can be transmitted and be deposited to image Reservoir 930, and display 980 can read view data from video memory 930.In one embodiment, video memory 930 It can be configured as realizing one or more frame buffers.In addition, the output of ISP processors 940 can be transmitted to encoder/decoder 970, so as to encoding/decoding image data.The view data of coding can be saved, and display with the equipment of display 980 on it Preceding decompression.
The step of processing view data of ISP processors 940, includes:To view data carry out VFE (Video FrontEnd, Video front) handle and CPP (Camera Post Processing, camera post processing) processing.At the VFE of view data Reason may include correct view data contrast or brightness, modification record in a digital manner illumination conditions data, to picture number According to compensate processing (such as white balance, automatic growth control, γ correction etc.), to view data be filtered processing etc..To figure As the CPP processing of data may include to zoom in and out image, preview frame and record frame are provided to each path.Wherein, CPP can make Preview frame and record frame are handled with different codecs.
View data after the processing of ISP processors 940 can be transmitted to defogging module 960, so as to before shown to figure As carrying out defogging processing.Defogging module 960 can reduce the brightness value of the first pending image, obtain the second pending image, root The defogging parameter of the second pending image is calculated according to the brightness value after reduction, and is treated according to the defogging parameter being calculated to first Handle image and carry out defogging processing etc..Wherein, defogging module 960 can be CPU (Central Processing in mobile terminal Unit, central processing unit), GPU or coprocessor etc.., can be by defogging after view data is carried out defogging processing by defogging module 960 View data after processing is sent to encoder/decoder 970, so as to encoding/decoding image data.The view data of coding can Be saved, and show with the equipment of display 980 before decompress.It is understood that the figure after the processing of defogging module 960 As data can directly be issued display 980 and shown without encoder/decoder 970.After the processing of ISP processors 940 View data can also first pass through encoder/decoder 970 and handle, then handled again by defogging module 960.It is above-mentioned Encoder/decoder can be CPU, GPU or coprocessor etc. in mobile terminal.
The statistics that ISP processors 940 determine, which can be transmitted, gives the unit of control logic device 950.For example, statistics can wrap Include the image sensings such as automatic exposure, AWB, automatic focusing, flicker detection, black level compensation, the shadow correction of lens 912 The statistical information of device 914.Control logic device 950 may include the processor and/or micro-control for performing one or more routines (such as firmware) Device processed, one or more routines according to the statistics of reception, can determine control parameter and the ISP processing of imaging device 910 The control parameter of device 940.For example, control parameter may include the control parameter of sensor 920 (such as gain, the integration of spectrum assignment Time), camera flash control parameter, the group of the control parameter of lens 912 (such as focus on or zoom focal length) or these parameters Close.ISP control parameters may include the gain level for being used for AWB and color adjustment (for example, RGB processing during) and Color correction matrix, and the shadow correction parameter of lens 912.
In the present embodiment, above-mentioned image processing method can be realized with the image processing techniques in Fig. 9.
In one embodiment, there is provided a kind of computer-readable recording medium, be stored thereon with computer program, the calculating Machine program realizes above-mentioned image processing method when being executed by processor.
One of ordinary skill in the art will appreciate that realize all or part of flow in above-described embodiment method, being can be with The hardware of correlation is instructed to complete by computer program, described program can be stored in a non-volatile computer and can be read In storage medium, the program is upon execution, it may include such as the flow of the embodiment of above-mentioned each method.Wherein, described storage is situated between Matter can be magnetic disc, CD, read-only memory (Read-OnlyMemory, ROM) etc..
Each technical characteristic of embodiment described above can be combined arbitrarily, to make description succinct, not to above-mentioned reality Apply all possible combination of each technical characteristic in example to be all described, as long as however, the combination of these technical characteristics is not deposited In contradiction, the scope that this specification is recorded all is considered to be.
Embodiment described above only expresses the several embodiments of the present invention, and its description is more specific and detailed, but simultaneously Can not therefore it be construed as limiting the scope of the patent.It should be pointed out that come for one of ordinary skill in the art Say, without departing from the inventive concept of the premise, various modifications and improvements can be made, these belong to the protection of the present invention Scope.Therefore, the protection domain of patent of the present invention should be determined by the appended claims.

Claims (10)

  1. A kind of 1. image processing method, it is characterised in that including:
    Determine the exposure of the first pending image;
    When the exposure is more than predetermined threshold value, then the brightness value of the described first pending image is reduced, second is obtained and waits to locate Manage image;
    The defogging parameter of the second pending image is calculated according to the brightness value after reduction;
    Defogging processing is carried out to the described first pending image according to the defogging parameter.
  2. 2. according to the method for claim 1, it is characterised in that the brightness value for reducing by the first pending image, The second pending image is obtained, including:
    Extract the characteristics of image of the described first pending image;
    Described image feature is analyzed by the graphical analysis model pre-established, determines the described first pending image Image type;
    Obtain the reference brightness value with described image type matching;
    By the luminance-value reduction of the described first pending image to the reference brightness value, the second pending image is obtained.
  3. 3. according to the method for claim 1, it is characterised in that the brightness value according to after reduction calculates described second and treated The defogging parameter of image is handled, including:
    Air light value is determined according to the brightness value after reduction;
    Original transmissivity is asked for according to the air light value;
    Wavelength region corresponding with tri- wave bands difference of RGB in the second pending image according to the original transmittance calculation Rate.
  4. 4. according to the method for claim 3, it is characterised in that described second to be treated according to the original transmittance calculation Wavelength region rate corresponding with tri- wave bands difference of RGB in image is handled, including:
    Obtain adjustment factor corresponding with tri- wave bands difference of RGB in the described second pending image;
    Wavelength region corresponding with described tri- wave bands of RGB is calculated according to the original transmissivity and the adjustment factor respectively Rate.
  5. 5. the method according to claim 3 or 4, it is characterised in that described to be treated according to the defogging parameter to described first Handle image and carry out defogging processing, including:
    Tri- ripples of RGB according to the wavelength region rate corresponding with tri- wave bands difference of RGB to the described first pending image The processing of Duan Jinhang defoggings.
  6. A kind of 6. image processing apparatus, it is characterised in that including:
    Exposure determining module, for determining the exposure of the first pending image;
    Module is reduced, for when the exposure is more than predetermined threshold value, then reducing the brightness value of the described first pending image, Obtain the second pending image;
    Computing module, for calculating the defogging parameter of the second pending image according to the brightness value after reduction;
    Defogging module, for carrying out defogging processing to the described first pending image according to the defogging parameter.
  7. 7. device according to claim 6, it is characterised in that the reduction module, including:
    Extraction unit, for extracting the characteristics of image of the described first pending image;
    Analytic unit, for being analyzed by the graphical analysis model pre-established described image feature, determine described The image type of one pending image;
    Reference brightness value acquiring unit, for obtaining the reference brightness value with described image type matching;
    Unit is reduced, for by the luminance-value reduction of the described first pending image to the reference brightness value, obtaining second and treating Handle image.
  8. 8. device according to claim 6, it is characterised in that the computing module, including:
    Air light value determining unit, for determining air light value according to the brightness value after reduction;
    Unit is asked for, for asking for original transmissivity according to the air light value;
    Wavelength region rate computing unit, in the second pending image according to the original transmittance calculation with RGB tri- Wavelength region rate corresponding to individual wave band difference;
    The wavelength region rate computing unit, including:
    Adjustment factor obtains subelement, for obtaining corresponding with tri- wave bands difference of RGB in the described second pending image adjust Save coefficient;
    Computation subunit, for being calculated respectively and described tri- wave bands of RGB according to the original transmissivity and the adjustment factor Corresponding wavelength region rate;
    The defogging module, is additionally operable to according to described that corresponding wavelength region rate is treated to described first respectively with tri- wave bands of RGB Tri- wave bands of RGB for handling image carry out defogging processing.
  9. 9. a kind of mobile terminal, including memory, processor and storage are on a memory and the calculating that can run on a processor Machine program, the method as described in claim 1 to 5 is any is realized during the computing device described program.
  10. 10. a kind of computer-readable recording medium, is stored thereon with computer program, it is characterised in that the computer program The method as described in claim 1 to 5 is any is realized when being executed by processor.
CN201710625428.9A 2017-07-27 2017-07-27 Image processing method, image processing device, mobile terminal and computer readable storage medium Active CN107392870B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710625428.9A CN107392870B (en) 2017-07-27 2017-07-27 Image processing method, image processing device, mobile terminal and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710625428.9A CN107392870B (en) 2017-07-27 2017-07-27 Image processing method, image processing device, mobile terminal and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN107392870A true CN107392870A (en) 2017-11-24
CN107392870B CN107392870B (en) 2020-07-21

Family

ID=60342777

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710625428.9A Active CN107392870B (en) 2017-07-27 2017-07-27 Image processing method, image processing device, mobile terminal and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN107392870B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108171667A (en) * 2017-12-29 2018-06-15 努比亚技术有限公司 A kind of image processing method, terminal and computer readable storage medium
CN112598586A (en) * 2020-12-11 2021-04-02 青岛海信移动通信技术股份有限公司 Foggy day image display method and terminal
CN113228621A (en) * 2018-12-29 2021-08-06 浙江大华技术股份有限公司 Exposure control method and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104134194A (en) * 2014-07-23 2014-11-05 中国科学院深圳先进技术研究院 Image defogging method and image defogging system
CN105023256A (en) * 2015-08-13 2015-11-04 丘璇 Image defogging method and system
CN105447825A (en) * 2015-10-08 2016-03-30 湖北大学 Image defogging method and system
CN105631823A (en) * 2015-12-28 2016-06-01 西安电子科技大学 Dark channel sky area defogging method based on threshold segmentation optimization
CN106023118A (en) * 2016-06-13 2016-10-12 凌云光技术集团有限责任公司 Image defogging method and realization method on FPGA

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104134194A (en) * 2014-07-23 2014-11-05 中国科学院深圳先进技术研究院 Image defogging method and image defogging system
CN105023256A (en) * 2015-08-13 2015-11-04 丘璇 Image defogging method and system
CN105447825A (en) * 2015-10-08 2016-03-30 湖北大学 Image defogging method and system
CN105631823A (en) * 2015-12-28 2016-06-01 西安电子科技大学 Dark channel sky area defogging method based on threshold segmentation optimization
CN106023118A (en) * 2016-06-13 2016-10-12 凌云光技术集团有限责任公司 Image defogging method and realization method on FPGA

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108171667A (en) * 2017-12-29 2018-06-15 努比亚技术有限公司 A kind of image processing method, terminal and computer readable storage medium
CN113228621A (en) * 2018-12-29 2021-08-06 浙江大华技术股份有限公司 Exposure control method and system
CN113228621B (en) * 2018-12-29 2022-06-21 浙江大华技术股份有限公司 Imaging control method, system and non-transitory computer readable medium
US11546520B2 (en) 2018-12-29 2023-01-03 Zhejiang Dahua Technology Co., Ltd. Systems and methods for exposure control
CN112598586A (en) * 2020-12-11 2021-04-02 青岛海信移动通信技术股份有限公司 Foggy day image display method and terminal
CN112598586B (en) * 2020-12-11 2022-11-11 青岛海信移动通信技术股份有限公司 Foggy day image display method and terminal

Also Published As

Publication number Publication date
CN107392870B (en) 2020-07-21

Similar Documents

Publication Publication Date Title
CN107424198B (en) Image processing method, image processing device, mobile terminal and computer readable storage medium
CN107451969A (en) Image processing method, device, mobile terminal and computer-readable recording medium
EP2987134B1 (en) Generation of ghost-free high dynamic range images
CN108805103A (en) Image processing method and device, electronic equipment, computer readable storage medium
CN107317967A (en) Image processing method, device, mobile terminal and computer-readable recording medium
CN107911625A (en) Light measuring method, device, readable storage medium storing program for executing and computer equipment
CN107395991B (en) Image synthesis method, image synthesis device, computer-readable storage medium and computer equipment
CN107493432A (en) Image processing method, device, mobile terminal and computer-readable recording medium
CN107563976A (en) U.S. face parameter acquiring method, device, readable storage medium storing program for executing and computer equipment
CN107993209A (en) Image processing method, device, computer-readable recording medium and electronic equipment
CN107194901B (en) Image processing method, image processing device, computer equipment and computer readable storage medium
CN109089041A (en) Recognition methods, device, electronic equipment and the storage medium of photographed scene
CN107277299A (en) Image processing method, device, mobile terminal and computer-readable recording medium
CN107465903A (en) Image white balance method, device and computer-readable recording medium
CN107392870A (en) Image processing method, device, mobile terminal and computer-readable recording medium
CN107341782B (en) Image processing method, image processing device, computer equipment and computer readable storage medium
CN107277369B (en) Image processing method, device, computer readable storage medium and computer equipment
CN107454317A (en) Image processing method, device, computer-readable recording medium and computer equipment
CN107454318A (en) Image processing method, device, mobile terminal and computer-readable recording medium
CN107959843B (en) Image processing method and device, computer readable storage medium and computer equipment
CN107424134B (en) Image processing method, image processing device, computer-readable storage medium and computer equipment
CN107295261A (en) Image defogging processing method, device, storage medium and mobile terminal
CN107392871B (en) Image defogging method and device, mobile terminal and computer readable storage medium
CN112700396A (en) Illumination evaluation method and device for face picture, computing equipment and storage medium
CN113298829B (en) Image processing method, device, electronic equipment and computer readable storage medium

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

Address before: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

GR01 Patent grant
GR01 Patent grant