CN112055191A - White balance adjustment method, image acquisition device and storage medium - Google Patents

White balance adjustment method, image acquisition device and storage medium Download PDF

Info

Publication number
CN112055191A
CN112055191A CN202010866320.0A CN202010866320A CN112055191A CN 112055191 A CN112055191 A CN 112055191A CN 202010866320 A CN202010866320 A CN 202010866320A CN 112055191 A CN112055191 A CN 112055191A
Authority
CN
China
Prior art keywords
statistical
area
white
component information
black
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
CN202010866320.0A
Other languages
Chinese (zh)
Other versions
CN112055191B (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.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology Co 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 Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202010866320.0A priority Critical patent/CN112055191B/en
Publication of CN112055191A publication Critical patent/CN112055191A/en
Application granted granted Critical
Publication of CN112055191B publication Critical patent/CN112055191B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/80Camera processing pipelines; Components thereof
    • H04N23/84Camera processing pipelines; Components thereof for processing colour signals
    • H04N23/88Camera processing pipelines; Components thereof for processing colour signals for colour balance, e.g. white-balance circuits or colour temperature control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/80Camera processing pipelines; Components thereof
    • H04N23/84Camera processing pipelines; Components thereof for processing colour signals

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Color Television Image Signal Generators (AREA)
  • Processing Of Color Television Signals (AREA)

Abstract

The application discloses a white balance adjustment method, an image acquisition device and a storage medium, wherein the method is applied to the image acquisition device comprising a color acquisition unit and a black and white acquisition unit, and comprises the following steps: respectively acquiring a color picture output by a color acquisition unit and a black and white picture output by a black and white acquisition unit; the color picture comprises a plurality of first statistical areas, the black and white picture comprises a plurality of second statistical areas, and the second statistical areas and the first statistical areas are correspondingly divided; selecting at least one first statistical area as a reference statistical area based on the brightness component information of each first statistical area and each second statistical area; selecting at least one first statistical area as a trust statistical area based on the chrominance component information of the reference statistical area; and performing white balance calculation on the trust statistical area to obtain a target gain value, so that the problem of white balance color cast can be avoided.

Description

White balance adjustment method, image acquisition device and storage medium
Technical Field
The present application relates to the field of information security technologies, and in particular, to a method for adjusting white balance, an image capturing device, and a storage medium.
Background
Along with the development of security protection technology, the night low-light effect is more and more emphasized, the monocular and duplex fusion image acquisition equipment is developed, and in practical application, the problem of white balance color cast often occurs. If image acquisition equipment that monocular double-circuit fuses gathers the image under the extremely black environment at night, and when the infrared lamp of special wave band was opened in collocation and use together, because the reason of technology, the coating film for filtering infrared wave band is unable complete filtration clean infrared wave band, makes red infrared light in can showing in the colored picture like this, and then can appear the color cast when white balance is done on colored road, so need one kind can solve the technical scheme of above-mentioned white balance color cast problem.
Disclosure of Invention
The technical problem mainly solved by the application is to provide a method capable of avoiding the white balance color cast problem, and particularly to provide a white balance adjusting method, image acquisition equipment and a storage medium.
In order to solve the technical problem, the application adopts a technical scheme that: there is provided a method of white balance adjustment, the method being applied to an image pickup apparatus including a color pickup unit and a black-and-white pickup unit, the method including:
respectively acquiring a color picture output by the color acquisition unit and a black and white picture output by the black and white acquisition unit; the color picture comprises a plurality of first statistical areas, the black-and-white picture comprises a plurality of second statistical areas, and the second statistical areas and the first statistical areas are divided correspondingly;
selecting at least one first statistical area as a reference statistical area based on the brightness component information of each first statistical area and the second statistical area;
selecting at least one first statistical area as a trust statistical area based on the chrominance component information of the reference statistical area;
and performing white balance calculation on the trust statistical region to obtain a target gain value.
In order to solve the above technical problem, another technical solution adopted by the present application is: there is provided an image acquisition apparatus comprising a memory, a processor, a color acquisition unit and a black and white acquisition unit, the memory, the color acquisition unit and the black and white acquisition unit being coupled to the processor, respectively, wherein,
the color acquisition unit is used for acquiring a color picture and outputting the color picture to the processor;
the black and white acquisition unit is used for acquiring black and white pictures and outputting the black and white pictures to the processor;
the memory stores a computer program;
the processor is adapted to run the computer program to perform the method as described above.
In order to solve the above technical problem, the present application adopts another technical solution: there is provided a storage medium storing a computer program capable of being executed by a processor, the computer program being for implementing the method as described above.
The beneficial effect of this application is: different from the prior art, according to the technical scheme provided by the application, the color picture output by the color acquisition unit and the black-and-white picture output by the black-and-white unit are respectively obtained, and at least one first statistical area is selected as a reference statistical area based on the brightness component information of each first statistical area included in the color picture and each second statistical area included in the black-and-white picture. After the reference statistical area is selected, at least one first statistical area is selected from the color picture as a trust statistical area based on the chrominance component of the selected reference statistical area, and finally, the white balance calculation is carried out based on the determined trust statistical area to obtain a target gain value, so that the statistical area which possibly causes white balance color cast is removed based on the luminance component information and the chrominance component information, the target gain value obtained by the white balance calculation is more accurate, and the white balance color cast problem is avoided.
Drawings
Fig. 1 is a schematic flowchart illustrating an embodiment of a method for adjusting white balance according to the present application;
FIG. 2 is a schematic flow chart illustrating another embodiment of a method for adjusting white balance according to the present application;
FIG. 3 is a schematic flow chart illustrating a method for adjusting white balance according to another embodiment of the present disclosure;
FIG. 4 is a flowchart illustrating a method of adjusting white balance according to another embodiment of the present disclosure;
FIG. 5 is a flowchart illustrating a method for adjusting white balance according to an embodiment of the present disclosure;
FIG. 6 is a schematic structural diagram of an embodiment of an image capturing device according to the present application;
fig. 7 is a schematic structural diagram of an embodiment of a storage medium according to the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. It is to be understood that the specific embodiments described herein are merely illustrative of the application and are not limiting of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In the description of the present application, "plurality" means at least two, e.g., two, three, etc., unless explicitly specifically limited otherwise. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
It should be noted that the present application provides a method for adjusting white balance, which is applied to an image capturing apparatus including a color capturing unit and a black and white capturing unit. Wherein, the image acquisition equipment at least comprises monocular double-fusion image acquisition equipment. In order to better illustrate the technical scheme provided by the application, the image acquisition device is taken as a monocular dual-fusion image acquisition device as an example, and the main structure of the monocular dual-fusion image acquisition device is firstly and simply illustrated. The common monocular double-fusion image acquisition equipment mostly uses one lens, and a light path is divided into two paths through a light splitting prism and respectively transmitted to a sensor1 and a sensor 2. Two sensors, one is a color path for sensing light with infrared band removed and displaying colored visible light images on the picture; one path senses light of a full wave band, and simultaneously displays a black and white path of a black and white full wave band image. When the actual image is output, the two paths of images are subjected to pixel superposition and fusion to obtain a final output picture, and the output of the picture is realized. However, in the practical application of the monocular dual-fusion image acquisition device, the infrared lamp with a special waveband can be matched and started to be used together in an extremely dark environment at night. It should be noted that, in the technical solution provided in the present application, a structure included in a color road is defined as a color acquisition unit, and a structure included in a black and white road is defined as a black and white acquisition unit.
Theoretically, when an infrared lamp with a special waveband is turned on at night, a color road can only feel a visible waveband after the infrared lamp passes through a prism film coating or an optical filter. However, in an actual use environment, due to a process, the coating film cannot completely filter out an infrared band, and the color collecting unit still receives a part of infrared light components, so that medium red infrared light can be displayed in a color picture. In this case, the white balance is made to partially incorporate the infrared-irradiated region into the reference region calculated by the white balance algorithm at the time of processing, and it is desirable not to adopt this part of the image information as the reference information calculated by the white balance algorithm. In practical use, since it is difficult to judge the infrared information by the color road alone, color cast occurs when the color road is white balanced, and the method for adjusting the white balance provided by the application can better solve the technical problems.
Referring to fig. 1, fig. 1 is a schematic flow chart illustrating an embodiment of a white balance adjustment method according to the present application. In the current embodiment, the method provided by the present application includes:
s110: respectively acquiring the color picture output by the color acquisition unit and the black and white picture output by the black and white acquisition unit.
In the present embodiment, the image output by the color acquisition unit is a color image, the image output by the black-and-white acquisition unit is a black-and-white image, the color image includes a plurality of first statistical areas, and the black-and-white image includes a plurality of second statistical areas. It should be noted that, the second statistical area and the first statistical area are divided correspondingly, that is, the color picture and the black-and-white picture corresponding to the color picture are divided according to the same division rule, and it can also be understood that the second statistical area of the black-and-white picture corresponding to the color picture is divided into 32 × 32 blocks according to the same division rule as the first statistical area, and if the color picture is divided into 32 × 32 blocks, the corresponding black-and-white picture is also divided into 32 × 32 blocks according to the same division rule.
Further, in the current embodiment, the number of pixels included in each statistical area is not limited, and may be specifically set according to actual requirements and configurations. For example, in some embodiments, when the performance of the hardware configuration is sufficient, each pixel point in the color picture and the black-and-white picture is divided into one statistical region, and when the performance of the hardware configuration is insufficient, each statistical region may be divided to include a plurality of pixel points, that is, the whole picture is divided to obtain a plurality of statistical regions.
After the image acquisition equipment acquires an image, firstly, a color picture output by a color acquisition unit and a black-and-white picture output by a black-and-white acquisition unit in the image acquisition equipment are acquired. After the color picture and the black-and-white picture are obtained, the attribute information of the color picture and the black-and-white picture is further counted respectively, wherein the attribute information of the color picture and the black-and-white picture at least comprises the pixel value of each pixel point in the picture, and the attribute information of the color picture and the black-and-white picture at least comprises the energy value of each pixel point in the picture after photoelectric conversion.
Further, the format of the color picture includes any one of YUV data format, LAB data format, HSV data format, and HSL data format. It is understood that in other embodiments, the format of the color picture may also include other types of data formats, which are not listed here.
S120: and selecting at least one first statistical region as a reference statistical region based on the brightness component information of each first statistical region and each second statistical region.
After the color picture output by the color acquisition unit and the black-and-white picture output by the black-and-white acquisition unit are respectively acquired, the luminance component information of each first statistical area and the luminance component information of each second statistical area are respectively calculated and acquired further based on the attribute information of the color picture and the black-and-white picture obtained by statistics. And after the brightness component information of each first statistical area and the brightness component information of each second statistical area are obtained, at least one first statistical area is selected from the color picture as a reference statistical area based on the brightness component information of the first statistical area and the brightness component information of the second statistical area which are obtained through calculation and a preset selection rule. Wherein, the preset selection rule at least comprises: selecting a first statistical area between which the chroma component information difference is larger than or equal to a first preset threshold value, or selecting a preset number of first statistical areas with the top sequence according to the sequence of the chroma component information difference from large to small.
S130: and selecting at least one first statistical region as a trust statistical region based on the chrominance component information of the reference statistical region.
After selecting at least one first statistical region as a reference statistical region, further calculating chrominance component information of each reference statistical region, and selecting at least one first statistical region from the first statistical regions included in the color picture as a trusted statistical region based on the calculated chrominance component information. Specifically, the chrominance component information is calculated based on the pixel value of each pixel in the reference statistical region, and the calculation process of the chrominance is the prior art and is not described in detail herein.
In another embodiment, RAW data may be converted into RGB data format, and then the RGB format may be converted into YUV data format. In the current embodiment, the chrominance component information may be acquired by acquiring the UV component.
The trusted statistical region is a first statistical region finally used for white balance calculation, and a corresponding untrusted statistical region described below is a first statistical region which is not required to be considered in the white balance calculation process, and can also be understood as a first statistical region which can cause a color cast problem to the white balance calculation.
Further, in an embodiment, after the chrominance component information of each reference statistical area is calculated, an untrusted statistical area is further screened from the reference statistical areas based on the calculated chrominance component information, the untrusted statistical area is removed from a color picture, and then a first statistical area remaining after the untrusted statistical area is removed from the color picture is selected as a trusted statistical area.
S140: and carrying out white balance calculation on the trust statistical region to obtain a target gain value.
And after the trust statistical region is selected, white balance calculation is further carried out on the trust statistical region, and a target gain value is further obtained. Wherein the target gain value is a gain value for gain processing of the color picture.
Further, in some embodiments, after obtaining the target gain value, the color picture is further subjected to gain processing by using the obtained target gain value, and the color picture subjected to gain processing by using the target gain value is superimposed on the black-and-white picture to obtain a target output picture, so as to output the target output picture to realize picture output.
In the technical scheme provided in fig. 1 of the present application, a color picture output by a color acquisition unit and a black-and-white picture output by a black-and-white unit are respectively obtained, and at least one first statistical area is selected as a reference statistical area based on luminance component information of each first statistical area included in the color picture and each second statistical area included in the black-and-white picture. After the reference statistical area is selected, the distrust statistical area in the color picture is removed based on the chroma component information of the selected reference statistical area, at least one first statistical area is selected from the color picture to be used as a trust statistical area, finally, the white balance calculation is carried out based on the determined trust statistical area to obtain a target gain value, the statistical area which possibly causes color cast is removed based on the brightness component information and the chroma component information, the target gain value obtained by the white balance calculation is more accurate, and the color cast problem under infrared interference is avoided.
Referring to fig. 2, fig. 2 is a schematic flow chart of another embodiment of a method for adjusting white balance according to the present application. In the present embodiment, the content corresponding to the step S120 is emphasized. In the present embodiment, the step S120 in fig. 1 selects at least one first statistical region as a reference statistical region based on the luminance component information of each first statistical region and each second statistical region, and further includes steps S201 to S202.
S201: and acquiring the brightness component information difference between each first statistical area and the corresponding second statistical area.
After the luminance component information of each first statistical region and the luminance component information of the second statistical region are calculated and obtained respectively, the luminance component information difference between each first statistical region and the corresponding second statistical region is further obtained. The luminance component information at least includes a luminance statistic value, and it is understood that in other embodiments, the luminance component information may also include other information, which is not illustrated in detail herein. Correspondingly, the luminance component information difference is an absolute value of a difference between the luminance statistic of the first statistical area and the luminance statistic of the second statistical area, and the luminance component information difference can also be understood as a difference between the luminance statistic of the second statistical area and the luminance statistic of the first statistical area.
Specifically, in the present embodiment, the luminance component information difference is equal to the difference of the luminance component information of the second statistical region minus the luminance component information of the first statistical region. For example, when the luminance component information of the first statistical region is denoted as Yc, the luminance component information of the second statistical region is denoted as Yb, and the difference between the luminance component information of the first statistical region and the luminance component information of the corresponding second statistical region is denoted as Ye, it is true that Ye is Yb-Yc in the current embodiment.
In another embodiment, the difference in luminance component information is equal to the absolute value of the difference of the luminance component information of the first statistical region minus the luminance component information of the second statistical region. In the above embodiment, Ye ═ Yc-Yb | holds.
Correspondingly, in step S201, the luminance component difference between each first statistical region and the corresponding second statistical region is calculated, that is, the luminance component difference between each first statistical region and the corresponding second statistical region is calculated. For example, in an embodiment, when the color picture is divided into 32 × 32 first statistical regions (in some embodiments, the first statistical regions may also be defined as blocks), the luminance component information difference between the 32 × 32 first statistical regions and the corresponding second statistical regions in the color picture is calculated in the corresponding step S201.
S202: and selecting at least one first statistical area as a reference statistical area based on the brightness component information difference.
After the difference of the brightness component information between each first statistical area and the corresponding second statistical area is obtained, at least one first statistical area is selected from the color picture as a reference area further based on the calculated difference of the brightness component information. The reference area is a color picture referred to when selecting a trusted statistical area from the color pictures, and in some embodiments, may also be understood as an area used for selecting an untrusted statistical area.
Further, please refer to fig. 3, wherein fig. 3 is a schematic flowchart illustrating a white balance adjustment method according to another embodiment of the present application. In the present embodiment, the steps included in the embodiment corresponding to fig. 2 are emphasized for further description.
In the present embodiment, the step S201 of obtaining the luminance component information difference between each first statistical region and the corresponding second statistical region further includes steps S301 to S302.
S301: and acquiring the brightness statistic value of each first statistic area and the brightness statistic value of each second statistic area.
After acquiring color pictures output by a color acquisition unit and black and white pictures output by a black and white acquisition unit respectively, performing statistical area division on the color pictures and the black and white pictures respectively according to a preset division rule to obtain a first statistical area and a second statistical area, and calculating and acquiring brightness component information of each first statistical area and brightness component information of each second statistical area respectively after calculating attribute information of each statistical area in the color pictures and the black and white pictures. Wherein, the attribute information of each statistical region at least comprises: in the technical scheme provided by the application, the pixel values of the pixel points included in each statistical region are represented by the statistical region as a first statistical region and a second statistical region. It should be noted that, the order of calculating the luminance component information of each first statistical region and calculating the luminance component information of each second statistical region is not limited at all, and may be specifically set based on actual requirements. As in the current embodiment, the luminance statistics of each first statistical area may be calculated first, and then the luminance statistics of each second statistical area may be calculated. In other embodiments, when the hardware configuration parameters may satisfy the parallel calculation, the luminance statistic value of each first statistical area and the luminance statistic value of each second statistical area may be calculated simultaneously.
S302: and acquiring the difference of the brightness statistic value between each first statistic area and the corresponding second statistic area.
After the obtained luminance statistic value of each first statistic region and the obtained luminance statistic value of each second statistic region, a difference between the luminance of each first statistic region and the luminance of the corresponding second statistic region is further obtained. In the current embodiment, the difference between the luminance statistic value of each first statistic area and the luminance statistic value of the corresponding second statistic area may be obtained by subtracting the luminance statistic value of the corresponding first statistic area from the luminance statistic value of the second statistic area. In another embodiment, the luminance statistic of the second statistic area is subtracted from the luminance statistic of the first statistic area, an absolute value of the obtained difference is further obtained, and the absolute value of the difference is output as a difference between the luminance statistic of the first statistic area and the luminance statistic of the corresponding second statistic area.
In the present embodiment, the step S202 of selecting at least one first statistical region as the reference statistical region based on the luminance component information difference further includes a step S303.
S303: and selecting at least one first statistical area with the difference of the brightness statistics values larger than or equal to a first preset threshold value as a reference statistical area.
After the difference between the luminance statistic values of each first statistic area and the corresponding second statistic area is obtained, at least one first statistic area with the difference between the luminance statistic values larger than or equal to a first preset threshold value is further selected to serve as a reference statistic area. The first preset threshold is a brightness difference threshold that is set in advance according to an empirical value and is used for selecting a reference statistical area, and specifically, the first preset threshold may also be an average value of statistical differences between a first statistical area suspected of including infrared light components and a corresponding second statistical area. In another embodiment, the filter may be preset according to the performance of the filter for filtering the light in the infrared band.
Wherein, the brightness statistic value is a brightness average value. Specifically, for the first statistical region or the second statistical region, the luminance statistical value is an average value of the luminances of the respective pixel points included in each statistical region. Therefore, when calculating the luminance statistic value of each statistical region, the luminance of the pixel points included in each statistical region is obtained first, and then the average value of the luminance of the pixel points in the statistical region is obtained based on the luminance of all the pixel points included in each statistical region.
Referring to fig. 4, fig. 4 is a schematic flowchart illustrating a white balance adjustment method according to another embodiment of the present application.
In the present embodiment, the step S130 illustrated in fig. 1 is further described with respect to selecting at least one first statistical region as the trusted statistical region based on the chrominance component information of the reference statistical region. In the current embodiment, the above step S130 further includes the following steps S401 to S403.
S401: chrominance component information for each reference statistical region is obtained.
After at least one first statistical region is selected as a reference statistical region, further acquiring chroma component information of each reference statistical region. Wherein the chrominance component information includes at least a chrominance mean value.
When the format of the color picture is YUV data format, the chrominance component information at least includes the chrominance component UV value, and correspondingly, step S401 may be understood as obtaining the chrominance component UV value of each reference statistical region.
The method comprises the steps of obtaining the chromaticity of each pixel point included in each reference statistical region, then summing the chromaticities of the pixel points included in the current reference statistical region, calculating the average chromaticity value of each pixel point in the reference statistical region, and outputting the obtained average chromaticity value as the chromaticity component information of the current reference statistical region.
S402: based on the chroma component information, an untrusted statistical region is selected from the reference statistical regions.
After the chroma component information of each reference statistical region is obtained, the untrusted statistical region is further selected from the reference statistical regions based on the chroma component information. The untrusted statistical region is a statistical region included in the color picture and not considered when performing white balance calculation.
In an embodiment, the step S402 of selecting an untrusted statistical region from the reference statistical regions based on the chrominance component information further includes: and taking the reference statistical area with the chrominance component information being greater than or equal to a second preset threshold value as an untrusted statistical area. After the chrominance component information is calculated and obtained, whether the obtained chrominance component information is larger than or equal to a second preset threshold value or not is further judged, if yes, the current reference statistical area is judged to be an untrusted statistical area, otherwise, if the obtained chrominance component information is smaller than the second preset threshold value, the current reference statistical area is judged to be a trusted statistical area.
Further, the chrominance component information includes at least a red chrominance component. Correspondingly, the step S402 can also be understood as: and selecting a reference statistical area with the red chroma component value larger than or equal to a second preset threshold value from the reference statistical areas as an untrusted statistical area based on the red chroma component. Correspondingly, in the current embodiment, the second preset threshold is a threshold set based on an empirical value of the red chrominance component, and the number of the untrusted statistical regions is not limited herein, where the number of the untrusted statistical regions may be zero, one, or multiple, and specifically, an actual execution result is taken as a reference, and no limitation is made herein.
S403: and eliminating the distrusted statistical regions in the plurality of first statistical regions, and taking the rest first statistical regions as the trusted statistical regions.
After the untrusted statistical region is determined, the untrusted statistical region is further removed from the plurality of first statistical regions included in the color picture, and the remaining first statistical regions are taken as trusted statistical regions. It should be noted that, in some embodiments, as can be known from the comparison between the chrominance component information of each reference statistical area in step S402 and the second preset threshold, when the chrominance component information of all the reference statistical areas is smaller than the second preset threshold, it is correspondingly determined that there is no untrusted statistical area in the current reference statistical area, and at this time, another untrusted statistical area is removed in step S403, so that all the first statistical areas included in the color picture are used as trusted statistical areas.
Referring to fig. 5, fig. 5 is a schematic flowchart illustrating an embodiment of a white balance adjustment method according to the present application. In the present embodiment, the method provided by the present application, a method for adjusting white balance, includes:
s501: respectively acquiring the color picture output by the color acquisition unit and the black and white picture output by the black and white acquisition unit.
S502: and acquiring the brightness statistic value of each first statistic area and the brightness statistic value of each second statistic area.
S503: and acquiring the difference of the brightness statistic value between each first statistic area and the corresponding second statistic area.
S504: and selecting at least one first statistical area with the difference of the brightness statistics values larger than or equal to a first preset threshold value as a reference statistical area.
S505: chrominance component information for each reference statistical region is obtained.
S506: based on the chroma component information, an untrusted statistical region is selected from the reference statistical regions.
S507: and eliminating the distrusted statistical regions in the plurality of first statistical regions, and taking the rest first statistical regions as the trusted statistical regions.
S508: and carrying out white balance calculation on the trust statistical region to obtain a target gain value.
In the current embodiment, the steps S501 to S508 are the same as the corresponding steps in the embodiments shown in fig. 1 to fig. 4 and corresponding embodiments, and may specifically refer to the description of the corresponding parts above, which is not repeated herein. After the white balance calculation is performed on the trust statistic region in the above step S508 to obtain the target gain value, the method provided by the present application further includes step S509.
S509: and performing gain processing on the color picture by using the target gain value, and performing superposition processing on the color picture and the black and white picture after the gain processing to obtain a target output picture.
After the target gain value is obtained, the target gain value is further used as a coefficient to gain the color, and the gain-processed color picture and the black-and-white picture are subjected to superposition processing to obtain a target output picture.
In another embodiment, step S509 further includes performing gain processing on the black-and-white picture by using the target gain value, then performing superposition processing on the color picture after gain processing and the black-and-white picture after gain processing to obtain a target output picture, and finally outputting the target output picture to realize picture output.
The method provided by the application combines the color road information and the black and white road information in the image acquisition equipment, eliminates the infrared light area which influences the color white balance based on the brightness component information and the chromaticity component information on the difference of the infrared wave band, and avoids the problem of color cast of the white balance under the infrared interference.
The method comprises the steps of fully utilizing different light wave band induction characteristics of an image acquisition device under the same light path of a color path and a black and white path, extracting a first statistical region which meets conditions in a color picture through the difference of brightness component information to serve as a reference statistical region to realize first judgment, then taking the chromaticity characteristics of chromaticity classification information in the reference statistical region on red as the basis of secondary judgment, further selecting an untrusted statistical region from the reference statistical region, further eliminating an infrared light containing statistical region which influences white balance in the process of calculating the white balance, namely obtaining a trusted statistical region for white balance calculation through two times of judgment, and enabling the fusion device to realize the accuracy of the white balance.
Referring to fig. 6, fig. 6 is a schematic structural diagram of an embodiment of an image capturing apparatus according to the present application. In the current embodiment, the image capturing apparatus 600 provided by the present application includes a memory 602, a processor 601, a color capturing unit 603, and a black and white capturing unit 604. The memory 602, the color acquisition unit 603 and the black and white acquisition unit 604 are coupled to the processor 601, respectively.
The color acquisition unit 603 is configured to acquire and obtain a color image, and output the color image to the processor 601. The color collecting unit 603 includes various devices, such as a photoreceptor (not shown) and a beam splitter prism (not shown).
The black and white acquisition unit 604 is configured to acquire a black and white picture and output the black and white picture to the processor 601. The black-and-white collecting unit 604 includes various devices, such as a photoreceptor and a beam splitter prism, and it should be noted that the black-and-white collecting unit 604 and the color collecting unit 603 may share the same beam splitter prism.
The memory 602 includes a local storage (not shown) and stores a computer program, and the computer program can implement the method for adjusting white balance described in any one of the embodiments of fig. 1 to 5 and corresponding embodiments.
A processor 601 is coupled to the memory 602, and the processor 601 is configured to execute a computer program to perform the method of white balance adjustment as described in any one of the embodiments of fig. 1 to 5 and corresponding embodiments.
Further, the type of the image capturing device 600 at least includes a monocular dual-fusion image capturing device, and the structure of the monocular dual-fusion image capturing device may be detailed as set forth in the above corresponding parts, which is not described herein again.
Referring to fig. 7, fig. 7 is a schematic structural diagram of an embodiment of a storage medium according to the present application. The storage medium 700 stores a computer program 701 capable of being executed by a processor, and the computer program 701 is used for implementing the method for adjusting the white balance as described in any one of the embodiments of fig. 1 to 5 and corresponding embodiments. Specifically, the storage medium 700 may be one of a memory, a personal computer, a server, a network device, or a usb disk, and is not limited in any way herein.
The above description is only for the purpose of illustrating embodiments of the present application and is not intended to limit the scope of the present application, and all modifications of equivalent structures and equivalent processes, which are made by the contents of the specification and the drawings of the present application or are directly or indirectly applied to other related technical fields, are also included in the scope of the present application.

Claims (10)

1. A method of white balance adjustment, applied to an image pickup apparatus including a color pickup unit and a black-and-white pickup unit, the method comprising:
respectively acquiring a color picture output by the color acquisition unit and a black and white picture output by the black and white acquisition unit; the color picture comprises a plurality of first statistical areas, the black-and-white picture comprises a plurality of second statistical areas, and the second statistical areas and the first statistical areas are divided correspondingly;
selecting at least one first statistical area as a reference statistical area based on the brightness component information of each first statistical area and the second statistical area;
selecting at least one first statistical area as a trust statistical area based on the chrominance component information of the reference statistical area;
and performing white balance calculation on the trust statistical region to obtain a target gain value.
2. The method according to claim 1, wherein the selecting at least one first statistical region as a reference statistical region based on the luminance component information of each of the first statistical region and the second statistical region comprises:
acquiring brightness component information difference between each first statistical area and the corresponding second statistical area;
and selecting at least one first statistical area as a reference statistical area based on the brightness component information difference.
3. The method of claim 2, wherein obtaining the difference in luminance component information between each of the first statistical regions and the corresponding second statistical region comprises:
acquiring a brightness statistic value of each first statistic area and a brightness statistic value of each second statistic area;
acquiring the difference of the brightness statistic value between each first statistic area and the corresponding second statistic area;
selecting at least one first statistical region as a reference statistical region based on the luminance component information difference, including:
and selecting at least one first statistical area with the difference of the brightness statistics values larger than or equal to a first preset threshold value as the reference statistical area.
4. The method of claim 3, wherein the luminance statistic is a luminance average.
5. The method of claim 1, wherein the selecting at least one of the first statistical regions as a trusted statistical region based on the chroma component information of the reference statistical region further comprises:
acquiring chrominance component information of each reference statistical area;
selecting an untrusted statistical region from the reference statistical region based on the chroma component information;
and eliminating the distrust statistical areas in the plurality of first statistical areas, and taking the rest first statistical areas as the trust statistical areas.
6. The method of claim 5, wherein selecting an untrusted statistical region from the reference statistical regions based on the chroma component information further comprises:
and taking the reference statistical area with the chrominance component information being greater than or equal to a second preset threshold value as the distrusted statistical area.
7. The method according to claim 1, wherein the format of the color picture comprises any one of YUV data format, LAB data format, HSV data format, and HSL data format.
8. The method of claim 1, wherein after the white balance calculation of the confidence statistic region to obtain a target gain value, the method further comprises:
and performing gain processing on the color picture by using the target gain value, and performing superposition processing on the color picture and the black and white picture after the gain processing to obtain a target output picture.
9. An image acquisition device, characterized in that the device comprises a memory, a processor, a color acquisition unit and a black and white acquisition unit, the memory, the color acquisition unit and the black and white acquisition unit being coupled to the processor, respectively, wherein,
the color acquisition unit is used for acquiring a color picture and outputting the color picture to the processor;
the black and white acquisition unit is used for acquiring black and white pictures and outputting the black and white pictures to the processor;
the memory stores a computer program;
the processor is configured to run the computer program to perform the method of any one of claims 1 to 8.
10. A storage medium, characterized in that it stores a computer program executable by a processor, the computer program being adapted to implement the method of any one of claims 1 to 8.
CN202010866320.0A 2020-08-25 2020-08-25 White balance adjustment method, image acquisition device and storage medium Active CN112055191B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010866320.0A CN112055191B (en) 2020-08-25 2020-08-25 White balance adjustment method, image acquisition device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010866320.0A CN112055191B (en) 2020-08-25 2020-08-25 White balance adjustment method, image acquisition device and storage medium

Publications (2)

Publication Number Publication Date
CN112055191A true CN112055191A (en) 2020-12-08
CN112055191B CN112055191B (en) 2022-08-09

Family

ID=73600992

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010866320.0A Active CN112055191B (en) 2020-08-25 2020-08-25 White balance adjustment method, image acquisition device and storage medium

Country Status (1)

Country Link
CN (1) CN112055191B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1835600A (en) * 2005-03-14 2006-09-20 华宇电脑股份有限公司 White balance method
CN1941923A (en) * 2005-09-30 2007-04-04 八方科技股份有限公司 Automatic white balance method for color digital image
JP2011139489A (en) * 2011-02-02 2011-07-14 Eastman Kodak Co Apparatus for adjusting white balance, and apparatus for identifying color
CN102469243A (en) * 2010-11-04 2012-05-23 卡西欧计算机株式会社 Image capturing apparatus capable of adjusting white balance
CN105827990A (en) * 2016-01-22 2016-08-03 维沃移动通信有限公司 Automatic exposure method and mobile terminal
CN106454305A (en) * 2016-11-14 2017-02-22 浙江宇视科技有限公司 White balance correcting method and device
CN107911620A (en) * 2017-12-28 2018-04-13 努比亚技术有限公司 Definite method, terminal and the computer-readable recording medium of a kind of white balance
CN107959841A (en) * 2017-12-07 2018-04-24 广东欧珀移动通信有限公司 Image processing method, device, storage medium and electronic equipment
CN108600725A (en) * 2018-05-10 2018-09-28 杭州雄迈集成电路技术有限公司 A kind of white balance correction device and method based on RGB-IR image datas

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1835600A (en) * 2005-03-14 2006-09-20 华宇电脑股份有限公司 White balance method
CN1941923A (en) * 2005-09-30 2007-04-04 八方科技股份有限公司 Automatic white balance method for color digital image
CN102469243A (en) * 2010-11-04 2012-05-23 卡西欧计算机株式会社 Image capturing apparatus capable of adjusting white balance
JP2011139489A (en) * 2011-02-02 2011-07-14 Eastman Kodak Co Apparatus for adjusting white balance, and apparatus for identifying color
CN105827990A (en) * 2016-01-22 2016-08-03 维沃移动通信有限公司 Automatic exposure method and mobile terminal
CN106454305A (en) * 2016-11-14 2017-02-22 浙江宇视科技有限公司 White balance correcting method and device
CN107959841A (en) * 2017-12-07 2018-04-24 广东欧珀移动通信有限公司 Image processing method, device, storage medium and electronic equipment
CN107911620A (en) * 2017-12-28 2018-04-13 努比亚技术有限公司 Definite method, terminal and the computer-readable recording medium of a kind of white balance
CN108600725A (en) * 2018-05-10 2018-09-28 杭州雄迈集成电路技术有限公司 A kind of white balance correction device and method based on RGB-IR image datas

Also Published As

Publication number Publication date
CN112055191B (en) 2022-08-09

Similar Documents

Publication Publication Date Title
US10742889B2 (en) Image photographing method, image photographing apparatus, and terminal
US9344689B2 (en) Camera system with multi-spectral filter array and image processing method thereof
WO2019148912A1 (en) Image processing method, apparatus, electronic device and storage medium
CN106911876B (en) Method and apparatus for outputting image
US8948505B2 (en) Image processing apparatus, image processing method, program and imaging apparatus
US20070047803A1 (en) Image processing device with automatic white balance
US10102787B2 (en) Image signal processing apparatus and control method therefor
US8165396B2 (en) Digital image editing system and method for combining a foreground image with a background image
US20090161982A1 (en) Restoring images
EP3855387A1 (en) Image processing method and apparatus, electronic device, and readable storage medium
CN111369486B (en) Image fusion processing method and device
CN113132695B (en) Lens shading correction method and device and electronic equipment
CN114693580B (en) Image processing method and related device
CN104660905A (en) Shooting processing method and device
CN108174173B (en) Photographing method and apparatus, computer-readable storage medium, and computer device
CN109729259B (en) Image processing apparatus, method thereof, system thereof, and computer readable medium
US20210049427A1 (en) Image processing apparatus, image processing method, and image processing system
CN112055191B (en) White balance adjustment method, image acquisition device and storage medium
CN116309224A (en) Image fusion method, device, terminal and computer readable storage medium
CN116668862B (en) Image processing method and electronic equipment
WO2023151210A1 (en) Image processing method, electronic device and computer-readable storage medium
WO2022067761A1 (en) Image processing method and apparatus, capturing device, movable platform, and computer readable storage medium
CN103167183B (en) Translucent camera aperture processing method, system and mobile terminal
CN109447925B (en) Image processing method and device, storage medium and electronic equipment
CN113487497A (en) Image processing method and device and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant