WO2022116989A1 - Image processing method and apparatus, and device and storage medium - Google Patents

Image processing method and apparatus, and device and storage medium Download PDF

Info

Publication number
WO2022116989A1
WO2022116989A1 PCT/CN2021/134713 CN2021134713W WO2022116989A1 WO 2022116989 A1 WO2022116989 A1 WO 2022116989A1 CN 2021134713 W CN2021134713 W CN 2021134713W WO 2022116989 A1 WO2022116989 A1 WO 2022116989A1
Authority
WO
WIPO (PCT)
Prior art keywords
image
brightness
target
correction coefficient
brightness correction
Prior art date
Application number
PCT/CN2021/134713
Other languages
French (fr)
Chinese (zh)
Inventor
苏坦
Original Assignee
影石创新科技股份有限公司
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 影石创新科技股份有限公司 filed Critical 影石创新科技股份有限公司
Publication of WO2022116989A1 publication Critical patent/WO2022116989A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N25/00Circuitry of solid-state image sensors [SSIS]; Control thereof
    • H04N25/50Control of the SSIS exposure
    • H04N25/57Control of the dynamic range
    • 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
    • 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
    • H04N23/71Circuitry for evaluating the brightness variation
    • 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
    • H04N23/76Circuitry for compensating brightness variation in the scene by influencing the image signals

Definitions

  • the present application relates to the technical field of image processing, and in particular, to an image processing method, apparatus, device and storage medium.
  • the dynamic range of the display device that often needs to display images is limited dynamic range or low dynamic range, and low dynamic range is relative to high dynamic range, for example, CRT (Cathode Ray Tube) display, LCD display or Projectors, etc., have limited dynamic range.
  • CRT Cathode Ray Tube
  • LCD display or Projectors etc.
  • high dynamic range images need to be displayed on the above-mentioned limited dynamic range devices.
  • the high dynamic Displays the same effect as HDR on display devices with limited dynamic range.
  • the present invention provides an image processing method, the method comprising:
  • the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located;
  • the determining of the target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value includes at least one of the following steps:
  • the target brightness correction coefficient includes a first brightness correction coefficient
  • the determining the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value includes:
  • logarithm calculation is performed to obtain a first luminance correction coefficient, wherein the base of the logarithmic function is greater than 1.
  • the target brightness correction coefficient further includes a second brightness correction coefficient and a third brightness correction coefficient; the target brightness correction coefficient is determined according to the target brightness statistics value and the image brightness statistics value:
  • the performing brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image includes:
  • the performing pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image includes:
  • Fusion processing is performed on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a target dynamic image.
  • the described first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are fused to obtain the target dynamic image including:
  • Tone-mapping processing is performed on the first dynamic image according to the local mapping gain value to obtain a target dynamic image.
  • the obtaining a statistical value of the ambient light intensity includes:
  • the parameter ratio is used as the true number of the logarithmic function to perform logarithmic calculation to obtain a statistical value of the ambient light intensity, wherein the base of the logarithmic function is greater than 1.
  • the present invention provides an image processing device, the device comprising:
  • a first dynamic image acquisition module configured to acquire the first dynamic image to be processed
  • an image brightness statistical value acquisition module configured to acquire an image brightness statistical value corresponding to the first dynamic image
  • a target brightness statistical value acquisition module configured to acquire a statistical value of ambient light intensity, and obtain a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity
  • a target brightness correction coefficient determination module configured to determine a target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value
  • a target brightness correction image determination module configured to perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image
  • the target dynamic image determination module is used for performing pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image.
  • the target brightness correction coefficient determination module includes at least one of the following units:
  • a brightness enhancement coefficient obtaining unit configured to obtain a brightness enhancement coefficient as a target brightness correction coefficient when the target brightness statistic value is greater than the image brightness statistic value
  • a brightness reduction coefficient obtaining unit configured to obtain a brightness reduction coefficient as a target brightness correction coefficient when the target brightness statistic value is less than the image brightness statistic value.
  • the present invention provides a computer device, comprising a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
  • the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located;
  • the present invention provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
  • the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located;
  • the image brightness statistical value of the first dynamic image is acquired; by acquiring the ambient light intensity statistical value, according to the ambient light intensity statistical value Obtain the target brightness statistics value corresponding to the shooting environment, determine the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value, and perform brightness correction on the first dynamic image through the target brightness correction coefficient to obtain the target brightness correction image.
  • the correction coefficient of the image can be determined according to the ambient light intensity, and the brightness of the first dynamic image can be corrected by using the correction coefficient, so that an image with suitable brightness and more details can be obtained.
  • the target dynamic image is obtained by performing pixel dynamic range mapping on the target brightness correction image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image, thereby realizing the conversion from a high dynamic image to a low dynamic image.
  • Fig. 1 is the application environment diagram of the image processing method in one embodiment
  • FIG. 2 is a schematic flowchart of an image processing method in one embodiment
  • FIG. 3 is a schematic flowchart of a step of determining a target brightness correction coefficient according to a target brightness statistic value and an image brightness statistic value in another embodiment
  • FIG. 4 is a schematic flowchart of a method for obtaining a target dynamic image by performing fusion processing on a first mapping dynamic image, a second mapping dynamic image, and a third mapping dynamic image in another embodiment
  • FIG. 5 is a schematic flowchart of obtaining a statistical value of ambient light intensity in another embodiment
  • FIG. 6 is a schematic diagram of a normal image in one embodiment
  • FIG. 7 is a schematic diagram of a darker image in one embodiment
  • FIG. 8 is a schematic diagram of a brighter image in one embodiment
  • FIG. 9 is a structural block diagram of an image processing apparatus in one embodiment
  • Figure 10 is a diagram of the internal structure of a computer device in one embodiment.
  • the image processing method provided in this application can be applied to the application environment shown in FIG. 1 .
  • the application environment includes an image capturing device 102 and a terminal 104 , wherein the image capturing device 102 and the terminal 104 are connected in communication.
  • the image acquisition device 102 collects the dynamic image, it transmits it to the terminal 104.
  • the terminal 104 acquires the first dynamic image to be processed, and the terminal 104 can acquire the image brightness statistics value and the environment corresponding to the first dynamic image through the acquired first dynamic image.
  • the statistical value of light intensity, according to the statistical value of ambient light intensity, the statistical value of target brightness corresponding to the shooting environment is obtained; wherein, the statistical value of ambient light intensity is the statistical value of light intensity of the shooting environment where the first dynamic image is located; the terminal 104 is based on the statistical value of target brightness and the statistical value of light intensity of the shooting environment.
  • the image brightness statistics value determines the target brightness correction coefficient; performs brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain the target brightness correction image; performs pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image.
  • the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image.
  • the image capturing device 102 may be, but is not limited to, various devices having an image capturing function, and may be distributed outside the terminal 104 or inside the terminal 104 .
  • various cameras, scanners, various cameras, and image capture cards distributed outside the terminal 104 may be, but is not limited to, various cameras, personal computers, notebook computers, smart phones, tablet computers, and portable wearable devices.
  • an image processing method is provided, and the method is applied to the terminal in FIG. 1 as an example for description, including the following steps:
  • Step 202 acquiring the first dynamic image to be processed.
  • the dynamic image refers to a dynamic range image
  • the dynamic range image refers to an image whose brightness is within a certain range.
  • Dynamic range images are classified into high dynamic range images (High-Dynamic Range, HDR), low dynamic range images or limited dynamic range images.
  • the image processing instruction carries the image identifier of the image to be processed, and through the image identifier, the terminal can obtain the first dynamic image to be processed from the stored image.
  • the terminal acquires the first dynamic image to be processed so as to perform subsequent processing work on the first dynamic image.
  • the first dynamic image may be acquired by a acquisition device having a dynamic range image acquisition function.
  • the terminal may be an image to be displayed, and as the first dynamic image to be processed, the terminal may directly perform image processing on the displayed image.
  • the first dynamic image may be obtained by synthesizing images with different exposures. Images with different exposures have different brightness. Appropriate exposure will make the image have appropriate brightness and more image details. Images with too low exposure or too high exposure will lose image details.
  • Step 204 Acquire a statistical value of image brightness corresponding to the first dynamic image.
  • the statistical value of image brightness refers to the comprehensive quantitative performance of image brightness, and the overall situation of image brightness can be obtained from the statistical value of image brightness.
  • the terminal After acquiring the first dynamic image, the terminal obtains a brightness histogram by converting the first dynamic image into a grayscale image and statistics. to the average brightness of the first moving image.
  • Step 206 Obtain a statistical value of ambient light intensity, and obtain a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity; the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located.
  • the statistical value of the ambient light intensity refers to the comprehensive quantitative performance of the ambient light intensity.
  • the overall situation of the ambient light intensity can be known through the statistical value of the ambient light intensity.
  • the statistical value is obtained through statistics, such as the average or the median. .
  • the terminal can obtain the corresponding value of the statistical value of ambient light intensity according to the corresponding relationship between the statistical value of ambient light intensity and the statistical value of target brightness. target brightness statistics.
  • the exposure parameter can be obtained according to the sensitivity, shutter speed and aperture value, and the statistical value of the image brightness is divided by the exposure parameter as the true number of the logarithmic function, and the logarithmic calculation is performed to obtain the statistical value of the ambient light intensity.
  • the statistical value of ambient light intensity is expressed as EE
  • the statistical value of image brightness is expressed as V0
  • the statistical value of target brightness is expressed as V
  • I is the sensitivity
  • s the shutter speed in seconds
  • a is the aperture value
  • the statistical value of ambient light intensity is related to the image.
  • the relationship between the luminance statistics can be expressed as:
  • Different statistical values of ambient light intensity have different statistical values of target brightness. Assuming that the statistical value of target brightness is V, there is a one-to-one correspondence between the statistical value of ambient light intensity EE and the statistical value of target brightness V. It is understandable that images taken under different ambient light intensities have different image brightness that the user likes. For example, for photos taken in sunny days with sufficient light, people prefer brighter pictures, so the target brightness statistic value V corresponding to the ambient light intensity statistic value EE is too large, and for images taken outdoors at night, the appropriate brightness The target brightness statistic value V corresponding to the ambient light intensity statistic value EE of the image is relatively small.
  • f there is a one-to-one correspondence between the statistical value of ambient light intensity EE and the statistical value of target brightness V, which may be denoted as f.
  • EE the statistical value of ambient light intensity
  • V target brightness
  • f the statistical value of target brightness V
  • Table 1 The mapping table between the statistical value of ambient light intensity and the statistical value of target brightness
  • the numerical relationship between different ambient light intensity statistics EE and the corresponding target brightness statistics V can be obtained, and the numerical relationship is unique.
  • the target brightness statistic V can be expressed as f(EE)
  • the target brightness statistic f(EE) under a certain illumination intensity can be adjusted by adjusting the value in this correspondence, so that the Images can be made lighter or darker.
  • Step 208 Determine the target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value.
  • the brightness correction coefficient is a coefficient for performing brightness correction on the image.
  • the image can be adjusted to the appropriate brightness through the brightness correction coefficient, such as brightening or darkening.
  • the terminal After the terminal has obtained the statistical value of target brightness and the statistical value of image brightness, through the functional relationship between the statistical value of target brightness and the statistical value of image brightness, for example, there is a ratio between the statistical value of target brightness and the statistical value of image brightness
  • the type of functional relationship can determine the target brightness correction coefficient.
  • the statistical value of target brightness is expressed as f(EE)
  • the statistical value of image brightness is expressed as V0
  • the target brightness correction is obtained through the functional relationship between the target brightness correction coefficient, the target brightness statistical value and the image brightness statistical value.
  • the target luminance correction coefficient is ⁇
  • Step 210 Perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness corrected image.
  • the terminal performs brightness correction on the first dynamic image according to the determined target brightness correction coefficient, and acquires the corrected first dynamic image as the target brightness correction image.
  • a pixel value after brightness correction can be obtained by multiplying each pixel value of the first dynamic image by a target brightness correction coefficient, and an image composed of the corrected pixel values is a target brightness correction image.
  • the brightness correction of the first dynamic image may be performed directly by using the target brightness correction coefficient, so that the image brightness statistical value of the corrected first dynamic image is close to the target brightness statistical value. For example, assuming that the value of each pixel in the first dynamic image is X, and using the target brightness correction coefficient e1 to correct the brightness of the first dynamic image, the obtained pixel value of the corresponding position of the target brightness corrected image is X*e1; A final correction coefficient is obtained by calculating a function having a corresponding relationship with the target brightness correction coefficient, and brightness correction is performed on the first moving image by using the final correction coefficient.
  • the function related to the target brightness correction coefficient is an exponential function
  • the brightness correction coefficient can be used as an exponent
  • the preset value is used as the base to perform exponential calculation
  • the preset value is a number greater than 1. For example, assuming that the preset value is 2, the final obtained correction coefficient is 2 e1 , and the obtained pixel value of the corresponding position of the target brightness corrected image is X*2 e1 .
  • Step 212 Perform pixel dynamic range mapping on the target brightness correction image to obtain a target dynamic image, where the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image.
  • dynamic range mapping refers to mapping an image from one dynamic range to another dynamic range.
  • the pixel dynamic range of the first dynamic image is larger than the pixel dynamic range of the target dynamic image.
  • the target brightness correction image obtained by the terminal needs to be subjected to the pixel dynamic range.
  • Mapping converts high dynamic images into low dynamic images, so that the mapped images can adapt to low dynamic display devices.
  • the target brightness correction image at this time is still a high dynamic image, which needs to be converted into a low dynamic image by dynamic range mapping images, so that low-motion images can be used as target motion images for low-motion devices.
  • the transformation from a high dynamic image to a low dynamic image can be achieved using a gamma transform. For example, converting from a high-motion image with pixel values ranging from 0 to 65535 to a low-motion image with pixel values ranging from 0 to 255.
  • the image brightness statistics value of the first dynamic image is acquired; by acquiring the ambient light intensity statistics value, the target brightness corresponding to the shooting environment is acquired according to the ambient light intensity statistics value.
  • the target brightness correction coefficient is determined according to the target brightness statistical value and the image brightness statistical value, and the brightness correction is performed on the first dynamic image through the target brightness correction coefficient to obtain a target brightness correction image.
  • the correction coefficient of the image can be determined according to the ambient light intensity, and the brightness of the first dynamic image can be corrected by using the correction coefficient, so that an image with suitable brightness and more details can be obtained.
  • the target dynamic image is obtained by performing pixel dynamic range mapping on the target brightness correction image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image, thereby realizing the conversion from a high dynamic image to a low dynamic image.
  • the image correction coefficient is determined by the ambient light intensity and the statistical value of the image brightness when the image is taken, and the image is corrected by the image correction coefficient. To the image processing process of low dynamic images, more image details are preserved and the image processing effect is improved.
  • determining the target brightness correction coefficient according to the target brightness statistical value and the image brightness statistical value includes at least one of the following steps: when the target brightness statistical value is greater than the image brightness statistical value, acquiring a brightness enhancement coefficient as the target brightness correction coefficient ; When the target brightness statistic value is less than the image brightness statistic value, obtain the brightness reduction coefficient as the target brightness correction coefficient.
  • the brightness enhancement coefficient enhances the brightness.
  • the target brightness correction coefficient will enhance the brightness of the image.
  • the target brightness correction coefficient at this time may be called a brightness enhancement coefficient.
  • the brightness enhancement coefficient can enhance the image brightness linearly or nonlinearly.
  • the brightness enhancement coefficient and the brightness reduction coefficient may be preset, or may be calculated by a preset algorithm. For example, the brightness ratio between the target brightness statistic and the image brightness statistic can be calculated; the brightness ratio is used as the true number in the logarithmic function to perform logarithmic calculation to obtain the first brightness correction coefficient, where the base of the logarithmic function is greater than 1.
  • f(EE)/V0 When the statistical value of target brightness is greater than the statistical value of image brightness, f(EE)/V0 is a positive number greater than 1, at this time e is a positive number greater than 0, then ⁇ is a positive number greater than 1, multiply ⁇ by the The pixel value will increase the brightness. At this time, e can be called the brightness enhancement coefficient, and the brightness of the image can be enhanced and adjusted.
  • f(EE)/V0 is a positive number less than 1, and e is a negative number less than 0, then ⁇ is a positive number less than 1, and e can be called brightness Decrease the coefficient to decrease the brightness of the image.
  • the purpose of determining the target brightness coefficient can be achieved through the target brightness statistical value and the image brightness statistical value, and the brightness of the image can be enhanced or attenuated by using the target brightness coefficient.
  • the target brightness correction coefficient includes a first brightness correction coefficient
  • determining the target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value includes: calculating the brightness ratio of the target brightness statistic value and the image brightness statistic value; The ratio is used as the true number in the logarithmic function to perform logarithmic calculation to obtain the first brightness correction coefficient.
  • the terminal may obtain the first brightness correction coefficient through the statistical value of target brightness and the statistical value of image brightness, for example, firstly calculate the brightness ratio of the statistical value of target brightness to the statistical value of image brightness.
  • the statistical value of target brightness is expressed as f(EE)
  • the statistical value of image brightness is V0
  • the calculated ratio is expressed as a
  • the first luminance correction coefficient can be expressed as e1, wherein the base of the logarithmic function is greater than 1.
  • e1 is a logarithmic function with an integer base as the base, and e1 can vary with the change of the true number of the logarithmic function.
  • the luminance ratio is positively correlated with the first luminance correction coefficient
  • the first luminance correction coefficient is obtained by calculating the luminance ratio between the target luminance statistical value and the image luminance statistical value, such that The brightness ratio reflects the magnitude relationship between the target brightness statistic value and the image brightness statistic value.
  • the first brightness enhancement coefficient is the brightness enhancement coefficient.
  • the first brightness enhancement coefficient is a brightness reduction coefficient. Therefore, the adjusted image is matched with the ambient brightness where the shooting environment is located.
  • the target brightness correction coefficient further includes a second brightness correction coefficient and a third brightness correction coefficient; and determining the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value includes:
  • Step 302 reducing the first brightness correction coefficient to obtain a second brightness correction coefficient.
  • the first brightness correction coefficient may be reduced based on the first brightness correction coefficient, and the second brightness correction coefficient may be obtained.
  • reducing the first luminance correction coefficient may be in the form of reducing the corresponding coefficient value.
  • Step 304 performing an increase process on the first brightness correction coefficient to obtain a third brightness correction coefficient.
  • the first brightness correction coefficient may be increased based on the first brightness correction coefficient, and the third brightness correction coefficient may be obtained.
  • the process of increasing the first luminance correction coefficient may be in the form of increasing the corresponding coefficient value.
  • Step 306 Perform brightness correction on the first dynamic image according to the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient, respectively, to obtain a first brightness correction image and a second brightness correction image obtained by modifying the first brightness correction coefficient.
  • the terminal uses the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient to modify the first dynamic image respectively.
  • a first brightness corrected image, a second brightness corrected image and a third brightness corrected image are obtained.
  • the first brightness correction coefficient is used as the target correction coefficient
  • the corresponding first brightness correction image is used as the target correction image.
  • the second brightness correction image is the correction image corresponding to the reduction of the brightness correction coefficient
  • the second brightness correction is a darker image; similarly, the third brightness corrected image is a brighter image.
  • the third brightness correction coefficient when the first brightness correction coefficient is large, can be configured to be closer to the first brightness correction coefficient; when the first brightness correction coefficient is small, the second brightness correction coefficient can be configured to be closer to at the first brightness correction coefficient. Therefore, the details of each brightness level in the picture can be better balanced, so that the image corrected by the correction coefficient can reflect more details of the target image.
  • Step 308 Perform pixel dynamic range mapping on the first brightness-corrected image, the second brightness-corrected image, and the third brightness-corrected image, respectively, to obtain a first mapped dynamic image corresponding to the first brightness-corrected image, and a first mapped dynamic image corresponding to the second brightness-corrected image.
  • the second mapping dynamic image and the third mapping dynamic image corresponding to the third brightness correction image are performed by Step 308.
  • pixel dynamic range mapping may be performed on the first brightness-corrected image, the second brightness-corrected image, and the third brightness-corrected image by means of gamma transformation, to obtain the first mapping dynamic range corresponding to the first brightness-corrected image.
  • the image, the second mapping dynamic image corresponding to the second brightness correction image, and the third mapping dynamic image corresponding to the third brightness correction image are transformed into a low-dynamic-range mapped dynamic image, and a low-dynamic-range mapped dynamic image with different brightness is obtained.
  • the low dynamic range image may be an eight-bit low dynamic range image
  • the high dynamic correction image may be a sixteen-bit high dynamic range image
  • the high dynamic range image has three channels of red, green and blue
  • the pixel value range is An image between 0 and 65535
  • a low dynamic range image is an image with three channels of red, green and blue
  • the pixel value range is between 0 and 255.
  • Step 310 Perform fusion processing on the first mapping dynamic image, the second mapping dynamic image, and the third mapping dynamic image to obtain a target dynamic image.
  • the fusion processing refers to the fusion of images with different brightness according to a certain image fusion method, so that the processed image has richer image details.
  • the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are down-sampled; according to the down-sampled first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image, obtain the first weight map corresponding to the first mapped dynamic image, the second weight map corresponding to the second mapped dynamic image, and the third weight map corresponding to the third mapped dynamic image; the down-sampled first mapped dynamic image,
  • the second mapping dynamic image and the third mapping dynamic image are converted into grayscale images respectively, and multi-resolution fusion is performed on the three grayscale images and the first weight map, the second weight map and the third weight map to obtain multi-resolution rate fusion grayscale image; according to this grayscale image, and the down-sampled first mapping dynamic image, second mapping dynamic image and third mapping dynamic image are converted into three grayscale images and the first weight map, the third
  • new weight maps are obtained by the following formulas, which are the fourth weight map, the fifth weight map and the sixth weight map, respectively
  • the new weight map is represented as wi '
  • the first weight map, the second weight map and the third weight map are represented as w i , where i ⁇ (1,2,3)
  • multi-resolution fusion
  • the grayscale image is represented as If, and the grayscale images converted from the first mapping dynamic image, the second mapping dynamic image, and the third mapping dynamic image are respectively represented as I 1 , I 2 , and I 3 , then the new weight map Expressed as w i ', it can be obtained by the following formula:
  • I f ' w 1 I 1 +w 2 I 2 +w 3 I 3 ,i ⁇ (1,2,3)
  • the fourth weight map, the fifth weight map and the sixth weight map After up-sampling the new weight map, the fourth weight map, the fifth weight map and the sixth weight map respectively, it forms the same size as the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image. After weighted fusion of the fourth weight map, the fifth weight map and the sixth weight map with the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image, the final fused target is obtained dynamic images. It can be understood that the above-mentioned image fusion method can use other fusion methods that can achieve the same effect.
  • the multi-resolution fusion method can also adopt the multi-resolution fusion method of biorthogonal wavelet transform, which can utilize the redundant and complementary information of multiple images, so that the fused image can contain more abundant and comprehensive information. information.
  • the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image may be fused by the Laplacian pyramid weighted fusion method to obtain the target dynamic image.
  • the second brightness correction coefficient and the third brightness correction coefficient are respectively obtained by using the first brightness correction coefficient
  • the first brightness correction image, the second brightness correction image and the third brightness correction image are obtained by using the above three correction coefficients. image, and obtain the corresponding mapping dynamic image through the first brightness correction image, the second brightness correction image and the third brightness correction image, and fuse the above three mapping dynamic images to obtain the target dynamic image.
  • the images with higher brightness use the value of the image with lower brightness more
  • the image with lower brightness uses the value of the image with higher brightness more, so that the target dynamic image can be The purpose of preserving more image details and improving the image processing effect.
  • performing fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain the target dynamic image includes:
  • Step 402 Perform fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a fusion processed image.
  • the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are respectively used for fusion processing to obtain a fusion processed image.
  • the first mapping dynamic image, the second mapping dynamic image, and the third mapping dynamic image are respectively low dynamic images with pixel values between 0 and 255, and fusion processing is performed on the above three mapping dynamic images Afterwards, the obtained fusion image is also a low dynamic image with pixel values between 0 and 255.
  • Step 404 acquiring the image area of the fusion-processed image.
  • the fusion-processed image retains the highlights and shadow details in the high dynamic range image
  • some highlight areas that originally have color information such as colored signboard light boxes
  • the corrected images after different brightness corrections will appear due to highlight truncation. different color.
  • a brighter image will be overexposed due to brightness correction, causing the image to turn white. Therefore, the image obtained by the fusion processing method often has a color cast in the highlight color.
  • the image area may be a partial area of the fused image, or may be the entire area of the fused image.
  • Step 406 obtaining a reference image area.
  • the size of the fused image is the same as that of the second mapped dynamic image.
  • the second mapped dynamic image there is an image area corresponding to the fused image, and a reference image area is obtained.
  • the reference image area may be a partial area in the second mapped dynamic image, or may be the entire area in the second mapped dynamic image.
  • Step 408 Calculate the local mapping gain value of the image region of the fused image relative to the reference image region.
  • the local mapping gain value means that the mapping value is the mapping gain value corresponding to the image area.
  • the local mapping gain value is subjected to inverse gamma transformation between the image region in the fused image and the reference image region in the second mapped dynamic image, and the ratio calculation is performed on the two luminance values after the inverse gamma transformation to obtain The linear gain value of the luminance value of each pixel of the fused image relative to the luminance value of the corresponding pixel of the second mapped dynamic image.
  • each of the fused images can be obtained.
  • Step 410 Perform tone mapping processing on the first dynamic image according to the local mapping gain value to obtain a target dynamic image.
  • tone mapping is performed on the first dynamic image, and after gamma transformation is performed, the first dynamic image is converted into an eight-bit low dynamic range image with a pixel value between 0 and 255.
  • the product of the pixel value of the to-be-processed image region of the first dynamic image and the second luminance coefficient correction coefficient corresponding to the corresponding second mapped dynamic image pixel is multiplied by the local mapping gain value of the corresponding pixel position. Operation, and then perform gamma transformation on the pixel value after the gain, and convert it into an eight-bit low-dynamic target dynamic image with a pixel value between 0 and 255. After the above processing, more details of the image can be preserved, the effect of image processing can be improved, and the color of highlights can be more accurate.
  • the pixel value after the gain exceeds the preset pixel value, it is limited to the preset pixel value.
  • the preset pixel value is limited to 65535
  • the part of the pixel value after the gain that exceeds 65535 is limited to 65535.
  • the fusion processing image is obtained by using the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image, and the to-be-processed image area in the fusion processing image can be processed by using the local mapping gain value.
  • the fused image is then subjected to gamma change to obtain a target dynamic image, which can achieve a target image with more image details preserved after image processing.
  • obtaining a statistical value of ambient light intensity includes:
  • Step 502 Acquire the sensitivity, shutter speed and aperture value corresponding to the first dynamic image.
  • the sensitivity refers to the sensitivity of the camera to light when the first dynamic image is acquired. If the sensitivity is too high, the image quality will be affected. Although the brightness of the acquired image will be bright, the sensitivity will be too high if the sensitivity is too high. More noise; shutter speed refers to the opening time of the shutter when using the camera to capture images. The faster the shutter speed, the shorter the opening time, the less light entering the camera, and the darker the image; conversely, the slower the shutter speed, the longer the opening time. The longer, the more light entering the camera, the brighter the image.
  • the aperture value refers to the relative value of the light passing through the camera lens. The smaller the aperture value, the greater the amount of light entering in the same unit time; conversely, the larger the aperture value, the greater the amount of light entering in the same unit time.
  • the statistical value of ambient light intensity has a functional relationship with the sensitivity, shutter speed, and aperture value. To obtain the statistical value of ambient light intensity, it is necessary to first obtain the above-mentioned parameters of sensitivity, shutter speed, and aperture value.
  • Step 504 obtaining a first parameter value according to the sensitivity, shutter speed and aperture value.
  • the first parameter value is obtained through the sensitivity, shutter speed and aperture value. Since the shutter speed is doubled, for example, press 1 second, 1/2 second, 1 /4 second, 1/8 second sequence, the light flux of the lens will be reduced by half; each time the aperture value increases by one stop, for example, 1.4, 2.0, 4.0, 5.6, 8.0, etc., the light flux will also be reduced by half; the shutter speed is based on When the multiple is increased or decreased, the aperture value is multiplied or decreased according to the square root of the fixed value; when the sensitivity is doubled, the amount of light transmitted is reduced by half. Underexposure can be adjusted by setting a larger aperture, slower shutter speed and higher sensitivity value. Avoid overexposure, which can be adjusted by setting a smaller aperture, faster shutter speed and lower ISO value.
  • the first parameter value can be represented by a formula, and the formula includes sensitivity, shutter speed and aperture value.
  • the sensitivity is expressed as I
  • the shutter speed is expressed as s
  • the aperture value is expressed as a
  • the first parameter value is expressed as c
  • Step 506 Calculate the parameter ratio between the image brightness statistic and the first parameter.
  • the image brightness statistical value is represented as V0, and the parameter ratio between the image brightness statistical value and the first parameter can be calculated, and the functional relationship between the image brightness statistical value and the acquired image parameter value can be preliminarily determined through the ratio.
  • the parameter ratio of the image brightness statistic value to the first parameter can be represented by b:
  • Step 508 Perform logarithmic calculation using the parameter ratio as the true number of the logarithmic function to obtain a statistical value of ambient light intensity.
  • the above-mentioned parameter ratio is used as the true number of the logarithmic function to perform logarithmic calculation, and the statistical value of the ambient light intensity can be obtained.
  • the ambient light intensity EE is a value greater than 0, so b, which is the base of the logarithmic function, is greater than 1, and the preprocessed image brightness statistic value is greater than the parameter value of the first parameter.
  • the purpose of obtaining the statistical value of ambient light intensity can be achieved.
  • the terminal first obtains the first dynamic image to be processed; obtains the statistical value of the target brightness corresponding to the shooting environment through the statistical value of the image brightness corresponding to the first dynamic image and the statistical value of the ambient light intensity, and obtains the statistical value of the target brightness corresponding to the shooting environment through the statistical value of the target brightness.
  • the second brightness correction coefficient and the third brightness correction coefficient are used to process the high dynamic range image through the three brightness correction coefficients to obtain three brightness corrected images, which are respectively the normal images corrected by the first brightness correction coefficient, such as As shown in FIG. 6 ; the darker image corrected by the second brightness correction coefficient is shown in FIG. 7 , and the brighter image corrected by the third brightness correction coefficient is shown in FIG. 8 .
  • the image pixel values are mapped to red, green, and blue three-channel low-dynamic images with pixel values ranging from 0 to 255.
  • the three low-dynamic images after mapping are then fused to obtain a single image after fusion.
  • the fused image retains the highlights and shadow details in the original high dynamic range image, because in some highlight areas that originally have color information, such as colored signboard light boxes, the images corrected by different brightness correction coefficients will appear due to highlight truncation. different color. For example, a brighter image will be overexposed due to brightness correction, causing the image to turn white.
  • the fused image often has a color cast in the highlights.
  • a local tone mapping gain map is obtained. Extract the pixel intensity values of the fused image, and the pixel intensity values of the three darker images in low dynamic range. Perform inverse gamma transformation on the two brightness values, and perform a ratio operation on the two brightness values after inverse gamma transformation, such as division operation, to obtain the brightness value of each pixel of the fused image, which is relative to the brightness value of the corresponding pixel in the darker image.
  • the linear gain value of is
  • the pixel value of the first dynamic image is multiplied by the brightness correction coefficient corresponding to the darker image, and then multiplied by the local tone mapping gain value corresponding to the pixel position to obtain a gain image.
  • the pixel value in the gain image exceeds the preset pixel value, it is limited to the preset pixel value, and then gamma transform is performed on the pixel value of the gain image, and the pixel value is converted into a pixel value between 0 and 255, with eight red, green and blue channels. Bit low dynamic range images.
  • an image processing apparatus 900 including: a first dynamic image acquisition module 902, an image brightness statistical value acquisition module 904, a target brightness statistical value acquisition module 906, a target brightness correction The coefficient determination module 908, the target brightness correction image determination module 910 and the target dynamic image determination module 912, wherein:
  • the first dynamic image acquisition module 902 is configured to acquire the first dynamic image to be processed.
  • the image brightness statistical value acquisition module 904 is configured to acquire the image brightness statistical value corresponding to the first dynamic image.
  • the target brightness statistical value acquisition module 906 is configured to acquire the ambient light intensity statistical value, and obtain the target brightness statistical value corresponding to the shooting environment according to the ambient light intensity statistical value.
  • the target brightness correction coefficient determination module 908 is configured to determine the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value.
  • the target brightness correction image determination module 910 is configured to perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image.
  • the target dynamic image determination module 912 is configured to perform pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image.
  • the target brightness correction coefficient determination module 910 includes at least one of the following units:
  • a brightness enhancement coefficient obtaining unit configured to obtain a brightness enhancement coefficient as a target brightness correction coefficient when the target brightness statistic value is greater than the image brightness statistic value
  • a brightness reduction coefficient acquiring unit configured to acquire a brightness reduction coefficient as a target brightness correction coefficient when the target brightness statistic value is smaller than the image brightness statistic value.
  • the target brightness correction coefficient determination module is further used for:
  • the target brightness correction coefficient determination module 910 is further configured to: perform a reduction process on the first brightness correction coefficient to obtain a second brightness correction coefficient;
  • the target brightness correction image determination module 910 is further configured to: perform brightness correction on the first dynamic image according to the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient, respectively, to obtain the first brightness correction coefficient corrected by the first brightness correction coefficient. a brightness corrected image, a second brightness corrected image corrected by the second brightness correction coefficient, and a third brightness corrected image corrected by the third brightness correction coefficient;
  • the target dynamic image determination module 912 is also used to:
  • the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are fused to obtain the target dynamic image.
  • the target dynamic image determination module 912 is further configured to:
  • Tone-mapping processing is performed on the first dynamic image according to the local mapping gain value to obtain the target dynamic image.
  • an ambient light intensity statistical value acquisition module is further included, configured to acquire the sensitivity, shutter speed, and aperture value corresponding to the first dynamic image
  • the logarithm calculation is performed to obtain the statistical value of the ambient light intensity, where the base of the logarithmic function is greater than 1.
  • Each module in the above-mentioned image processing apparatus may be implemented in whole or in part by software, hardware, and combinations thereof.
  • the above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
  • a computer device is provided, and the computer device may be a server, and its internal structure diagram may be as shown in FIG. 10 .
  • the computer device includes a processor, memory, and a network interface connected by a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities.
  • the memory of the computer device includes a non-volatile storage medium, an internal memory.
  • the nonvolatile storage medium stores an operating system, a computer program, and a database.
  • the internal memory provides an environment for the execution of the operating system and computer programs in the non-volatile storage medium.
  • the database of the computer device is used to store image processing data.
  • the network interface of the computer device is used to communicate with an external terminal through a network connection.
  • the computer program implements an image processing method when executed by a processor.
  • FIG. 10 is only a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied. Include more or fewer components than shown in the figures, or combine certain components, or have a different arrangement of components.
  • a computer device including a memory and a processor, where a computer program is stored in the memory, and the processor implements the steps in the foregoing method embodiments when the processor executes the computer program.
  • a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, implements the steps in the foregoing method embodiments.
  • Non-volatile memory may include read-only memory (Read-Only Memory, ROM), magnetic tape, floppy disk, flash memory, or optical memory, and the like.
  • Volatile memory may include random access memory (RAM) or external cache memory.
  • RAM may be in various forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM).

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Image Processing (AREA)

Abstract

The present application relates to an image processing method and apparatus, and a computer device and a storage medium. The method comprises: acquiring a first dynamic image to be processed; acquiring an image brightness statistical value corresponding to the first dynamic image; acquiring an ambient illumination intensity statistical value, and acquiring, according to the ambient illumination intensity statistical value, a target brightness statistical value corresponding to a photographing environment; determining a target brightness correction coefficient according to the target brightness statistical value and the image brightness statistical value; performing brightness correction on the first dynamic image according to the target brightness correction coefficient, so as to obtain a target brightness correction image; and performing pixel dynamic range mapping on the target brightness correction image, so as to obtain a target dynamic image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image. By means of the present method, the effect of image processing can be improved.

Description

图像处理方法、装置、设备和存储介质Image processing method, apparatus, device and storage medium 技术领域technical field
本申请涉及图像处理技术领域,特别是涉及一种图像处理方法、装置、设备和存储介质。The present application relates to the technical field of image processing, and in particular, to an image processing method, apparatus, device and storage medium.
背景技术Background technique
随着图像处理技术的发展,高动态图像因能够提供更多的动态范围和图像细节,被广泛应用。但是在部分应用中,往往要显示图像的显示设备的动态范围为有限动态范围或者低动态范围,低动态范围是相对于高动态来说的,例如,CRT(Cathode Ray Tube)显示器、LCD显示器或者投影仪等,只有有限的动态范围。经常存在需要在上述有限动态范围设备上显示高动态图像的情景,此时,就需要将高动态图像处理成能够在有限的动态范围设备上显示,并且能够保留图像细节的图像,以便于用户在有限动态范围的显示设备上显示和高动态图像一样的效果。With the development of image processing technology, high dynamic images are widely used because they can provide more dynamic range and image details. However, in some applications, the dynamic range of the display device that often needs to display images is limited dynamic range or low dynamic range, and low dynamic range is relative to high dynamic range, for example, CRT (Cathode Ray Tube) display, LCD display or Projectors, etc., have limited dynamic range. There are often situations in which high dynamic range images need to be displayed on the above-mentioned limited dynamic range devices. In this case, the high dynamic Displays the same effect as HDR on display devices with limited dynamic range.
技术问题technical problem
然而,目前的图像处理方法,在将高动态图像转换为低动态图像时,存在图像细节丢失较多且图像处理效果差的问题。However, in the current image processing method, when converting a high dynamic image into a low dynamic image, there are problems that the image details are lost more and the image processing effect is poor.
技术解决方案technical solutions
基于此,有必要针对上述技术问题,提供一种在将高动态图像转换为低动态图像时,保留更多图像细节且提高图像处理效果的图像处理方法、装置、计算机设备和存储介质。Based on this, it is necessary to provide an image processing method, apparatus, computer equipment and storage medium that retain more image details and improve image processing effects when converting a high dynamic image into a low dynamic image.
第一方面,本发明提供一种图像处理方法,所述方法包括:In a first aspect, the present invention provides an image processing method, the method comprising:
获取待处理的第一动态图像;obtaining the first dynamic image to be processed;
获取所述第一动态图像对应的图像亮度统计值;obtaining the image brightness statistics value corresponding to the first dynamic image;
获取环境光照强度统计值,根据所述环境光照强度统计值获取拍摄环境对应的目标亮度统计值;所述环境光照强度统计值为所述第一动态图像所在拍摄环境的光照强度统计值;Obtaining a statistical value of ambient light intensity, and obtaining a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity; the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located;
根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数;Determine a target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value;
根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像;Perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image;
对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像,所述目标动态图像的像素动态范围小于所述第一动态图像的像素动态范围。Performing pixel dynamic range mapping on the target brightness correction image to obtain a target dynamic image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image.
在其中一个实施例中,所述根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数包括以下步骤的至少一个:In one embodiment, the determining of the target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value includes at least one of the following steps:
当所述目标亮度统计值大于所述图像亮度统计值时,获取亮度增强系数,作为目标亮度修正系数;When the target brightness statistic value is greater than the image brightness statistic value, obtain a brightness enhancement coefficient as a target brightness correction coefficient;
当所述目标亮度统计值小于所述图像亮度统计值时,获取亮度减弱系数。When the target brightness statistic value is smaller than the image brightness statistic value, a brightness reduction coefficient is obtained.
在其中一个实施例中,所述目标亮度修正系数包括第一亮度修正系数,所述根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数包括:In one embodiment, the target brightness correction coefficient includes a first brightness correction coefficient, and the determining the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value includes:
计算所述目标亮度统计值与所述图像亮度统计值的亮度比值;Calculate the brightness ratio of the target brightness statistic value and the image brightness statistic value;
将所述亮度比值作为对数函数中的真数进行对数计算,得到第一亮度修正系数,其中所述对数函数的底数大于1。Taking the luminance ratio as a true number in a logarithmic function, logarithm calculation is performed to obtain a first luminance correction coefficient, wherein the base of the logarithmic function is greater than 1.
在其中一个实施例中,所述目标亮度修正系数还包括第二亮度修正系数以及第三亮度修正系数;所述根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数:In one embodiment, the target brightness correction coefficient further includes a second brightness correction coefficient and a third brightness correction coefficient; the target brightness correction coefficient is determined according to the target brightness statistics value and the image brightness statistics value:
对所述第一亮度修正系数进行减少处理,得到第二亮度修正系数;performing a reduction process on the first brightness correction coefficient to obtain a second brightness correction coefficient;
对所述第一亮度修正系数进行增加处理,得到第三亮度修正系数;performing increasing processing on the first brightness correction coefficient to obtain a third brightness correction coefficient;
所述根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像包括:The performing brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image includes:
分别根据所述第一亮度修正系数、所述第二亮度修正系数、所述第三亮度修正系数对所述第一动态图像进行亮度修正,得到所述第一亮度修正系数修正得到的第一亮度修正图像、所述第二亮度修正系数修正得到的第二亮度修正图像以及所述第三亮度修正系数修正得到的第三亮度修正图像;Performing brightness correction on the first dynamic image according to the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient, respectively, to obtain a first brightness corrected by the first brightness correction coefficient a corrected image, a second brightness corrected image corrected by the second brightness correction coefficient, and a third brightness corrected image corrected by the third brightness correction coefficient;
所述对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像包括:The performing pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image includes:
分别对所述第一亮度修正图像、所述第二亮度修正图像以及所述第三亮度修正图像进行像素动态范围映射,得到所述第一亮度修正图像对应的第一映射动态图像、所述第二亮度修正图像对应的第二映射动态图像以及所述第三亮度修正图像对应的第三映射动态图像;Perform pixel dynamic range mapping on the first brightness-corrected image, the second brightness-corrected image, and the third brightness-corrected image, respectively, to obtain a first mapped dynamic image corresponding to the first brightness-corrected image, the The second mapping dynamic image corresponding to the two brightness correction images and the third mapping dynamic image corresponding to the third brightness correction image;
对所述第一映射动态图像、所述第二映射动态图像以及所述第三映射动态图像进行融合处理,得到目标动态图像。Fusion processing is performed on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a target dynamic image.
在其中一个实施例中,所述对所述第一映射动态图像、所述第二映射动态 图像以及所述第三映射动态图像进行融合处理,得到目标动态图像包括:In one of the embodiments, the described first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are fused to obtain the target dynamic image including:
对所述第一映射动态图像、所述第二映射动态图像以及所述第三映射动态图像进行融合处理,得到融合处理图像;Perform fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a fusion processed image;
获取所述融合处理图像的图像区域;obtaining the image area of the fusion processing image;
获取参考图像区域;Get the reference image area;
计算所述融合图像的图像区域相对于参考图像区域的局部映射增益值;Calculate the local mapping gain value of the image area of the fused image relative to the reference image area;
根据所述局部映射增益值对所述第一动态图像进行色调映射处理,得到目标动态图像。Tone-mapping processing is performed on the first dynamic image according to the local mapping gain value to obtain a target dynamic image.
在其中一个实施例中,所述获取环境光照强度统计值包括:In one of the embodiments, the obtaining a statistical value of the ambient light intensity includes:
获取所述第一动态图像对应的感光度、快门速度以及光圈值;acquiring the sensitivity, shutter speed and aperture value corresponding to the first dynamic image;
根据所述感光度、快门速度以及光圈值得到第一参数值;Obtain the first parameter value according to the sensitivity, shutter speed and aperture value;
计算所述图像亮度统计值与所述第一参数的参数比值;calculating the parameter ratio of the image brightness statistic to the first parameter;
将所述参数比值作为对数函数的真数进行对数计算,得到环境光照强度统计值,其中所述对数函数的底数大于1。The parameter ratio is used as the true number of the logarithmic function to perform logarithmic calculation to obtain a statistical value of the ambient light intensity, wherein the base of the logarithmic function is greater than 1.
第二方面,本发明提供一种图像处理装置,所述装置包括:In a second aspect, the present invention provides an image processing device, the device comprising:
第一动态图像获取模块,用于获取待处理的第一动态图像;a first dynamic image acquisition module, configured to acquire the first dynamic image to be processed;
图像亮度统计值获取模块,用于获取所述第一动态图像对应的图像亮度统计值;an image brightness statistical value acquisition module, configured to acquire an image brightness statistical value corresponding to the first dynamic image;
目标亮度统计值获取模块,用于获取环境光照强度统计值,根据所述环境光照强度统计值获取拍摄环境对应的目标亮度统计值;a target brightness statistical value acquisition module, configured to acquire a statistical value of ambient light intensity, and obtain a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity;
目标亮度修正系数确定模块,用于根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数;a target brightness correction coefficient determination module, configured to determine a target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value;
目标亮度修正图像确定模块,用于根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像;a target brightness correction image determination module, configured to perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image;
目标动态图像确定模块,用于对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像。The target dynamic image determination module is used for performing pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image.
在其中一个实施例中,所述目标亮度修正系数确定模块,包括以下单元的至少一个:In one embodiment, the target brightness correction coefficient determination module includes at least one of the following units:
亮度增强系数获取单元,用于当所述目标亮度统计值大于所述图像亮度统计值时,获取亮度增强系数,作为目标亮度修正系数;a brightness enhancement coefficient obtaining unit, configured to obtain a brightness enhancement coefficient as a target brightness correction coefficient when the target brightness statistic value is greater than the image brightness statistic value;
亮度减弱系数获取单元,用于当所述目标亮度统计值小于所述图像亮度统 计值时,获取亮度减弱系数,作为目标亮度修正系数。A brightness reduction coefficient obtaining unit, configured to obtain a brightness reduction coefficient as a target brightness correction coefficient when the target brightness statistic value is less than the image brightness statistic value.
第三方面,本发明提供一种计算机设备,包括存储器和处理器,所述存储器存储有计算机程序,所述处理器执行所述计算机程序时实现以下步骤:In a third aspect, the present invention provides a computer device, comprising a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
获取待处理的第一动态图像;obtaining the first dynamic image to be processed;
获取所述第一动态图像对应的图像亮度统计值;obtaining the image brightness statistics value corresponding to the first dynamic image;
获取环境光照强度统计值,根据所述环境光照强度统计值获取拍摄环境对应的目标亮度统计值;所述环境光照强度统计值为所述第一动态图像所在拍摄环境的光照强度统计值;Obtaining a statistical value of ambient light intensity, and obtaining a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity; the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located;
根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数;Determine a target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value;
根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像;Perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image;
对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像,所述目标动态图像的像素动态范围小于所述第一动态图像的像素动态范围。Performing pixel dynamic range mapping on the target brightness correction image to obtain a target dynamic image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image.
第四方面,本发明提供一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现以下步骤:In a fourth aspect, the present invention provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
获取待处理的第一动态图像;obtaining the first dynamic image to be processed;
获取所述第一动态图像对应的图像亮度统计值;obtaining the image brightness statistics value corresponding to the first dynamic image;
获取环境光照强度统计值,根据所述环境光照强度统计值获取拍摄环境对应的目标亮度统计值;所述环境光照强度统计值为所述第一动态图像所在拍摄环境的光照强度统计值;Obtaining a statistical value of ambient light intensity, and obtaining a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity; the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located;
根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数;Determine a target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value;
根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像;Perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image;
对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像,所述目标动态图像的像素动态范围小于所述第一动态图像的像素动态范围。Performing pixel dynamic range mapping on the target brightness correction image to obtain a target dynamic image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image.
有益效果beneficial effect
上述图像处理方法、装置、计算机设备和存储介质,通过获取待处理的第一动态图像,获取该第一动态图像的图像亮度统计值;通过获取环境光照强度统计值,根据该环境光照强度统计值获取拍摄环境对应的目标亮度统计值,通过上述的目标亮度统计值与图像亮度统计值确定目标亮度修正系数,通过该目标亮度修正系数对第一动态图像进行亮度修正,得到目标亮度修正图像。 可以通过环境光照强度确定图像的修正系数,并利用修正系数对第一动态图像进行亮度修正,可以得到合适亮度、保留更多细节的图像。通过对目标亮度修正图像进行像素动态范围映射,得到目标动态图像,其中目标动态图像的像素动态范围小于第一动态图像的像素动态范围,从而实现了从高动态图像转换为低动态图像。通过上述过程,实现了通过拍摄图像时的环境光照强度和图像亮度统计值确定图像修正系数,并利用图像修正系数对图像进行修正,能够使得修正后的图像的亮度与所在拍摄环境匹配,故在合适亮度的基础上,将高动态图像处理为低动态图像时,能够保留更多图像细节且提高图像处理效果。In the above image processing method, device, computer equipment and storage medium, by acquiring the first dynamic image to be processed, the image brightness statistical value of the first dynamic image is acquired; by acquiring the ambient light intensity statistical value, according to the ambient light intensity statistical value Obtain the target brightness statistics value corresponding to the shooting environment, determine the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value, and perform brightness correction on the first dynamic image through the target brightness correction coefficient to obtain the target brightness correction image. The correction coefficient of the image can be determined according to the ambient light intensity, and the brightness of the first dynamic image can be corrected by using the correction coefficient, so that an image with suitable brightness and more details can be obtained. The target dynamic image is obtained by performing pixel dynamic range mapping on the target brightness correction image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image, thereby realizing the conversion from a high dynamic image to a low dynamic image. Through the above process, it is realized that the image correction coefficient is determined by the ambient light intensity and the statistical value of the image brightness when the image is taken, and the image is corrected by the image correction coefficient, so that the brightness of the corrected image can be matched with the shooting environment. On the basis of appropriate brightness, when a high dynamic image is processed into a low dynamic image, more image details can be preserved and the image processing effect can be improved.
附图说明Description of drawings
图1为一个实施例中图像处理方法的应用环境图;Fig. 1 is the application environment diagram of the image processing method in one embodiment;
图2为一个实施例中图像处理方法的流程示意图;2 is a schematic flowchart of an image processing method in one embodiment;
图3为另一个实施例中根据目标亮度统计值与图像亮度统计值确定目标亮度修正系数步骤的流程示意图;3 is a schematic flowchart of a step of determining a target brightness correction coefficient according to a target brightness statistic value and an image brightness statistic value in another embodiment;
图4为另一个实施例中第一映射动态图像、第二映射动态图像以及第三映射动态图像进行融合处理,得到目标动态图像方法的流程示意图;4 is a schematic flowchart of a method for obtaining a target dynamic image by performing fusion processing on a first mapping dynamic image, a second mapping dynamic image, and a third mapping dynamic image in another embodiment;
图5为另一个实施例中获取环境光照强度统计值的流程示意图;5 is a schematic flowchart of obtaining a statistical value of ambient light intensity in another embodiment;
图6为一个实施例中正常图像示意图;6 is a schematic diagram of a normal image in one embodiment;
图7为一个实施例中较暗图像示意图;7 is a schematic diagram of a darker image in one embodiment;
图8为一个实施例中较亮图像示意图;8 is a schematic diagram of a brighter image in one embodiment;
图9为一个实施例中图像处理装置的结构框图;9 is a structural block diagram of an image processing apparatus in one embodiment;
图10为一个实施例中计算机设备的内部结构图。Figure 10 is a diagram of the internal structure of a computer device in one embodiment.
本发明的实施方式Embodiments of the present invention
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solutions and advantages of the present application more clearly understood, the present application will be described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application.
本申请提供的图像处理方法,可以应用于如图1所示的应用环境中。应用环境包括图像采集设备102与终端104,其中,图像采集设备102与终端104通信连接。图像采集设备102采集到动态图像后,传输给终端104,终端104获取待处理的第一动态图像,终端104可以通过获取到的第一动态图像获取第一动态图像对应的图像亮度统计值和环境光照强度统计值,根据环境光照 强度统计值获取拍摄环境对应的目标亮度统计值;其中,环境光照强度统计值为第一动态图像所在拍摄环境的光照强度统计值;终端104根据目标亮度统计值与图像亮度统计值确定目标亮度修正系数;根据目标亮度修正系数对第一动态图像进行亮度修正,得到目标亮度修正图像;对目标亮度修正图像进行像素动态范围映射,得到目标动态图像。其中,目标动态图像的像素动态范围小于第一动态图像的像素动态范围。其中,图像采集设备102可以但不限于是各种有图像采集功能的设备,可以分布于终端104的外部,也可以分布于终端104的内部。例如:分布于终端104的外部的各种摄像头、扫描仪、各种相机、图像采集卡。终端104可以但不限于是各种相机、个人计算机、笔记本电脑、智能手机、平板电脑和便携式可穿戴设备。The image processing method provided in this application can be applied to the application environment shown in FIG. 1 . The application environment includes an image capturing device 102 and a terminal 104 , wherein the image capturing device 102 and the terminal 104 are connected in communication. After the image acquisition device 102 collects the dynamic image, it transmits it to the terminal 104. The terminal 104 acquires the first dynamic image to be processed, and the terminal 104 can acquire the image brightness statistics value and the environment corresponding to the first dynamic image through the acquired first dynamic image. The statistical value of light intensity, according to the statistical value of ambient light intensity, the statistical value of target brightness corresponding to the shooting environment is obtained; wherein, the statistical value of ambient light intensity is the statistical value of light intensity of the shooting environment where the first dynamic image is located; the terminal 104 is based on the statistical value of target brightness and the statistical value of light intensity of the shooting environment. The image brightness statistics value determines the target brightness correction coefficient; performs brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain the target brightness correction image; performs pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image. The pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image. The image capturing device 102 may be, but is not limited to, various devices having an image capturing function, and may be distributed outside the terminal 104 or inside the terminal 104 . For example: various cameras, scanners, various cameras, and image capture cards distributed outside the terminal 104 . The terminal 104 may be, but is not limited to, various cameras, personal computers, notebook computers, smart phones, tablet computers, and portable wearable devices.
可以理解,本申请实施例提供的方法,也可以是由服务器执行的。It can be understood that the method provided by the embodiment of the present application may also be executed by a server.
在一个实施例中,如图2所示,提供了一种图像处理方法,以该方法应用于图1中的终端为例进行说明,包括以下步骤:In one embodiment, as shown in FIG. 2, an image processing method is provided, and the method is applied to the terminal in FIG. 1 as an example for description, including the following steps:
步骤202,获取待处理的第一动态图像。Step 202, acquiring the first dynamic image to be processed.
其中,动态图像是指动态范围图像,动态范围图像是指其亮度处于一定范围的图像。动态范围图像分为高动态范围图像(High-Dynamic Range,HDR)、低动态范围图像或者有限动态范围图像。The dynamic image refers to a dynamic range image, and the dynamic range image refers to an image whose brightness is within a certain range. Dynamic range images are classified into high dynamic range images (High-Dynamic Range, HDR), low dynamic range images or limited dynamic range images.
具体地,当终端接收到图像处理指令后,图像处理指令中携带有待处理图像的图像标识,通过此图像标识,终端可以从存储的图像中获取到待处理的第一动态图像。终端获取待处理的第一动态图像以便于对第一动态图像做后续的处理工作。Specifically, after the terminal receives the image processing instruction, the image processing instruction carries the image identifier of the image to be processed, and through the image identifier, the terminal can obtain the first dynamic image to be processed from the stored image. The terminal acquires the first dynamic image to be processed so as to perform subsequent processing work on the first dynamic image.
在一个实施例中,第一动态图像可以通过具备动态范围图像采集功能的采集设备采集得到。In one embodiment, the first dynamic image may be acquired by a acquisition device having a dynamic range image acquisition function.
在一个实施例中,终端可以是要显示的图像,作为待处理的第一动态图像,则终端可以直接对显示的图像进行图像处理。In one embodiment, the terminal may be an image to be displayed, and as the first dynamic image to be processed, the terminal may directly perform image processing on the displayed image.
在一个实施例中,第一动态图像可以通过不同曝光量的图像合成得到。不同曝光量的图像亮度不同,曝光量合适会使图像具有合适的亮度,图像细节更多,曝光量过低或者过曝光量过高的图像都会使图像细节丢失。In one embodiment, the first dynamic image may be obtained by synthesizing images with different exposures. Images with different exposures have different brightness. Appropriate exposure will make the image have appropriate brightness and more image details. Images with too low exposure or too high exposure will lose image details.
步骤204,获取第一动态图像对应的图像亮度统计值。Step 204: Acquire a statistical value of image brightness corresponding to the first dynamic image.
其中,图像亮度统计值是指图像亮度的综合数量表现,从图像亮度统计值中可以获得图像亮度的整体情况,统计值是经过统计得到的,例如可以是平 均值或者是中位数。Among them, the statistical value of image brightness refers to the comprehensive quantitative performance of image brightness, and the overall situation of image brightness can be obtained from the statistical value of image brightness.
具体的,终端在获取第一动态图像之后,通过将第一动态图像转换成灰度图之后统计得到亮度直方图,亮度直方图可以表示图像的每个亮度级别的像素数量,通过亮度直方图获取到第一动态图像的平均亮度。Specifically, after acquiring the first dynamic image, the terminal obtains a brightness histogram by converting the first dynamic image into a grayscale image and statistics. to the average brightness of the first moving image.
步骤206,获取环境光照强度统计值,根据环境光照强度统计值获取拍摄环境对应的目标亮度统计值;环境光照强度统计值为第一动态图像所在拍摄环境的光照强度统计值。Step 206: Obtain a statistical value of ambient light intensity, and obtain a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity; the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located.
其中,环境光照强度统计值是指环境光照强度的综合数量表现,通过环境光照强度统计值可以获知环境光照强度的整体情况,统计值是经过统计得到的,例如可以是平均值或者是中位数。Among them, the statistical value of the ambient light intensity refers to the comprehensive quantitative performance of the ambient light intensity. The overall situation of the ambient light intensity can be known through the statistical value of the ambient light intensity. The statistical value is obtained through statistics, such as the average or the median. .
具体的,终端在获取第一动态图像对应的图像亮度统计值和环境光照强度统计值之后,根据环境光照强度统计值和目标亮度统计值之间的对应关系,可以获取到环境光照强度统计值对应的目标亮度统计值。Specifically, after acquiring the statistical value of image brightness and the statistical value of ambient light intensity corresponding to the first dynamic image, the terminal can obtain the corresponding value of the statistical value of ambient light intensity according to the corresponding relationship between the statistical value of ambient light intensity and the statistical value of target brightness. target brightness statistics.
在一个实施例中,可以根据感光度、快门速度以及光圈值得到曝光参数,将图像亮度统计值除以曝光参数,作为对数函数的真数,进行对数计算,得到环境光照强度统计值。环境光照强度统计值表示为EE,图像亮度统计值表示为V0,目标亮度统计值表示为V,I表示感光度,s为快门速度单位为秒,a为光圈值,环境光照强度统计值与图像亮度统计值之间的关系可以表示为:In one embodiment, the exposure parameter can be obtained according to the sensitivity, shutter speed and aperture value, and the statistical value of the image brightness is divided by the exposure parameter as the true number of the logarithmic function, and the logarithmic calculation is performed to obtain the statistical value of the ambient light intensity. The statistical value of ambient light intensity is expressed as EE, the statistical value of image brightness is expressed as V0, the statistical value of target brightness is expressed as V, I is the sensitivity, s is the shutter speed in seconds, a is the aperture value, and the statistical value of ambient light intensity is related to the image. The relationship between the luminance statistics can be expressed as:
EE=log 2(V0/(I*s/a 2) EE=log 2 (V0/(I*s/a 2 )
不同的环境光照强度统计值有不同的目标亮度统计值,假设目标亮度统计值为V,则环境光照强度统计值EE与目标亮度统计值为V之间有一一对应关系。可以理解的,不同的环境光照强度下拍摄的图像,用户喜欢的图像亮度也不同。比如光照充足的晴天日间拍摄的照片,人们就更喜欢画面偏亮的图片,所以此环境光照强度统计值EE对应的目标亮度统计值V就偏大,而对于夜间室外拍摄的图像,合适亮度的图像的环境光照强度统计值EE对应的目标亮度统计值V相对较小。Different statistical values of ambient light intensity have different statistical values of target brightness. Assuming that the statistical value of target brightness is V, there is a one-to-one correspondence between the statistical value of ambient light intensity EE and the statistical value of target brightness V. It is understandable that images taken under different ambient light intensities have different image brightness that the user likes. For example, for photos taken in sunny days with sufficient light, people prefer brighter pictures, so the target brightness statistic value V corresponding to the ambient light intensity statistic value EE is too large, and for images taken outdoors at night, the appropriate brightness The target brightness statistic value V corresponding to the ambient light intensity statistic value EE of the image is relatively small.
在一个实施例中,环境光照强度统计值EE与目标亮度统计值为V之间有一一对应关系可以记作f。例如,假设以图像像素点亮度值范围在0到1之间,f可以是映射表,如表1所示,为映射表f中部分数据:In one embodiment, there is a one-to-one correspondence between the statistical value of ambient light intensity EE and the statistical value of target brightness V, which may be denoted as f. For example, assuming that the brightness value of an image pixel is between 0 and 1, f can be a mapping table, as shown in Table 1, which is part of the data in the mapping table f:
EE(cd/m 2) EE(cd/m 2 ) -12-12 -10-10 -8-8 -4-4 -2-2 33 55
V(cd/m 2) V(cd/m 2 ) 0.0250.025 0.050.05 0.20.2 0.250.25 0.3750.375 0.50.5 0.50.5
表1环境光照强度统计值与目标亮度统计值映射表Table 1 The mapping table between the statistical value of ambient light intensity and the statistical value of target brightness
从表1中可以得到不同的环境光照强度统计值EE与相对应的目标亮度统计值V之间的数值关系,并且数值关系唯一。基于这种一一对应关系,目标亮度统计值V可以表示为f(EE),可以通过调整此对应关系中的值,来调整某个光照强度下的目标亮度统计值f(EE),从而使图像能够实现更亮或者更暗的效果。From Table 1, the numerical relationship between different ambient light intensity statistics EE and the corresponding target brightness statistics V can be obtained, and the numerical relationship is unique. Based on this one-to-one correspondence, the target brightness statistic V can be expressed as f(EE), and the target brightness statistic f(EE) under a certain illumination intensity can be adjusted by adjusting the value in this correspondence, so that the Images can be made lighter or darker.
步骤208,根据目标亮度统计值与图像亮度统计值确定目标亮度修正系数。Step 208: Determine the target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value.
其中,亮度修正系数为对图像进行亮度修正的系数。可以通过亮度修正的系数把图像调到合适亮度,例如调亮或者调暗。The brightness correction coefficient is a coefficient for performing brightness correction on the image. The image can be adjusted to the appropriate brightness through the brightness correction coefficient, such as brightening or darkening.
具体的,在终端已经获取到目标亮度统计值与图像亮度统计值之后,通过目标亮度统计值与图像亮度统计值之间的函数关系,例如,目标亮度统计值与图像亮度统计值之间存在比值类型的函数关系,可以确定目标亮度修正系数。Specifically, after the terminal has obtained the statistical value of target brightness and the statistical value of image brightness, through the functional relationship between the statistical value of target brightness and the statistical value of image brightness, for example, there is a ratio between the statistical value of target brightness and the statistical value of image brightness The type of functional relationship can determine the target brightness correction coefficient.
在一个实施例中,目标亮度统计值表示为f(EE),图像亮度统计值表示为V0,通过目标亮度修正系数、目标亮度统计值以及图像亮度统计值之间的函数关系,得到目标亮度修正系数。例如,目标亮度修正系数为β,β可表示为:β=log 2(f(EE)/V 0) In one embodiment, the statistical value of target brightness is expressed as f(EE), the statistical value of image brightness is expressed as V0, and the target brightness correction is obtained through the functional relationship between the target brightness correction coefficient, the target brightness statistical value and the image brightness statistical value. coefficient. For example, the target luminance correction coefficient is β, and β can be expressed as: β=log 2 (f(EE)/V 0 )
步骤210,根据目标亮度修正系数对第一动态图像进行亮度修正,得到目标亮度修正图像。Step 210: Perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness corrected image.
具体的,终端根据确定的目标亮度修正系数对第一动态图像进行亮度修正,获取修正后的第一动态图像,作为目标亮度修正图像。例如,可以通过将第一动态图像每个像素值与目标亮度修正系数相乘,得到亮度修正后的像素值,修正后的像素值组成的图像为目标亮度修正图像。Specifically, the terminal performs brightness correction on the first dynamic image according to the determined target brightness correction coefficient, and acquires the corrected first dynamic image as the target brightness correction image. For example, a pixel value after brightness correction can be obtained by multiplying each pixel value of the first dynamic image by a target brightness correction coefficient, and an image composed of the corrected pixel values is a target brightness correction image.
在一个实施例中,可以直接利用目标亮度修正系数对第一动态图像进行亮度修正,使修正后的第一动态图像的图像亮度统计值接近目标亮度统计值。例如,假设第一动态图像中每个像素值为X,利用目标亮度修正系数e1对第一动态图像进行亮度修正,则得到的目标亮度修正图像相对应位置的像素值为X*e1;也可以通过与目标亮度修正系数有对应关系的函数进行计算,得到最终的修正系数,利用该最终的修正系数对第一动态图像进行亮度修正。例如,与目标亮度修正系数相关的函数为指数函数,可以亮度修正系数作为 指数,将预设值作为底数,进行指数计算,预设值为大于1的数。例如,假设预设值为2,则最终得到的修正系数为2 e1,则得到的目标亮度修正图像相对应位置的像素值为X*2 e1In one embodiment, the brightness correction of the first dynamic image may be performed directly by using the target brightness correction coefficient, so that the image brightness statistical value of the corrected first dynamic image is close to the target brightness statistical value. For example, assuming that the value of each pixel in the first dynamic image is X, and using the target brightness correction coefficient e1 to correct the brightness of the first dynamic image, the obtained pixel value of the corresponding position of the target brightness corrected image is X*e1; A final correction coefficient is obtained by calculating a function having a corresponding relationship with the target brightness correction coefficient, and brightness correction is performed on the first moving image by using the final correction coefficient. For example, the function related to the target brightness correction coefficient is an exponential function, the brightness correction coefficient can be used as an exponent, and the preset value is used as the base to perform exponential calculation, and the preset value is a number greater than 1. For example, assuming that the preset value is 2, the final obtained correction coefficient is 2 e1 , and the obtained pixel value of the corresponding position of the target brightness corrected image is X*2 e1 .
步骤212,对目标亮度修正图像进行像素动态范围映射,得到目标动态图像,目标动态图像的像素动态范围小于第一动态图像的像素动态范围。Step 212: Perform pixel dynamic range mapping on the target brightness correction image to obtain a target dynamic image, where the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image.
具体的,动态范围映射是指将图像由一个动态范围映射到另一个动态范围。第一动态图像的像素动态范围是大于目标动态图像的像素动态范围的,为了能够使图像的像素动态范围适应有限动态或者低动态的显示设备,需要将终端得到的目标亮度修正图像进行像素动态范围映射,将高动态图像转换成低动态图像,以便于映射后的图像能够适应低动态的显示设备。Specifically, dynamic range mapping refers to mapping an image from one dynamic range to another dynamic range. The pixel dynamic range of the first dynamic image is larger than the pixel dynamic range of the target dynamic image. In order to adapt the pixel dynamic range of the image to a display device with limited or low dynamics, the target brightness correction image obtained by the terminal needs to be subjected to the pixel dynamic range. Mapping, converts high dynamic images into low dynamic images, so that the mapped images can adapt to low dynamic display devices.
在一个实施例中,当利用亮度修正系数对第一动态图像进行修正得到目标亮度修正图像之后,此时的目标亮度修正图像仍然为高动态图像,需要将其通过动态范围映射方式转换为低动态图像,以便于低动态图像作为目标动态图像,能够适用于低动态设备。In one embodiment, after the target brightness correction image is obtained by correcting the first dynamic image by using the brightness correction coefficient, the target brightness correction image at this time is still a high dynamic image, which needs to be converted into a low dynamic image by dynamic range mapping images, so that low-motion images can be used as target motion images for low-motion devices.
在一个实施例中,可以利用伽马变换实现从高动态图像到低动态图像之间的变换。例如,从像素值范围为0到65535的高动态图像转换为像素值范围为0到255的低动态图像。In one embodiment, the transformation from a high dynamic image to a low dynamic image can be achieved using a gamma transform. For example, converting from a high-motion image with pixel values ranging from 0 to 65535 to a low-motion image with pixel values ranging from 0 to 255.
上述图像处理方法中,通过获取待处理的第一动态图像,获取该第一动态图像的图像亮度统计值;通过获取环境光照强度统计值,根据该环境光照强度统计值获取拍摄环境对应的目标亮度统计值,通过上述的目标亮度统计值与图像亮度统计值确定目标亮度修正系数,通过该目标亮度修正系数对第一动态图像进行亮度修正,得到目标亮度修正图像。可以通过环境光照强度确定图像的修正系数,并利用修正系数对第一动态图像进行亮度修正,可以得到合适亮度、保留更多细节的图像。通过对目标亮度修正图像进行像素动态范围映射,得到目标动态图像,其中目标动态图像的像素动态范围小于第一动态图像的像素动态范围,从而实现了从高动态图像转换为低动态图像。通过上述过程,实现了通过拍摄图像时的环境光照强度和图像亮度统计值确定图像修正系数,并利用图像修正系数对图像进行修正,在保留更多细节和合适亮度的基础上,从高动态图像到低动态图像的图像处理过程,保留更多图像细节且提高了图像处理效果。In the above image processing method, by acquiring the first dynamic image to be processed, the image brightness statistics value of the first dynamic image is acquired; by acquiring the ambient light intensity statistics value, the target brightness corresponding to the shooting environment is acquired according to the ambient light intensity statistics value. Statistical value, the target brightness correction coefficient is determined according to the target brightness statistical value and the image brightness statistical value, and the brightness correction is performed on the first dynamic image through the target brightness correction coefficient to obtain a target brightness correction image. The correction coefficient of the image can be determined according to the ambient light intensity, and the brightness of the first dynamic image can be corrected by using the correction coefficient, so that an image with suitable brightness and more details can be obtained. The target dynamic image is obtained by performing pixel dynamic range mapping on the target brightness correction image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image, thereby realizing the conversion from a high dynamic image to a low dynamic image. Through the above process, it is realized that the image correction coefficient is determined by the ambient light intensity and the statistical value of the image brightness when the image is taken, and the image is corrected by the image correction coefficient. To the image processing process of low dynamic images, more image details are preserved and the image processing effect is improved.
在一个实施例中,根据目标亮度统计值与图像亮度统计值确定目标亮度修 正系数包括以下步骤的至少一个:当目标亮度统计值大于图像亮度统计值时,获取亮度增强系数,作为目标亮度修正系数;当目标亮度统计值小于图像亮度统计值时,获取亮度减弱系数,作为目标亮度修正系数。In one embodiment, determining the target brightness correction coefficient according to the target brightness statistical value and the image brightness statistical value includes at least one of the following steps: when the target brightness statistical value is greater than the image brightness statistical value, acquiring a brightness enhancement coefficient as the target brightness correction coefficient ; When the target brightness statistic value is less than the image brightness statistic value, obtain the brightness reduction coefficient as the target brightness correction coefficient.
具体的,亮度增强系数使得亮度增强,当目标亮度统计值大于图像亮度统计值时,目标亮度修正系数会对图像有亮度增强用,此时的目标亮度修正系数可以称为亮度增强系数。亮度增强系数可以对图像亮度线性增强,也可以对图像亮度非线性增强。亮度增强系数以及亮度减弱系数可以是预设的,也可是通过预设的算法计算得到。例如可以计算目标亮度统计值与所述图像亮度统计值的亮度比值;将亮度比值作为对数函数中的真数进行对数计算,得到第一亮度修正系数,其中对数函数的底数大于1。Specifically, the brightness enhancement coefficient enhances the brightness. When the target brightness statistic value is greater than the image brightness statistic value, the target brightness correction coefficient will enhance the brightness of the image. The target brightness correction coefficient at this time may be called a brightness enhancement coefficient. The brightness enhancement coefficient can enhance the image brightness linearly or nonlinearly. The brightness enhancement coefficient and the brightness reduction coefficient may be preset, or may be calculated by a preset algorithm. For example, the brightness ratio between the target brightness statistic and the image brightness statistic can be calculated; the brightness ratio is used as the true number in the logarithmic function to perform logarithmic calculation to obtain the first brightness correction coefficient, where the base of the logarithmic function is greater than 1.
在一个实施例中,目标亮度统计值可以表示为f(EE),图像亮度统计值为V0,目标亮度修正系数为α,α可表示为:α=2 e In one embodiment, the target luminance statistic value can be expressed as f(EE), the image luminance statistic value is V0, the target luminance correction coefficient is α, and α can be expressed as: α=2 e
其中,e可表示为:e=log 2(f(EE)/V 0) Among them, e can be expressed as: e=log 2 (f(EE)/V 0 )
当目标亮度统计值大于图像亮度统计值时,f(EE)/V0为大于1的正数,此时e为大于0的正数,则α为大于1的正数,将α乘以图像的像素值,将会使亮度增大,此时e可以称为亮度增强系数,可以对图像亮度进行增强调整。当目标亮度统计值小于图像亮度统计值时,f(EE)/V0为小于1的正数,此时e为小于0的负数,则α为小于1的正数,此时e可以称为亮度减弱系数,可以对图像亮度进行减弱。When the statistical value of target brightness is greater than the statistical value of image brightness, f(EE)/V0 is a positive number greater than 1, at this time e is a positive number greater than 0, then α is a positive number greater than 1, multiply α by the The pixel value will increase the brightness. At this time, e can be called the brightness enhancement coefficient, and the brightness of the image can be enhanced and adjusted. When the statistical value of target brightness is less than the statistical value of image brightness, f(EE)/V0 is a positive number less than 1, and e is a negative number less than 0, then α is a positive number less than 1, and e can be called brightness Decrease the coefficient to decrease the brightness of the image.
本实施例中,通过目标亮度统计值与图像亮度统计值,能够达到确定目标亮度系数的目的,利用目标亮度系数可以对图像进行亮度增强或者衰减。In this embodiment, the purpose of determining the target brightness coefficient can be achieved through the target brightness statistical value and the image brightness statistical value, and the brightness of the image can be enhanced or attenuated by using the target brightness coefficient.
在一个实施例中,目标亮度修正系数包括第一亮度修正系数,根据目标亮度统计值与图像亮度统计值确定目标亮度修正系数包括:计算目标亮度统计值与图像亮度统计值的亮度比值;将亮度比值作为对数函数中的真数进行对数计算,得到第一亮度修正系数。In one embodiment, the target brightness correction coefficient includes a first brightness correction coefficient, and determining the target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value includes: calculating the brightness ratio of the target brightness statistic value and the image brightness statistic value; The ratio is used as the true number in the logarithmic function to perform logarithmic calculation to obtain the first brightness correction coefficient.
具体的,终端可以通过目标亮度统计值与图像亮度统计值能够得到第一亮度修正系数,例如先计算目标亮度统计值与图像亮度统计值的亮度比值。例如,目标亮度统计值表示为f(EE),图像亮度统计值为V0,计算比值表示为a,则a可表示为:a=f(EE)/V0Specifically, the terminal may obtain the first brightness correction coefficient through the statistical value of target brightness and the statistical value of image brightness, for example, firstly calculate the brightness ratio of the statistical value of target brightness to the statistical value of image brightness. For example, the statistical value of target brightness is expressed as f(EE), the statistical value of image brightness is V0, and the calculated ratio is expressed as a, then a can be expressed as: a=f(EE)/V0
第一亮度修正系数可表示为e1,其中对数函数的底数大于1,例如,e1是以某种整数为底数的对数函数,e1能够随着对数函数的真数的变化而变化。 例如,e1为以2为底数,单调递增的对数函数,e1=log 2a The first luminance correction coefficient can be expressed as e1, wherein the base of the logarithmic function is greater than 1. For example, e1 is a logarithmic function with an integer base as the base, and e1 can vary with the change of the true number of the logarithmic function. For example, e1 is a base-2, monotonically increasing logarithmic function, e1=log 2 a
本实施例中,对数函数的真数大于1,则使得亮度比值与第一亮度修正系数成正相关关系,通过目标亮度统计值与图像亮度统计值的亮度比值计算得到第一亮度修正系数,使得亮度比值反映目标亮度统计值与图像亮度统计值的大小关系,当目标亮度统计值大于所述图像亮度统计值时,第一亮度增强系数为亮度增强系数。当目标亮度统计值小于所述图像亮度统计值时,第一亮度增强系数为亮度减弱系数。因此使得调整后的图像,与拍摄环境所在的环境亮度是匹配的。In this embodiment, if the true number of the logarithmic function is greater than 1, the luminance ratio is positively correlated with the first luminance correction coefficient, and the first luminance correction coefficient is obtained by calculating the luminance ratio between the target luminance statistical value and the image luminance statistical value, such that The brightness ratio reflects the magnitude relationship between the target brightness statistic value and the image brightness statistic value. When the target brightness statistic value is greater than the image brightness statistic value, the first brightness enhancement coefficient is the brightness enhancement coefficient. When the target brightness statistic value is smaller than the image brightness statistic value, the first brightness enhancement coefficient is a brightness reduction coefficient. Therefore, the adjusted image is matched with the ambient brightness where the shooting environment is located.
在一个实施例中,如图3所示,目标亮度修正系数还包括第二亮度修正系数以及第三亮度修正系数;根据目标亮度统计值与图像亮度统计值确定目标亮度修正系数包括:In one embodiment, as shown in FIG. 3 , the target brightness correction coefficient further includes a second brightness correction coefficient and a third brightness correction coefficient; and determining the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value includes:
步骤302,对第一亮度修正系数进行减少处理,得到第二亮度修正系数。Step 302 , reducing the first brightness correction coefficient to obtain a second brightness correction coefficient.
具体的,在得到第一亮度修正系数之后,可以以第一亮度修正系数为基础,对第一亮度修正系数进行减少处理,可以得到第二亮度修正系数。Specifically, after the first brightness correction coefficient is obtained, the first brightness correction coefficient may be reduced based on the first brightness correction coefficient, and the second brightness correction coefficient may be obtained.
在一个实施例中,对第一亮度修正系数进行减少处理可以通过减少相应的百分比形式。例如,原有修正系数为b,可以通过减少0.1b的形式,得到减少后得到的第二亮度修正系数b1=b-0.1b=0.9b。In one embodiment, reducing the first luminance correction coefficient may be in the form of reducing a corresponding percentage. For example, if the original correction coefficient is b, the second luminance correction coefficient b1=b−0.1b=0.9b obtained after the reduction can be obtained in the form of reducing 0.1b.
在一个实施例中,对第一亮度修正系数进行减少处理可以通过减少相应的系数数值形式。例如,原有修正系数为b,可以通过减少数值m的形式,得到减少后得到的第二亮度修正系数b1=b-m,其中m可以为任意正数,例如为3。In one embodiment, reducing the first luminance correction coefficient may be in the form of reducing the corresponding coefficient value. For example, if the original correction coefficient is b, the second brightness correction coefficient b1=b-m can be obtained by reducing the numerical value m, where m can be any positive number, for example, 3.
步骤304,对第一亮度修正系数进行增加处理,得到第三亮度修正系数。Step 304 , performing an increase process on the first brightness correction coefficient to obtain a third brightness correction coefficient.
具体的,在得到第一亮度修正系数之后,可以以第一亮度修正系数为基础,对第一亮度修正系数进行增加处理,可以得到第三亮度修正系数。Specifically, after the first brightness correction coefficient is obtained, the first brightness correction coefficient may be increased based on the first brightness correction coefficient, and the third brightness correction coefficient may be obtained.
在一个实施例中,可以通过增加相应的百分比形式对第一亮度修正系数进行增加处理。例如,原有修正系数为b,可以通过增加0.1b的形式,得到减少后得到的第三亮度修正系数b1=b+0.1b=1.1b。In one embodiment, the first luminance correction coefficient may be increased in the form of increasing a corresponding percentage. For example, if the original correction coefficient is b, the third luminance correction coefficient b1=b+0.1b=1.1b obtained after the reduction can be obtained in the form of adding 0.1b.
在一个实施例中,对第一亮度修正系数进行增加处理可以通过增加相应的系数数值形式。例如,原有修正系数为b,可以通过增加数值n的形式,得到增加后得到的第三亮度修正系数b1=b+n,其中n为任意正数,例如为3。In one embodiment, the process of increasing the first luminance correction coefficient may be in the form of increasing the corresponding coefficient value. For example, if the original correction coefficient is b, a third brightness correction coefficient b1=b+n can be obtained by increasing the numerical value n, where n is any positive number, for example, 3.
步骤306,分别根据第一亮度修正系数、第二亮度修正系数、第三亮度修 正系数对第一动态图像进行亮度修正,得到第一亮度修正系数修正得到的第一亮度修正图像、第二亮度修正系数修正得到的第二亮度修正图像以及第三亮度修正系数修正得到的第三亮度修正图像。Step 306: Perform brightness correction on the first dynamic image according to the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient, respectively, to obtain a first brightness correction image and a second brightness correction image obtained by modifying the first brightness correction coefficient. The second brightness correction image obtained by the coefficient correction and the third brightness correction image obtained by the third brightness correction coefficient correction.
具体的,在终端获取到第一亮度修正系数、第二亮度修正系数、第三亮度修正系数之后,利用第一亮度修正系数、第二亮度修正系数和第三亮度修正系数分别对第一动态图像进行处理后,得到第一亮度修正图像、第二亮度修正图像以及第三亮度修正图像。例如,第一亮度修正系数作为目标修正系数,相对应的第一亮度修正图像作为目标修正图像,因第二亮度修正图像为对亮度修正系数进行减少处理对应的修正图像,则第二亮度修正图像为较暗的图像;同理,第三亮度修正图像为较亮的图像。Specifically, after the terminal acquires the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient, the terminal uses the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient to modify the first dynamic image respectively. After processing, a first brightness corrected image, a second brightness corrected image and a third brightness corrected image are obtained. For example, the first brightness correction coefficient is used as the target correction coefficient, and the corresponding first brightness correction image is used as the target correction image. Since the second brightness correction image is the correction image corresponding to the reduction of the brightness correction coefficient, the second brightness correction is a darker image; similarly, the third brightness corrected image is a brighter image.
在一个实施例中,第一亮度修正系数较大时,第三亮度修正系数可以配置为更接近于第一亮度修正系数;第一亮度修正系数较小时,第二亮度修正系数可以配置为更接近于第一亮度修正系数。因此可以更好的平衡画面中各个亮度等级的细节,以便于经过修正系数修正后的图像能够体现出目标图像的更多细节。In one embodiment, when the first brightness correction coefficient is large, the third brightness correction coefficient can be configured to be closer to the first brightness correction coefficient; when the first brightness correction coefficient is small, the second brightness correction coefficient can be configured to be closer to at the first brightness correction coefficient. Therefore, the details of each brightness level in the picture can be better balanced, so that the image corrected by the correction coefficient can reflect more details of the target image.
步骤308,分别对第一亮度修正图像、第二亮度修正图像以及第三亮度修正图像进行像素动态范围映射,得到第一亮度修正图像对应的第一映射动态图像、第二亮度修正图像对应的第二映射动态图像以及第三亮度修正图像对应的第三映射动态图像。Step 308: Perform pixel dynamic range mapping on the first brightness-corrected image, the second brightness-corrected image, and the third brightness-corrected image, respectively, to obtain a first mapped dynamic image corresponding to the first brightness-corrected image, and a first mapped dynamic image corresponding to the second brightness-corrected image. The second mapping dynamic image and the third mapping dynamic image corresponding to the third brightness correction image.
在一个实施例中,可以通过伽马变换方式,分别对第一亮度修正图像、第二亮度修正图像以及第三亮度修正图像进行像素动态范围映射,得到第一亮度修正图像对应的第一映射动态图像、第二亮度修正图像对应的第二映射动态图像以及第三亮度修正图像对应的第三映射动态图像。从而实现高动态的亮度修正图像变换为低动态范围的映射动态图像,并且得到的是不同亮度的低动态范围映射动态图像。In one embodiment, pixel dynamic range mapping may be performed on the first brightness-corrected image, the second brightness-corrected image, and the third brightness-corrected image by means of gamma transformation, to obtain the first mapping dynamic range corresponding to the first brightness-corrected image. The image, the second mapping dynamic image corresponding to the second brightness correction image, and the third mapping dynamic image corresponding to the third brightness correction image. In this way, a high-dynamic brightness correction image is transformed into a low-dynamic-range mapped dynamic image, and a low-dynamic-range mapped dynamic image with different brightness is obtained.
在一个实施例中,低动态范围图像可以是八位的低动态范围图像,高动态的修正图像可以是十六位的高动态范围图像,高动态图像是红绿蓝三通道、像素值范围是0到65535之间的图像,低动态范围图像是红绿蓝三通道、像素值范围是0到255之间的图像。In one embodiment, the low dynamic range image may be an eight-bit low dynamic range image, the high dynamic correction image may be a sixteen-bit high dynamic range image, the high dynamic range image has three channels of red, green and blue, and the pixel value range is An image between 0 and 65535, a low dynamic range image is an image with three channels of red, green and blue, and the pixel value range is between 0 and 255.
步骤310,对第一映射动态图像、第二映射动态图像以及第三映射动态图像进行融合处理,得到目标动态图像。Step 310: Perform fusion processing on the first mapping dynamic image, the second mapping dynamic image, and the third mapping dynamic image to obtain a target dynamic image.
其中,融合处理是指根据一定的图像融合方法对不同亮度的图像进行融合,以便于使处理后的图像具有更丰富的图像细节。Among them, the fusion processing refers to the fusion of images with different brightness according to a certain image fusion method, so that the processed image has richer image details.
具体的,首先对第一映射动态图像、第二映射动态图像以及第三映射动态图像进行降采样;根据降采样后的第一映射动态图像、第二映射动态图像以及第三映射动态图像,获取第一映射动态图像对应的第一权值图、第二映射动态图像对应的第二权值图和第三映射动态图像对应的第三权值图;将降采样后的第一映射动态图像、第二映射动态图像以及第三映射动态图像分别转换成灰度图像,对三张灰度图像及第一权值图、第二权值图和第三权值图做多分辨率融合得到多分辨率融合灰度图像;根据此灰度图像,和降采样后的第一映射动态图像、第二映射动态图像以及第三映射动态图像转换成的三张灰度图像和第一权值图、第二权值图和第三权值图,通过如下公式得到新的权值图,分别为第四权值图、第五权值图和第六权值图。假设新的权值图表示为w i',第一权值图、第二权值图和第三权值图表示为w i,其中,i∈(1,2,3),多分辨率融合灰度图像表示为I f,第一映射动态图像、第二映射动态图像以及第三映射动态图像分别转换成的灰度图像分别表示为I 1、I 2和I 3,则新的权值图表示为w i'可以通过如下公式求得: Specifically, first, the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are down-sampled; according to the down-sampled first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image, obtain the first weight map corresponding to the first mapped dynamic image, the second weight map corresponding to the second mapped dynamic image, and the third weight map corresponding to the third mapped dynamic image; the down-sampled first mapped dynamic image, The second mapping dynamic image and the third mapping dynamic image are converted into grayscale images respectively, and multi-resolution fusion is performed on the three grayscale images and the first weight map, the second weight map and the third weight map to obtain multi-resolution rate fusion grayscale image; according to this grayscale image, and the down-sampled first mapping dynamic image, second mapping dynamic image and third mapping dynamic image are converted into three grayscale images and the first weight map, the third For the second weight map and the third weight map, new weight maps are obtained by the following formulas, which are the fourth weight map, the fifth weight map and the sixth weight map, respectively. Suppose the new weight map is represented as wi ', the first weight map, the second weight map and the third weight map are represented as w i , where i∈(1,2,3), multi-resolution fusion The grayscale image is represented as If, and the grayscale images converted from the first mapping dynamic image, the second mapping dynamic image, and the third mapping dynamic image are respectively represented as I 1 , I 2 , and I 3 , then the new weight map Expressed as w i ', it can be obtained by the following formula:
w i'=kw i w i '=kw i
Figure PCTCN2021134713-appb-000001
Figure PCTCN2021134713-appb-000001
I f'=w 1I 1+w 2I 2+w 3I 3,i∈(1,2,3) I f '=w 1 I 1 +w 2 I 2 +w 3 I 3 ,i∈(1,2,3)
再将新的权值图第四权值图、第五权值图和第六权值图分别上采样后,形成和第一映射动态图像、第二映射动态图像以及第三映射动态图像尺寸相同的图像,将第四权值图、第五权值图和第六权值图和第一映射动态图像、第二映射动态图像以及第三映射动态图像加权融合后,得到最终的融合后的目标动态图像。可以理解的,上述图像融合的方法可以使用其他能实现相同效果的融合方法。After up-sampling the new weight map, the fourth weight map, the fifth weight map and the sixth weight map respectively, it forms the same size as the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image. After weighted fusion of the fourth weight map, the fifth weight map and the sixth weight map with the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image, the final fused target is obtained dynamic images. It can be understood that the above-mentioned image fusion method can use other fusion methods that can achieve the same effect.
在一个实施例中,多分辨率融合方法也可以采用双正交小波变换的多分辨率融合方法,可以利用多张图像的冗余及互补信息,使融合后的图像可以包含更加丰富、全面的信息。In one embodiment, the multi-resolution fusion method can also adopt the multi-resolution fusion method of biorthogonal wavelet transform, which can utilize the redundant and complementary information of multiple images, so that the fused image can contain more abundant and comprehensive information. information.
在一个实施例中,可以通过拉普拉斯金字塔加权融合方法对第一映射动态图像、第二映射动态图像以及第三映射动态图像进行融合处理,得到目标动 态图像。In one embodiment, the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image may be fused by the Laplacian pyramid weighted fusion method to obtain the target dynamic image.
本实施例中,通过利用第一亮度修正系数分别得到第二亮度修正系数和第三亮度修正系数,再利用上述三种修正系数得到第一亮度修正图像、第二亮度修正图像以及第三亮度修正图像,并通过第一亮度修正图像、第二亮度修正图像以及第三亮度修正图像得到相应的映射动态图像,将上述三张映射动态图像进行融合处理,得到目标动态图像。能够达到通过不同亮度图像之间细节互补,使亮度较高的图像更多使用亮度较低的图像的值,使亮度较低的图像更多使用亮度较高的图像的值,使目标动态图像能够保留更多图像细节,提高图像处理效果的目的。In this embodiment, the second brightness correction coefficient and the third brightness correction coefficient are respectively obtained by using the first brightness correction coefficient, and the first brightness correction image, the second brightness correction image and the third brightness correction image are obtained by using the above three correction coefficients. image, and obtain the corresponding mapping dynamic image through the first brightness correction image, the second brightness correction image and the third brightness correction image, and fuse the above three mapping dynamic images to obtain the target dynamic image. Through the complementation of details between images with different brightness, the images with higher brightness use the value of the image with lower brightness more, and the image with lower brightness uses the value of the image with higher brightness more, so that the target dynamic image can be The purpose of preserving more image details and improving the image processing effect.
在一个实施例中,如图4所示,对第一映射动态图像、第二映射动态图像以及第三映射动态图像进行融合处理,得到目标动态图像包括:In one embodiment, as shown in FIG. 4 , performing fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain the target dynamic image includes:
步骤402,对第一映射动态图像、第二映射动态图像以及第三映射动态图像进行融合处理,得到融合处理图像。Step 402: Perform fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a fusion processed image.
具体的,为了保留更多的图像细节,分别利用第一映射动态图像、第二映射动态图像以及第三映射动态图像做融合处理,得到融合处理图像。Specifically, in order to retain more image details, the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are respectively used for fusion processing to obtain a fusion processed image.
在一个实施例中,第一映射动态图像、第二映射动态图像以及第三映射动态图像分别都是像素值处在0到255之间的低动态图像,对上述三张映射动态图像进行融合处理后,得到融合处理图像也为像素值处在0到255之间的低动态图像。In one embodiment, the first mapping dynamic image, the second mapping dynamic image, and the third mapping dynamic image are respectively low dynamic images with pixel values between 0 and 255, and fusion processing is performed on the above three mapping dynamic images Afterwards, the obtained fusion image is also a low dynamic image with pixel values between 0 and 255.
步骤404,获取融合处理图像的图像区域。Step 404, acquiring the image area of the fusion-processed image.
具体的,融合处理图像虽然保留了高动态范围图像中的高光和阴影细节,但是由于在一些原本有色彩信息的高光区域,如彩色招牌灯箱,不同亮度修正后的修正图像会因为高光截断而呈现不同的颜色。如较亮图像会因为亮度修正而过曝,导致该处画面变白。因此,融合处理方法得到的图像,在高光出的色彩经常会有偏色的现象。其中,图像区域可以是融合图像中的部分区域,也可以是融合图像的全部区域。Specifically, although the fusion-processed image retains the highlights and shadow details in the high dynamic range image, in some highlight areas that originally have color information, such as colored signboard light boxes, the corrected images after different brightness corrections will appear due to highlight truncation. different color. For example, a brighter image will be overexposed due to brightness correction, causing the image to turn white. Therefore, the image obtained by the fusion processing method often has a color cast in the highlight color. The image area may be a partial area of the fused image, or may be the entire area of the fused image.
步骤406,获取参考图像区域。Step 406, obtaining a reference image area.
具体的,融合后的图像与第二映射动态图像尺寸是相同的,在第二映射动态图像中,有与融合后的图像相对应的图像区域,获取参考图像区域。其中,参考图像区域可以是第二映射动态图像中的部分区域,也可以是第二映射动态图像中的全部区域。Specifically, the size of the fused image is the same as that of the second mapped dynamic image. In the second mapped dynamic image, there is an image area corresponding to the fused image, and a reference image area is obtained. The reference image area may be a partial area in the second mapped dynamic image, or may be the entire area in the second mapped dynamic image.
步骤408,计算融合图像的图像区域相对于参考图像区域的局部映射增益值。Step 408: Calculate the local mapping gain value of the image region of the fused image relative to the reference image region.
其中,局部映射增益值是指该映射值是图像区域对应的映射增益值。The local mapping gain value means that the mapping value is the mapping gain value corresponding to the image area.
在一个实施例中,局部映射增益值为融合后的图像中图像区域与第二映射动态图像中参考图像区域做逆伽马变换,对逆伽马变换后的两个亮度值做比值计算,得到融合后图像每个像素的亮度值相对第二映射动态图像对应像素亮度值的线性增益值。In one embodiment, the local mapping gain value is subjected to inverse gamma transformation between the image region in the fused image and the reference image region in the second mapped dynamic image, and the ratio calculation is performed on the two luminance values after the inverse gamma transformation to obtain The linear gain value of the luminance value of each pixel of the fused image relative to the luminance value of the corresponding pixel of the second mapped dynamic image.
在一个实施例中,可以通过对逆伽马变换后的融合后的图像中待处理图像区域与第二映射动态图像中参考图像区域的两个亮度值做差值计算,得到融合后图像每个像素的亮度值相对第二映射动态图像对应像素亮度值的线性增益值。In one embodiment, by calculating the difference between the two luminance values of the to-be-processed image region in the inverse gamma-transformed fused image and the reference image region in the second mapped dynamic image, each of the fused images can be obtained. The linear gain value of the luminance value of the pixel relative to the luminance value of the pixel corresponding to the second mapped dynamic image.
步骤410,根据局部映射增益值对第一动态图像进行色调映射处理,得到目标动态图像。Step 410: Perform tone mapping processing on the first dynamic image according to the local mapping gain value to obtain a target dynamic image.
具体的,在获取局部映射增益值之后,对第一动态图像进行色调映射处理,做伽马变换之后,将第一动态图像转换为像素值为0到255之间的八位低动态范围图像。Specifically, after the local mapping gain value is obtained, tone mapping is performed on the first dynamic image, and after gamma transformation is performed, the first dynamic image is converted into an eight-bit low dynamic range image with a pixel value between 0 and 255.
在一个实施例中,将第一动态图像待处理图像区域的像素值和对应的第二映射动态图像像素对应的第二亮度系数修正系数的乘积,再与对应像素位置的局部映射增益值进行倍数运算,再对增益之后的像素值做伽马变换,转换为像素值为0到255之间,八位低动态的目标动态图像。经过以上处理,可以保留图像的更多细节,提高图像处理的效果,使高光处颜色更准确。In one embodiment, the product of the pixel value of the to-be-processed image region of the first dynamic image and the second luminance coefficient correction coefficient corresponding to the corresponding second mapped dynamic image pixel is multiplied by the local mapping gain value of the corresponding pixel position. Operation, and then perform gamma transformation on the pixel value after the gain, and convert it into an eight-bit low-dynamic target dynamic image with a pixel value between 0 and 255. After the above processing, more details of the image can be preserved, the effect of image processing can be improved, and the color of highlights can be more accurate.
在一个实施例中,当增益后的像素值超过预设的像素值时,限制为预设像素值。例如,预设像素值限制为65535时,增益后的像素值超过65535的部分都限制为65535。In one embodiment, when the pixel value after the gain exceeds the preset pixel value, it is limited to the preset pixel value. For example, when the preset pixel value is limited to 65535, the part of the pixel value after the gain that exceeds 65535 is limited to 65535.
本实施例中,通过第一映射动态图像、第二映射动态图像以及第三映射动态图像得到融合处理图像,通过局部映射增益值可以对融合处理图像中的待处理图像区域进行处理,处理后的融合图像再经过伽马变化,得到目标动态图像,能够达到在图像处理之后得到保留图像细节更多的目标图像。In this embodiment, the fusion processing image is obtained by using the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image, and the to-be-processed image area in the fusion processing image can be processed by using the local mapping gain value. The fused image is then subjected to gamma change to obtain a target dynamic image, which can achieve a target image with more image details preserved after image processing.
在一个实施例中,如图5所示,获取环境光照强度统计值包括:In one embodiment, as shown in FIG. 5 , obtaining a statistical value of ambient light intensity includes:
步骤502,获取第一动态图像对应的感光度、快门速度以及光圈值。Step 502: Acquire the sensitivity, shutter speed and aperture value corresponding to the first dynamic image.
其中,感光度是指获取第一动态图像时相机对光的敏感程度,感光度过高 会影响图像质量,虽然获取的图像亮度会偏亮,但是感光度过高会使感光度过高,图像噪点更多;快门速度是指使用相机获取图像时,快门的开启时间,快门速度越快,开启时间越短,进入相机的光线越少,图像越暗;反之,快门速度越慢,开启时间越长,进入相机的光线越多,图像越亮。光圈值是指相机镜头通光的相对值,光圈值越小,同一单位时间内进光量越大;反之,光圈值越大,同一单位时间内进光量越大。Among them, the sensitivity refers to the sensitivity of the camera to light when the first dynamic image is acquired. If the sensitivity is too high, the image quality will be affected. Although the brightness of the acquired image will be bright, the sensitivity will be too high if the sensitivity is too high. More noise; shutter speed refers to the opening time of the shutter when using the camera to capture images. The faster the shutter speed, the shorter the opening time, the less light entering the camera, and the darker the image; conversely, the slower the shutter speed, the longer the opening time. The longer, the more light entering the camera, the brighter the image. The aperture value refers to the relative value of the light passing through the camera lens. The smaller the aperture value, the greater the amount of light entering in the same unit time; conversely, the larger the aperture value, the greater the amount of light entering in the same unit time.
具体的,环境光照强度统计值与感光度、快门速度以及光圈值存在函数关系,获取环境光照强度统计值,需要首先获取到上述感光度、快门速度以及光圈值参数。Specifically, the statistical value of ambient light intensity has a functional relationship with the sensitivity, shutter speed, and aperture value. To obtain the statistical value of ambient light intensity, it is necessary to first obtain the above-mentioned parameters of sensitivity, shutter speed, and aperture value.
步骤504,根据感光度、快门速度以及光圈值得到第一参数值。Step 504, obtaining a first parameter value according to the sensitivity, shutter speed and aperture value.
具体的,在获取到感光度、快门速度以及光圈值之后,通过感光度、快门速度以及光圈值得到第一参数值,因快门速度提高一倍,例如,按1秒、1/2秒、1/4秒、1/8秒的序列排列,镜头通光量会减少一半;光圈值每增加一档,例如,1.4、2.0、4.0、5.6、8.0等,通光量也会减少一半;快门速度是按照倍数增加或者减少,光圈值是按照固定数值的平方根成倍增加或者减少的;感光度增加一倍,通光量减少一半。曝光不足时,可以通过设置更大的光圈、更慢的快门速度和更高的感光值来调整。避免曝光过度,可以通过设置更小的光圈、更快的快门速度和更低的感光值来调整。Specifically, after obtaining the sensitivity, shutter speed and aperture value, the first parameter value is obtained through the sensitivity, shutter speed and aperture value. Since the shutter speed is doubled, for example, press 1 second, 1/2 second, 1 /4 second, 1/8 second sequence, the light flux of the lens will be reduced by half; each time the aperture value increases by one stop, for example, 1.4, 2.0, 4.0, 5.6, 8.0, etc., the light flux will also be reduced by half; the shutter speed is based on When the multiple is increased or decreased, the aperture value is multiplied or decreased according to the square root of the fixed value; when the sensitivity is doubled, the amount of light transmitted is reduced by half. Underexposure can be adjusted by setting a larger aperture, slower shutter speed and higher sensitivity value. Avoid overexposure, which can be adjusted by setting a smaller aperture, faster shutter speed and lower ISO value.
在一个实施例中,第一参数值可以利用公式来表示,公式中包括感光度、快门速度和光圈值。其中感光度表示为I,快门速度表示为s,光圈值表示为a,第一参数值表示为c,则c可以表示为:c=I*s/a 2 In one embodiment, the first parameter value can be represented by a formula, and the formula includes sensitivity, shutter speed and aperture value. The sensitivity is expressed as I, the shutter speed is expressed as s, the aperture value is expressed as a, and the first parameter value is expressed as c, then c can be expressed as: c=I*s/a 2
步骤506,计算图像亮度统计值与第一参数的参数比值。Step 506: Calculate the parameter ratio between the image brightness statistic and the first parameter.
具体的,图像亮度统计值表示为V0,可以计算出图像亮度统计值与第一参数的参数比值,通过该比值可以初步判断出图像亮度统计值与获取到图像参数值之间的函数关系。Specifically, the image brightness statistical value is represented as V0, and the parameter ratio between the image brightness statistical value and the first parameter can be calculated, and the functional relationship between the image brightness statistical value and the acquired image parameter value can be preliminarily determined through the ratio.
在一个实施例中,图像亮度统计值与第一参数的参数比值可以用b来表示:In one embodiment, the parameter ratio of the image brightness statistic value to the first parameter can be represented by b:
b=V0/I*s/a 2 b=V0/I*s/a 2
步骤508,将参数比值作为对数函数的真数进行对数计算,得到环境光照强度统计值。Step 508: Perform logarithmic calculation using the parameter ratio as the true number of the logarithmic function to obtain a statistical value of ambient light intensity.
具体的,将上述参数比值作为对数函数的真数进行对数计算,可以得到环境光照强度统计值。环境光照强度统计值可以表示为EE,则EE使用公式表 示为:EE=log 2b Specifically, the above-mentioned parameter ratio is used as the true number of the logarithmic function to perform logarithmic calculation, and the statistical value of the ambient light intensity can be obtained. The statistical value of ambient light intensity can be expressed as EE, then EE is expressed as: EE=log 2 b
环境光照强度EE为大于0的数值,所以作为对数函数的底数的b大于1,预处理的图像亮度统计值大于第一参数的参数值。The ambient light intensity EE is a value greater than 0, so b, which is the base of the logarithmic function, is greater than 1, and the preprocessed image brightness statistic value is greater than the parameter value of the first parameter.
本实施例中,通过第一动态图像对应的感光度、快门速度以及光圈值,以及三者与图像亮度统计值之间的函数关系,能够达到获取环境光照强度统计值的目的。In this embodiment, through the sensitivity, shutter speed, and aperture value corresponding to the first dynamic image, as well as the functional relationship between the three and the statistical value of image brightness, the purpose of obtaining the statistical value of ambient light intensity can be achieved.
在一个实施例中,终端先获取到待处理的第一动态图像;通过第一动态图像对应的图像亮度统计值和环境光照强度统计值获取拍摄环境对应的目标亮度统计值,通过目标亮度统计值与图像亮度统计值确定目标亮度修正系数,把此目标亮度修正系数作为第一亮度修正参数;再通过在此第一亮度修正系数的基础上增加或者减少亮度形成其他两种亮度修正系数,分别是第二亮度修正系数和第三亮度修正系数,通过三种亮度修正系数对高动态范围图像进行处理,得到三种亮度修正之后的图像,分别是经过第一亮度修正系数修正后的正常图像,如图6所示;第二亮度修正系数修正后的较暗的图像,如图7所示,和经过第三亮度修正系数修正后的较亮的图像,如图8所示。三张图像经过伽马变换之后,将图像像素值映射到像素值范围为0到255之间的红绿蓝三通道低动态图像。映射后的三张低动态图像,再通过图像融合,得到融合后的单张图像。融合后的图像虽然保留了原高动态范围图像中的高光和阴影细节,但是由于在一些原本有色彩信息的高光区域,如彩色招牌灯箱,不同亮度修正系数修正后的图像会因为高光截断而呈现不同的颜色。如较亮图像会因为亮度修正而过曝,导致该处画面变白。融合后的图像,在高光处的色彩经常会有偏色的现象。以融合后的画面的局部亮度信息作为参考,结合较暗图相对应的局部亮度信息,得到局部色调映射增益图。提取融合后图像的像素亮度值,和三张低动态范围中较暗图的像素亮度值。对两个亮度值作逆伽马变换,对逆伽马变换后的两个亮度值做比值运算,例如除法运算,得到融合后图像每个像素的亮度值,相对于较暗图对应像素亮度值的线性增益值。第一动态图像的像素值乘以较暗图所对应的亮度修正系数,再乘以对应像素位置的局部色调映射增益值,得到增益图像。增益图像中的像素值超过预设像素值时,限制为预设像素值,再对增益图像的像素值做伽马变换,转换为像素值为0~255之间,红绿蓝三通道的八位低动态范围图像。In one embodiment, the terminal first obtains the first dynamic image to be processed; obtains the statistical value of the target brightness corresponding to the shooting environment through the statistical value of the image brightness corresponding to the first dynamic image and the statistical value of the ambient light intensity, and obtains the statistical value of the target brightness corresponding to the shooting environment through the statistical value of the target brightness. Determine the target brightness correction coefficient with the image brightness statistic value, and use this target brightness correction coefficient as the first brightness correction parameter; and then form other two brightness correction coefficients by increasing or reducing the brightness on the basis of this first brightness correction coefficient, which are respectively The second brightness correction coefficient and the third brightness correction coefficient are used to process the high dynamic range image through the three brightness correction coefficients to obtain three brightness corrected images, which are respectively the normal images corrected by the first brightness correction coefficient, such as As shown in FIG. 6 ; the darker image corrected by the second brightness correction coefficient is shown in FIG. 7 , and the brighter image corrected by the third brightness correction coefficient is shown in FIG. 8 . After the three images are gamma-transformed, the image pixel values are mapped to red, green, and blue three-channel low-dynamic images with pixel values ranging from 0 to 255. The three low-dynamic images after mapping are then fused to obtain a single image after fusion. Although the fused image retains the highlights and shadow details in the original high dynamic range image, because in some highlight areas that originally have color information, such as colored signboard light boxes, the images corrected by different brightness correction coefficients will appear due to highlight truncation. different color. For example, a brighter image will be overexposed due to brightness correction, causing the image to turn white. The fused image often has a color cast in the highlights. Taking the local brightness information of the fused picture as a reference, and combining the local brightness information corresponding to the darker image, a local tone mapping gain map is obtained. Extract the pixel intensity values of the fused image, and the pixel intensity values of the three darker images in low dynamic range. Perform inverse gamma transformation on the two brightness values, and perform a ratio operation on the two brightness values after inverse gamma transformation, such as division operation, to obtain the brightness value of each pixel of the fused image, which is relative to the brightness value of the corresponding pixel in the darker image. The linear gain value of . The pixel value of the first dynamic image is multiplied by the brightness correction coefficient corresponding to the darker image, and then multiplied by the local tone mapping gain value corresponding to the pixel position to obtain a gain image. When the pixel value in the gain image exceeds the preset pixel value, it is limited to the preset pixel value, and then gamma transform is performed on the pixel value of the gain image, and the pixel value is converted into a pixel value between 0 and 255, with eight red, green and blue channels. Bit low dynamic range images.
应该理解的是,虽然图1-5的流程图中的各个步骤按照箭头的指示依次显 示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,图1-5中的至少一部分步骤可以包括多个步骤或者多个阶段,这些步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些步骤或者阶段的执行顺序也不必然是依次进行,而是可以与其它步骤或者其它步骤中的步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that although the various steps in the flowcharts of Figures 1-5 are shown in sequence as indicated by the arrows, these steps are not necessarily performed sequentially in the sequence indicated by the arrows. Unless explicitly stated herein, the execution of these steps is not strictly limited to the order, and these steps may be performed in other orders. Moreover, at least a part of the steps in FIGS. 1-5 may include multiple steps or multiple stages. These steps or stages are not necessarily executed and completed at the same time, but may be executed at different times. The execution of these steps or stages The order is also not necessarily sequential, but may be performed alternately or alternately with other steps or at least a portion of the steps or phases within the other steps.
在一个实施例中,如图9所示,提供了一种图像处理装置900,包括:第一动态图像获取模块902、图像亮度统计值获取模块904、目标亮度统计值获取模块906、目标亮度修正系数确定模块908、目标亮度修正图像确定模块910和目标动态图像确定模块912,其中:In one embodiment, as shown in FIG. 9, an image processing apparatus 900 is provided, including: a first dynamic image acquisition module 902, an image brightness statistical value acquisition module 904, a target brightness statistical value acquisition module 906, a target brightness correction The coefficient determination module 908, the target brightness correction image determination module 910 and the target dynamic image determination module 912, wherein:
第一动态图像获取模块902,用于获取待处理的第一动态图像。The first dynamic image acquisition module 902 is configured to acquire the first dynamic image to be processed.
图像亮度统计值获取模块904,用于获取第一动态图像对应的图像亮度统计值。The image brightness statistical value acquisition module 904 is configured to acquire the image brightness statistical value corresponding to the first dynamic image.
目标亮度统计值获取模块906,用于获取环境光照强度统计值,根据环境光照强度统计值获取拍摄环境对应的目标亮度统计值。The target brightness statistical value acquisition module 906 is configured to acquire the ambient light intensity statistical value, and obtain the target brightness statistical value corresponding to the shooting environment according to the ambient light intensity statistical value.
目标亮度修正系数确定模块908,用于根据目标亮度统计值与图像亮度统计值确定目标亮度修正系数。The target brightness correction coefficient determination module 908 is configured to determine the target brightness correction coefficient according to the target brightness statistics value and the image brightness statistics value.
目标亮度修正图像确定模块910,用于根据目标亮度修正系数对第一动态图像进行亮度修正,得到目标亮度修正图像。The target brightness correction image determination module 910 is configured to perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image.
目标动态图像确定模块912,用于对目标亮度修正图像进行像素动态范围映射,得到目标动态图像。The target dynamic image determination module 912 is configured to perform pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image.
在一个实施例中,目标亮度修正系数确定模块910,包括以下单元的至少一个:In one embodiment, the target brightness correction coefficient determination module 910 includes at least one of the following units:
亮度增强系数获取单元,用于当所述目标亮度统计值大于所述图像亮度统计值时,获取亮度增强系数,作为目标亮度修正系数;a brightness enhancement coefficient obtaining unit, configured to obtain a brightness enhancement coefficient as a target brightness correction coefficient when the target brightness statistic value is greater than the image brightness statistic value;
亮度减弱系数获取单元,用于当所述目标亮度统计值小于所述图像亮度统计值时,获取亮度减弱系数,作为目标亮度修正系数。A brightness reduction coefficient acquiring unit, configured to acquire a brightness reduction coefficient as a target brightness correction coefficient when the target brightness statistic value is smaller than the image brightness statistic value.
在一个实施例中,目标亮度修正系数确定模块还用于:In one embodiment, the target brightness correction coefficient determination module is further used for:
计算目标亮度统计值与图像亮度统计值的亮度比值;Calculate the brightness ratio of the target brightness statistic value to the image brightness statistic value;
将亮度比值作为对数函数中的真数进行对数计算,得到第一亮度修正系 数,其中对数函数的底数大于1。Taking the luminance ratio as a true number in the logarithmic function, perform logarithmic calculation to obtain a first luminance correction coefficient, wherein the base of the logarithmic function is greater than 1.
在一个实施例中,目标亮度修正系数确定模块910还用于:对第一亮度修正系数进行减少处理,得到第二亮度修正系数;In one embodiment, the target brightness correction coefficient determination module 910 is further configured to: perform a reduction process on the first brightness correction coefficient to obtain a second brightness correction coefficient;
对第一亮度修正系数进行增加处理,得到第三亮度修正系数;performing increasing processing on the first brightness correction coefficient to obtain a third brightness correction coefficient;
目标亮度修正图像确定模块910,还用于:分别根据第一亮度修正系数、第二亮度修正系数、第三亮度修正系数对第一动态图像进行亮度修正,得到第一亮度修正系数修正得到的第一亮度修正图像、第二亮度修正系数修正得到的第二亮度修正图像以及第三亮度修正系数修正得到的第三亮度修正图像;The target brightness correction image determination module 910 is further configured to: perform brightness correction on the first dynamic image according to the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient, respectively, to obtain the first brightness correction coefficient corrected by the first brightness correction coefficient. a brightness corrected image, a second brightness corrected image corrected by the second brightness correction coefficient, and a third brightness corrected image corrected by the third brightness correction coefficient;
目标动态图像确定模块912还用于:The target dynamic image determination module 912 is also used to:
分别对第一亮度修正图像、第二亮度修正图像以及第三亮度修正图像进行像素动态范围映射,得到第一亮度修正图像对应的第一映射动态图像、第二亮度修正图像对应的第二映射动态图像以及第三亮度修正图像对应的第三映射动态图像;Perform pixel dynamic range mapping on the first brightness-corrected image, the second brightness-corrected image, and the third brightness-corrected image, respectively, to obtain a first mapping dynamic image corresponding to the first brightness-corrected image and a second mapping dynamic corresponding to the second brightness-corrected image the image and the third mapping dynamic image corresponding to the third brightness correction image;
对第一映射动态图像、第二映射动态图像以及第三映射动态图像进行融合处理,得到目标动态图像。The first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image are fused to obtain the target dynamic image.
在一个实施例中,目标动态图像确定模块912还用于:In one embodiment, the target dynamic image determination module 912 is further configured to:
对第一映射动态图像、第二映射动态图像以及第三映射动态图像进行融合处理,得到融合处理图像;Perform fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a fusion processed image;
获取所述融合处理图像的图像区域;obtaining the image area of the fusion processing image;
获取参考图像区域;Get the reference image area;
计算待处理图像区域相对于参考图像区域的局部映射增益值;Calculate the local mapping gain value of the image area to be processed relative to the reference image area;
根据局部映射增益值对第一动态图像进行色调映射处理,得到目标动态图像。Tone-mapping processing is performed on the first dynamic image according to the local mapping gain value to obtain the target dynamic image.
在一个实施例中,还包括环境光照强度统计值获取模块,用于获取第一动态图像对应的感光度、快门速度以及光圈值;In one embodiment, an ambient light intensity statistical value acquisition module is further included, configured to acquire the sensitivity, shutter speed, and aperture value corresponding to the first dynamic image;
根据感光度、快门速度以及光圈值得到第一参数值;Obtain the first parameter value according to the sensitivity, shutter speed and aperture value;
计算图像亮度统计值与第一参数的参数比值;Calculate the parameter ratio of the image brightness statistical value and the first parameter;
将参数比值作为对数函数的真数进行对数计算,得到环境光照强度统计值,其中对数函数的底数大于1。Taking the parameter ratio as the true number of the logarithmic function, the logarithm calculation is performed to obtain the statistical value of the ambient light intensity, where the base of the logarithmic function is greater than 1.
关于图像处理装置的具体限定可以参见上文中对于图像处理方法的限定, 在此不再赘述。上述图像处理装置中的各个模块可全部或部分通过软件、硬件及其组合来实现。上述各模块可以硬件形式内嵌于或独立于计算机设备中的处理器中,也可以以软件形式存储于计算机设备中的存储器中,以便于处理器调用执行以上各个模块对应的操作。For the specific limitation of the image processing apparatus, reference may be made to the limitation of the image processing method above, which will not be repeated here. Each module in the above-mentioned image processing apparatus may be implemented in whole or in part by software, hardware, and combinations thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
在一个实施例中,提供了一种计算机设备,该计算机设备可以是服务器,其内部结构图可以如图10所示。该计算机设备包括通过系统总线连接的处理器、存储器和网络接口。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质、内存储器。该非易失性存储介质存储有操作系统、计算机程序和数据库。该内存储器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的数据库用于存储图像处理数据。该计算机设备的网络接口用于与外部的终端通过网络连接通信。该计算机程序被处理器执行时以实现一种图像处理方法。In one embodiment, a computer device is provided, and the computer device may be a server, and its internal structure diagram may be as shown in FIG. 10 . The computer device includes a processor, memory, and a network interface connected by a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium, an internal memory. The nonvolatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the execution of the operating system and computer programs in the non-volatile storage medium. The database of the computer device is used to store image processing data. The network interface of the computer device is used to communicate with an external terminal through a network connection. The computer program implements an image processing method when executed by a processor.
本领域技术人员可以理解,图10中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。Those skilled in the art can understand that the structure shown in FIG. 10 is only a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied. Include more or fewer components than shown in the figures, or combine certain components, or have a different arrangement of components.
在一个实施例中,还提供了一种计算机设备,包括存储器和处理器,存储器中存储有计算机程序,该处理器执行计算机程序时实现上述各方法实施例中的步骤。In one embodiment, a computer device is also provided, including a memory and a processor, where a computer program is stored in the memory, and the processor implements the steps in the foregoing method embodiments when the processor executes the computer program.
在一个实施例中,提供了一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现上述各方法实施例中的步骤。In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, implements the steps in the foregoing method embodiments.
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一非易失性计算机可读取存储介质中,该计算机程序在执行时,可包括如上述各方法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、存储、数据库或其它介质的任何引用,均可包括非易失性和易失性存储器中的至少一种。非易失性存储器可包括只读存储器(Read-Only Memory,ROM)、磁带、软盘、闪存或光存储器等。易失性存储器可包括随机存取存储器(Random Access Memory,RAM)或外部高速缓冲存储器。作为说明而非局限,RAM可以是多种形式,比如静态随机存取存储器(Static Random Access Memory,SRAM)或动态随机存取存储器(Dynamic Random  Access Memory,DRAM)等。Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be implemented by instructing relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage In the medium, when the computer program is executed, it may include the processes of the above-mentioned method embodiments. Wherein, any reference to memory, storage, database or other media used in the various embodiments provided in this application may include at least one of non-volatile and volatile memory. Non-volatile memory may include read-only memory (Read-Only Memory, ROM), magnetic tape, floppy disk, flash memory, or optical memory, and the like. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM may be in various forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM).
以上实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above embodiments can be combined arbitrarily. In order to make the description simple, all possible combinations of the technical features in the above embodiments are not described. However, as long as there is no contradiction in the combination of these technical features It is considered to be the range described in this specification.
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。The above-mentioned embodiments only represent several embodiments of the present application, and the descriptions thereof are specific and detailed, but should not be construed as a limitation on the scope of the invention patent. It should be pointed out that for those skilled in the art, without departing from the concept of the present application, several modifications and improvements can be made, which all belong to the protection scope of the present application. Therefore, the scope of protection of the patent of the present application shall be subject to the appended claims.

Claims (10)

  1. 一种图像处理方法,其特征在于,所述方法包括:An image processing method, characterized in that the method comprises:
    获取待处理的第一动态图像;obtaining the first dynamic image to be processed;
    获取所述第一动态图像对应的图像亮度统计值;obtaining the image brightness statistics value corresponding to the first dynamic image;
    获取环境光照强度统计值,根据所述环境光照强度统计值获取拍摄环境对应的目标亮度统计值;所述环境光照强度统计值为所述第一动态图像所在拍摄环境的光照强度统计值;Obtaining a statistical value of ambient light intensity, and obtaining a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity; the statistical value of ambient light intensity is a statistical value of light intensity of the shooting environment where the first dynamic image is located;
    根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数;Determine a target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value;
    根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像;Perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image;
    对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像,所述目标动态图像的像素动态范围小于所述第一动态图像的像素动态范围。Performing pixel dynamic range mapping on the target brightness correction image to obtain a target dynamic image, wherein the pixel dynamic range of the target dynamic image is smaller than the pixel dynamic range of the first dynamic image.
  2. 根据权利要求1所述的方法,其特征在于,所述根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数包括以下步骤的至少一个:The method according to claim 1, wherein the determining the target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value comprises at least one of the following steps:
    当所述目标亮度统计值大于所述图像亮度统计值时,获取亮度增强系数,作为目标亮度修正系数;When the target brightness statistic value is greater than the image brightness statistic value, obtain a brightness enhancement coefficient as a target brightness correction coefficient;
    当所述目标亮度统计值小于所述图像亮度统计值时,获取亮度减弱系数,作为目标亮度修正系数。When the target brightness statistic value is smaller than the image brightness statistic value, a brightness reduction coefficient is obtained as a target brightness correction coefficient.
  3. 根据权利要求1或2所述的方法,其特征在于,所述目标亮度修正系数包括第一亮度修正系数,所述根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数包括:The method according to claim 1 or 2, wherein the target brightness correction coefficient comprises a first brightness correction coefficient, and the determining the target brightness correction coefficient according to the target brightness statistical value and the image brightness statistical value comprises: :
    计算所述目标亮度统计值与所述图像亮度统计值的亮度比值;Calculate the brightness ratio of the target brightness statistic value and the image brightness statistic value;
    将所述亮度比值作为对数函数中的真数进行对数计算,得到第一亮度修正系数,其中所述对数函数的底数大于1。Taking the luminance ratio as a true number in a logarithmic function, logarithm calculation is performed to obtain a first luminance correction coefficient, wherein the base of the logarithmic function is greater than 1.
  4. 根据权利要求3所述的方法,其特征在于,所述目标亮度修正系数还包括第二亮度修正系数以及第三亮度修正系数;所述根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数包括:The method according to claim 3, wherein the target brightness correction coefficient further comprises a second brightness correction coefficient and a third brightness correction coefficient; the determining according to the target brightness statistic value and the image brightness statistic value Target brightness correction factors include:
    对所述第一亮度修正系数进行减少处理,得到第二亮度修正系数;performing a reduction process on the first brightness correction coefficient to obtain a second brightness correction coefficient;
    对所述第一亮度修正系数进行增加处理,得到第三亮度修正系数;performing increasing processing on the first brightness correction coefficient to obtain a third brightness correction coefficient;
    所述根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像包括:The performing brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image includes:
    分别根据所述第一亮度修正系数、所述第二亮度修正系数、所述第三亮度 修正系数对所述第一动态图像进行亮度修正,得到所述第一亮度修正系数修正得到的第一亮度修正图像、所述第二亮度修正系数修正得到的第二亮度修正图像以及所述第三亮度修正系数修正得到的第三亮度修正图像;Performing brightness correction on the first dynamic image according to the first brightness correction coefficient, the second brightness correction coefficient, and the third brightness correction coefficient, respectively, to obtain a first brightness corrected by the first brightness correction coefficient a corrected image, a second brightness corrected image corrected by the second brightness correction coefficient, and a third brightness corrected image corrected by the third brightness correction coefficient;
    所述对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像包括:The performing pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image includes:
    分别对所述第一亮度修正图像、所述第二亮度修正图像以及所述第三亮度修正图像进行像素动态范围映射,得到所述第一亮度修正图像对应的第一映射动态图像、所述第二亮度修正图像对应的第二映射动态图像以及所述第三亮度修正图像对应的第三映射动态图像;Perform pixel dynamic range mapping on the first brightness-corrected image, the second brightness-corrected image, and the third brightness-corrected image, respectively, to obtain a first mapped dynamic image corresponding to the first brightness-corrected image, the The second mapping dynamic image corresponding to the two brightness correction images and the third mapping dynamic image corresponding to the third brightness correction image;
    对所述第一映射动态图像、所述第二映射动态图像以及所述第三映射动态图像进行融合处理,得到目标动态图像。Fusion processing is performed on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a target dynamic image.
  5. 根据权利要求4所述的方法,其特征在于,所述对所述第一映射动态图像、所述第二映射动态图像以及所述第三映射动态图像进行融合处理,得到目标动态图像包括:The method according to claim 4, wherein the performing fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain the target dynamic image comprises:
    对所述第一映射动态图像、所述第二映射动态图像以及所述第三映射动态图像进行融合处理,得到融合处理图像;Perform fusion processing on the first mapping dynamic image, the second mapping dynamic image and the third mapping dynamic image to obtain a fusion processed image;
    获取所述融合处理图像的图像区域;obtaining the image area of the fusion processing image;
    获取参考图像区域;Get the reference image area;
    计算所述融合图像的图像区域相对于参考图像区域的局部映射增益值;Calculate the local mapping gain value of the image area of the fused image relative to the reference image area;
    根据所述局部映射增益值对所述第一动态图像进行色调映射处理,得到目标动态图像。Tone-mapping processing is performed on the first dynamic image according to the local mapping gain value to obtain a target dynamic image.
  6. 根据权利要求5所述的方法,其特征在于,所述获取环境光照强度统计值包括:The method according to claim 5, wherein the obtaining a statistical value of the ambient light intensity comprises:
    获取所述第一动态图像对应的感光度、快门速度以及光圈值;acquiring the sensitivity, shutter speed and aperture value corresponding to the first dynamic image;
    根据所述感光度、快门速度以及光圈值得到第一参数值;Obtain the first parameter value according to the sensitivity, shutter speed and aperture value;
    计算所述图像亮度统计值与所述第一参数的参数比值;calculating the parameter ratio of the image brightness statistic to the first parameter;
    将所述参数比值作为对数函数的真数进行对数计算,得到环境光照强度统计值,其中所述对数函数的底数大于1。The parameter ratio is used as the true number of the logarithmic function to perform logarithmic calculation to obtain a statistical value of the ambient light intensity, wherein the base of the logarithmic function is greater than 1.
  7. 一种图像处理装置,其特征在于,所述装置包括:An image processing device, characterized in that the device comprises:
    第一动态图像获取模块,用于获取待处理的第一动态图像;a first dynamic image acquisition module, configured to acquire the first dynamic image to be processed;
    图像亮度统计值获取模块,用于获取所述第一动态图像对应的图像亮度统 计值;an image brightness statistical value acquisition module, used for acquiring the image brightness statistical value corresponding to the first dynamic image;
    目标亮度统计值获取模块,用于获取环境光照强度统计值,根据所述环境光照强度统计值获取拍摄环境对应的目标亮度统计值;a target brightness statistical value acquisition module, configured to acquire a statistical value of ambient light intensity, and obtain a statistical value of target brightness corresponding to the shooting environment according to the statistical value of ambient light intensity;
    目标亮度修正系数确定模块,用于根据所述目标亮度统计值与所述图像亮度统计值确定目标亮度修正系数;a target brightness correction coefficient determination module, configured to determine a target brightness correction coefficient according to the target brightness statistic value and the image brightness statistic value;
    目标亮度修正图像确定模块,用于根据所述目标亮度修正系数对所述第一动态图像进行亮度修正,得到目标亮度修正图像;a target brightness correction image determination module, configured to perform brightness correction on the first dynamic image according to the target brightness correction coefficient to obtain a target brightness correction image;
    目标动态图像确定模块,用于对所述目标亮度修正图像进行像素动态范围映射,得到目标动态图像。The target dynamic image determination module is used for performing pixel dynamic range mapping on the target brightness correction image to obtain the target dynamic image.
  8. 根据权利要求7所述的装置,其特征在于,所述目标亮度修正系数确定模块,包括以下单元的至少一个:The device according to claim 7, wherein the target brightness correction coefficient determination module comprises at least one of the following units:
    亮度增强系数获取单元,用于当所述目标亮度统计值大于所述图像亮度统计值时,获取亮度增强系数,作为目标亮度修正系数;a brightness enhancement coefficient obtaining unit, configured to obtain a brightness enhancement coefficient as a target brightness correction coefficient when the target brightness statistic value is greater than the image brightness statistic value;
    亮度减弱系数获取单元,用于当所述目标亮度统计值小于所述图像亮度统计值时,获取亮度减弱系数,作为目标亮度修正系数。A brightness reduction coefficient obtaining unit, configured to obtain a brightness reduction coefficient as a target brightness correction coefficient when the target brightness statistic value is smaller than the image brightness statistic value.
  9. 一种计算机设备,包括存储器和处理器,所述存储器存储有计算机程序,其特征在于,所述处理器执行所述计算机程序时实现权利要求1至6中任一项所述的方法的步骤。A computer device, comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, when the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.
  10. 一种计算机可读存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现权利要求1至6中任一项所述的方法的步骤。A computer-readable storage medium on which a computer program is stored, characterized in that, when the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
PCT/CN2021/134713 2020-12-01 2021-12-01 Image processing method and apparatus, and device and storage medium WO2022116989A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011387105.9A CN112565636B (en) 2020-12-01 2020-12-01 Image processing method, device, equipment and storage medium
CN202011387105.9 2020-12-01

Publications (1)

Publication Number Publication Date
WO2022116989A1 true WO2022116989A1 (en) 2022-06-09

Family

ID=75047115

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/134713 WO2022116989A1 (en) 2020-12-01 2021-12-01 Image processing method and apparatus, and device and storage medium

Country Status (2)

Country Link
CN (1) CN112565636B (en)
WO (1) WO2022116989A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117408927A (en) * 2023-12-12 2024-01-16 荣耀终端有限公司 Image processing method, device and storage medium

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112381743A (en) * 2020-12-01 2021-02-19 影石创新科技股份有限公司 Image processing method, device, equipment and storage medium
CN112565636B (en) * 2020-12-01 2023-11-21 影石创新科技股份有限公司 Image processing method, device, equipment and storage medium
CN114463191B (en) * 2021-08-26 2023-01-31 荣耀终端有限公司 Image processing method and electronic equipment
CN115484384B (en) * 2021-09-13 2023-12-01 华为技术有限公司 Method and device for controlling exposure and electronic equipment
CN116137674B (en) * 2021-11-18 2024-04-09 腾讯科技(深圳)有限公司 Video playing method, device, computer equipment and storage medium
CN117135467A (en) * 2023-02-23 2023-11-28 荣耀终端有限公司 Image processing method and electronic equipment

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101620819A (en) * 2009-06-25 2010-01-06 北京中星微电子有限公司 Dynamic regulation method and dynamic regulation device for displaying image back light brightness, and moving display device
CN103370736A (en) * 2010-12-10 2013-10-23 顶级公司 Display controller and display system
CN107690811A (en) * 2015-06-05 2018-02-13 苹果公司 It is presented and shows HDR content
WO2019245876A1 (en) * 2018-06-18 2019-12-26 Dolby Laboratories Licensing Corporation Image capture methods and systems
CN111601048A (en) * 2020-05-13 2020-08-28 展讯通信(上海)有限公司 Image processing method and device
CN111614908A (en) * 2020-05-29 2020-09-01 Oppo广东移动通信有限公司 Image processing method, image processing device, electronic equipment and storage medium
US20200342578A1 (en) * 2017-12-29 2020-10-29 Ateme Dynamic range compression method
CN112381743A (en) * 2020-12-01 2021-02-19 影石创新科技股份有限公司 Image processing method, device, equipment and storage medium
CN112565636A (en) * 2020-12-01 2021-03-26 影石创新科技股份有限公司 Image processing method, device, equipment and storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103916669B (en) * 2014-04-11 2017-06-13 浙江宇视科技有限公司 High dynamic range images compression method and device
CN205809921U (en) * 2016-05-12 2016-12-14 珠海市杰理科技有限公司 Figure image width dynamic range compression device
JP6866224B2 (en) * 2017-05-09 2021-04-28 キヤノン株式会社 Image coding device, image decoding device, image coding method and program
CN107481696A (en) * 2017-09-27 2017-12-15 天津汇讯视通科技有限公司 Self-adaptive image processing method based on gamma correlation
CN111294575B (en) * 2020-01-19 2022-06-28 Oppo广东移动通信有限公司 Image processing method, image processing device, electronic equipment and storage medium

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101620819A (en) * 2009-06-25 2010-01-06 北京中星微电子有限公司 Dynamic regulation method and dynamic regulation device for displaying image back light brightness, and moving display device
CN103370736A (en) * 2010-12-10 2013-10-23 顶级公司 Display controller and display system
CN107690811A (en) * 2015-06-05 2018-02-13 苹果公司 It is presented and shows HDR content
US20200342578A1 (en) * 2017-12-29 2020-10-29 Ateme Dynamic range compression method
WO2019245876A1 (en) * 2018-06-18 2019-12-26 Dolby Laboratories Licensing Corporation Image capture methods and systems
CN111601048A (en) * 2020-05-13 2020-08-28 展讯通信(上海)有限公司 Image processing method and device
CN111614908A (en) * 2020-05-29 2020-09-01 Oppo广东移动通信有限公司 Image processing method, image processing device, electronic equipment and storage medium
CN112381743A (en) * 2020-12-01 2021-02-19 影石创新科技股份有限公司 Image processing method, device, equipment and storage medium
CN112565636A (en) * 2020-12-01 2021-03-26 影石创新科技股份有限公司 Image processing method, device, equipment and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117408927A (en) * 2023-12-12 2024-01-16 荣耀终端有限公司 Image processing method, device and storage medium

Also Published As

Publication number Publication date
CN112565636B (en) 2023-11-21
CN112565636A (en) 2021-03-26

Similar Documents

Publication Publication Date Title
WO2022116989A1 (en) Image processing method and apparatus, and device and storage medium
US11403740B2 (en) Method and apparatus for image capturing and processing
WO2022116988A1 (en) Image processing method and apparatus, and device and storage medium
CN108335279B (en) Image fusion and HDR imaging
US10074165B2 (en) Image composition device, image composition method, and recording medium
JP6111336B2 (en) Image processing method and apparatus
CN110033418B (en) Image processing method, image processing device, storage medium and electronic equipment
WO2021143300A1 (en) Image processing method and apparatus, electronic device and storage medium
WO2022000397A1 (en) Low-illumination image enhancement method and apparatus, and computer device
US9542734B2 (en) Information processing apparatus, image processing method, and storage medium that determine tone characteristics for respective object signals
US11190707B2 (en) Motion ghost resistant HDR image generation method and portable terminal
WO2020143257A1 (en) Motion artifact resistant hdr method and portable terminal
WO2021218603A1 (en) Image processing method and projection system
CN113163127B (en) Image processing method, device, electronic equipment and storage medium
CN111242860B (en) Super night scene image generation method and device, electronic equipment and storage medium
CN110047060B (en) Image processing method, image processing device, storage medium and electronic equipment
EP4218228A1 (en) Saliency based capture or image processing
CN114429476A (en) Image processing method, image processing apparatus, computer device, and storage medium
CN114240767A (en) Image wide dynamic range processing method and device based on exposure fusion
CN113781358A (en) Image processing method, image processing device, electronic equipment and computer readable storage medium
CN115205168A (en) Image processing method, device, electronic equipment, storage medium and product
CN114554106B (en) Automatic exposure method, device, image acquisition method, medium and equipment
WO2022226917A1 (en) Image processing method and electronic device
Mangiat et al. Automatic scene relighting for video conferencing
KR100520970B1 (en) Method and apparatus for transforming a high dynamic range image into a low dynamic range image

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21900020

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 23-10-2023)

122 Ep: pct application non-entry in european phase

Ref document number: 21900020

Country of ref document: EP

Kind code of ref document: A1