WO2023241339A1 - Color cast correction method and apparatus, device, storage medium and program product - Google Patents

Color cast correction method and apparatus, device, storage medium and program product Download PDF

Info

Publication number
WO2023241339A1
WO2023241339A1 PCT/CN2023/096662 CN2023096662W WO2023241339A1 WO 2023241339 A1 WO2023241339 A1 WO 2023241339A1 CN 2023096662 W CN2023096662 W CN 2023096662W WO 2023241339 A1 WO2023241339 A1 WO 2023241339A1
Authority
WO
WIPO (PCT)
Prior art keywords
parameter
chromaticity
target
parameters
angle
Prior art date
Application number
PCT/CN2023/096662
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 WO2023241339A1 publication Critical patent/WO2023241339A1/en

Links

Classifications

    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G3/00Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes
    • G09G3/20Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes for presentation of an assembly of a number of characters, e.g. a page, by composing the assembly by combination of individual elements arranged in a matrix no fixed position being assigned to or needed to be assigned to the individual characters or partial characters
    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G2320/00Control of display operating conditions
    • G09G2320/02Improving the quality of display appearance
    • G09G2320/0242Compensation of deficiencies in the appearance of colours
    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G2320/00Control of display operating conditions
    • G09G2320/06Adjustment of display parameters
    • G09G2320/0666Adjustment of display parameters for control of colour parameters, e.g. colour temperature
    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G2320/00Control of display operating conditions
    • G09G2320/06Adjustment of display parameters
    • G09G2320/0693Calibration of display systems

Definitions

  • Embodiments of the present application relate to the field of image technology, and in particular to a color shift correction method, device, equipment, storage medium and program product.
  • SDR Standard Dynamic Range
  • HDR High Dynamic Range
  • the embodiments of the present application provide a color shift correction method, device, equipment, storage medium and program product.
  • the technical solution is as follows:
  • embodiments of the present application provide a color shift correction method, which method includes:
  • a local chromaticity parameter Based on the chromaticity information indicated by the image chromaticity parameter in the extended image parameters, select a local chromaticity parameter, where the local chromaticity parameter is a chromaticity parameter corresponding to the skin color area of the portrait;
  • a target HDR image corresponding to the target SDR image is generated.
  • a color shift correction device which includes:
  • a dynamic expansion module configured to dynamically expand the brightness of the image parameters of the target SDR image, where the target SDR image includes portraits, to obtain the expanded image parameters
  • a parameter selection module configured to select a local chromaticity parameter based on the chromaticity information indicated by the image chromaticity parameter in the extended image parameter, where the local chromaticity parameter is a chromaticity parameter corresponding to the skin color area of the portrait;
  • a color deviation correction module configured to perform color deviation correction on the local chromaticity parameters to obtain corrected image parameters
  • An image generation module configured to generate a target HDR image corresponding to the target SDR image based on the corrected image parameters.
  • inventions of the present application provide a computer device.
  • the computer device includes a processor and a memory. At least one instruction is stored in the memory. The at least one instruction is loaded and executed by the processor to implement Color shift correction method as described above.
  • embodiments of the present application provide a computer-readable storage medium in which at least one instruction is stored, and the at least one instruction is loaded and executed by a processor to implement the above aspects. color cast correction method.
  • inventions of the present application provide a computer program product or computer program.
  • the computer program product or computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium.
  • the processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the color shift correction method provided in various optional implementations of the above aspect.
  • Figure 1 shows a flow chart of a color shift correction method provided by an exemplary embodiment of the present application
  • Figure 2 shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application
  • Figure 3 shows a schematic diagram of the process of converting a target SDR image into a target HDR image provided by an exemplary embodiment of the present application
  • Figure 4 shows a schematic diagram of the target chromaticity range in the Lab color space provided by an exemplary embodiment of the present application
  • Figure 5 shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application.
  • Figure 6 shows a schematic diagram of the color shift correction process provided by an exemplary embodiment of the present application
  • Figure 7 shows a structural block diagram of a color shift correction device provided by an embodiment of the present application.
  • SDR describes the dynamic range of the image/video through the traditional gamma gamma curve, where the SDR content is represented by 8bit.
  • the color gamuts generally used for SDR content include Rec.601, Rec.709, and sRGB. Different color gamuts correspond to different gamma curves.
  • SDR content is generally displayed on a screen with a brightness of 100nit.
  • HDR uses the hybrid log-gamma method (Hybrid Log-Gamma, HLG) or the perceptual quantizer (Perceptual Quantizer, PQ) to describe the dynamic range of the image/video. Compared with the gamma curve, the dynamic range that can be described is larger.
  • the dynamic range refers to the brightness range. That is, the brightness range that can be displayed by the HDR standard is larger than the brightness range that can be displayed by the SDR standard.
  • HDR content can be represented in 10bit, 12bit and 14bit. Currently, 10bit representation is mainly used. HDR content is generally displayed on a screen with a brightness of 1000nit-10000nit.
  • SDR2HDR SDR to HDR, which converts traditional SDR content into HDR content.
  • Hunt effect refers to the obvious change in the color appearance of an object as the overall brightness changes, that is, the chromaticity changes with the change in brightness.
  • the traditional HSV/HSL/Lab/YUV/ICbCr color model can separate the brightness information and chroma information (hue and saturation) in the color to a certain extent, this separation is not perfect, and changes in brightness will still cause Bring about a change in color.
  • the human eye itself The perception of color and brightness are closely related and difficult to completely separate.
  • YUV color coding A color coding method commonly used in image processing components. Among them, Y represents brightness, U and V represent chroma.
  • YCbCr is a format of YUV color encoding, and YUV is often used to represent YCbCr.
  • Color deviation correction the process of adjusting the chroma. Due to the Hunter effect, after the SDR image is converted into an HDR image, as the overall brightness changes, the hue and saturation of the color subjectively perceived by the human eye will also change, and an obvious color shift can be perceived. Therefore, it is necessary to Perform color cast correction.
  • Lab color space CIE LAB, also called CIE L*a*b*.
  • Lab consists of a brightness channel and two color channels.
  • each color is represented by three components: L, a, and b, where L represents brightness; a represents the component from green to red; b represents the component from blue to yellow.
  • CIE XYZ A color space created by the International Commission on Illumination (CIE) in 1931.
  • the CIE XYZ space contains all colors that can be seen by the human eye. Each color is represented by three components: X, Y, and Z.
  • the brightness When converting SDR video to HDR images, the brightness will be increased due to brightness dynamic range expansion. After the brightness is increased, the corresponding chroma will change and the image saturation will increase. For most image areas, increasing saturation can make the image more natural and have better visual effects. However, for skin color areas, it will cause the skin color area to appear reddish, making the image less realistic and inconsistent with the real scene.
  • a color deviation correction method is provided. After dynamically expanding the brightness of the target SDR image, the color deviation correction will be further performed on the skin color area of the portrait, so that the converted HDR image is closer to reality. Scene; and only correct the skin color area in the image, which can avoid the impact on other areas and improve the visual effect.
  • the method provided by the embodiments of the present application can be applied to the process of converting a captured SDR video into an HDR video to perform color deviation correction on the skin color area in the video frame. It can also be used for real-time conversion of live broadcast scenes. During the live broadcast process, the live broadcast image can be converted in real time. During the process of converting the SDR image into an HDR image, the color cast of the skin color area can be corrected to improve the visual effect of live broadcast viewing. .
  • the methods provided by the embodiments of the present application can also be used in other scenarios of converting SDR images/videos into HDR images/videos, which are not limited by the embodiments of the present application.
  • the method provided by the embodiment of the present application is executed by a computer device, where the computer device may have a video conversion function. It can be a smart phone, a tablet computer, a smart TV, a digital player, a laptop computer or a desktop computer, etc., which are not limited in the embodiments of the present application.
  • FIG. 1 shows a flow chart of a color shift correction method provided by an exemplary embodiment of the present application.
  • the method is used in computer equipment as an example for description. The method includes the following steps.
  • Step 101 Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters.
  • the target SDR image includes portraits.
  • the method provided by the embodiment of the present application is suitable for the process of converting an SDR image to an HDR image, where the process of converting an SDR image to an HDR image involves a brightness dynamic expansion process.
  • Brightness dynamic expansion refers to converting the SDR image into The brightness of the image extends to the brightness dynamic range supported by the HDR standard, making the image closer to the scene perceived by the human eye.
  • the chroma will increase accordingly, that is, the saturation will increase. In most scenes, increasing saturation will make the image more natural. However, for the skin color area of the portrait, the increase in saturation will cause the skin color to appear reddish, so color cast correction is required.
  • the expanded image parameters can be further corrected for color deviation, so that the converted image is closer to the scene perceived by the human eye.
  • Step 102 Select local chromaticity parameters based on the chromaticity information indicated by the image chromaticity parameters in the extended image parameters.
  • the local chromaticity parameters are the chromaticity parameters corresponding to the skin color area of the portrait.
  • the skin color of the human body has a certain color range.
  • the computer device can identify the skin color area (including the face, neck, arms, etc.) in the target SDR image according to the corresponding color range of the skin color, so as to Color cast correction for skin tone areas.
  • the extended image parameters include image chromaticity parameters corresponding to each pixel point, which are used to indicate the chromaticity information of the pixel point.
  • the computer device can determine whether the indicated pixel belongs to the color range corresponding to the skin color based on the chromaticity information of the indicated pixel. If the color range belonging to skin color is determined, it is determined that the pixel belongs to the skin color area. That is, the computer device can filter out the local chromaticity parameters according to the image chromaticity parameters and the color range of the skin color.
  • the chromaticity information indicated by the local chromaticity parameters matches the color range of the skin color.
  • the local chromaticity parameters correspond to the pixels composed of The area is the skin color area in the target SDR image, which can realize color deviation correction of the skin color area.
  • color cast correction is performed on the entire image, and color cast correction can be performed only on the skin color area, which reduces the problem of unnatural skin color caused by increased saturation and avoids the impact on other areas.
  • Step 103 Perform color deviation correction on local chromaticity parameters to obtain corrected image parameters.
  • the computer device can perform color deviation correction on the local chromaticity parameters.
  • the saturation can be reduced by reducing the chroma parameter.
  • the local chromaticity parameters can be reduced in the same proportion to complete the color deviation correction of the skin color area.
  • the computer device can also use the local chromaticity parameters according to the local chromaticity parameters.
  • the chromaticity information indicated by the chromaticity parameters corresponding to different pixel points in the chromaticity parameters determines the reduction ratio, and the color deviation is corrected according to the corresponding reduction ratio. That is, different methods are used to correct color casts in different skin color areas to make the corrected image more natural and improve the visual effect.
  • Step 104 Generate a target HDR image corresponding to the target SDR image based on the corrected image parameters.
  • the computer device can further generate a target HDR image corresponding to the target SDR image based on the corrected image parameters to complete the conversion of the SDR image.
  • the computer device can determine the skin color in the target SDR image based on the chromaticity information indicated by the chromaticity parameters in the expanded image parameters. local chromaticity parameters corresponding to the area, thereby colorizing the local chromaticity parameters Bias correction to desaturate areas of skin tone. That is, the computer equipment can determine the skin color area based on the chroma information indicated by the image chroma parameters after brightness expansion, thereby correcting the color deviation of the skin color area, reducing the problem of high saturation in the skin color area caused by the increase in brightness, and improving the visual effect . And it can only correct the skin color area to avoid affecting other areas.
  • the computer device before performing color deviation correction, the computer device first determines the skin color area in the image, thereby performing color deviation correction on the skin color area. In a possible implementation, the computer device determines whether it belongs to the skin color area based on the chromaticity information indicated by each pixel point. Exemplary embodiments will be described below.
  • FIG. 2 shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application.
  • the method is used in computer equipment as an example for description. The method includes the following steps.
  • Step 201 Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters.
  • the image parameters of the acquired target SDR image are nonlinear RGB parameters.
  • the computer device first linearizes the nonlinear RGB parameters 301 to obtain the display linear RGB parameters.
  • the display linear RGB parameters are used to indicate when displayed in the display screen. color and brightness information.
  • the color space conversion 302 will be performed to convert the display linear RGB parameters into the display linear XYZ parameters in the CIE Extended image parameters.
  • the extended image parameters are the XYZ parameters after the brightness is dynamically expanded, which belongs to the CIE XYZ space.
  • Step 202 Perform color space conversion on the extended image parameters to obtain image chromaticity parameters in Lab space.
  • the image chromaticity parameters are used to indicate image color information.
  • the image chromaticity parameters include pixel chromaticity parameters corresponding to each pixel point.
  • the image parameters consist of the brightness parameter L and the chrominance parameters a, b.
  • the chromaticity information indicated by the chromaticity parameters a and b it is determined whether it belongs to the skin color area.
  • the computer device first performs color space conversion on the extended image parameters, that is, converts the XYZ parameters corresponding to the extended image parameters in the CIE color space into L, a, and b parameters in the Lab color space.
  • the a and b parameters of each pixel constitute the image chromaticity parameters, which are used to indicate the image color information. That is, the image chromaticity parameters include the pixel chromaticity parameters corresponding to each pixel, respectively, including the a and b parameters corresponding to each pixel. .
  • Step 203 Based on the target chromaticity range, select the target chromaticity parameters from each pixel chromaticity parameter to obtain local chromaticity parameters, where the chromaticity information indicated by each target chromaticity parameter belongs to the target chromaticity range.
  • a corresponding target chromaticity range is preset for the skin color.
  • the skin color area is located in the yellowish area, as shown in Figure 4, which is a schematic diagram of the Lab color space.
  • the target chromaticity range corresponding to the skin color area can be set in the Lab color space.
  • the target chromaticity range may be shown as area 401.
  • the method of selecting the target chromaticity parameters may include steps 203a-203b (not shown in the figure):
  • Step 203a determine the angle parameter and length parameter corresponding to the chromaticity parameter of each pixel.
  • the angle parameter and the length parameter are used to indicate the chromaticity position of the chromaticity in the Lab color space.
  • the angle parameter and the length parameter are based on the a channel in the pixel chromaticity parameter.
  • the parameters are determined with the b channel parameters.
  • the target chromaticity range when determining whether the pixel chromaticity parameter (a, b) belongs to the target chromaticity range, it can be determined whether the chromaticity position of the pixel chromaticity parameter (a, b) in the Lab color space is located The target chromaticity range is within the corresponding target area in the Lab color space.
  • the computer device can determine the angle parameter and length parameter corresponding to the pixel chromaticity parameter based on the a and b channel parameters, thereby determining whether it is within the target chromaticity range based on the angle information and length information indicated by the angle parameter and the length parameter. within the corresponding target area.
  • tan ⁇ is the angle parameter
  • r 2 is the length parameter
  • Step 203b Based on the target angle range and the target length range, select the target chromaticity parameter to obtain the local chromaticity parameter.
  • the angle parameter corresponding to the target chromaticity parameter belongs to the target angle range, and the length parameter belongs to the target length range.
  • the judgment can be made based on the angle parameter and the length parameter.
  • the target area corresponding to the target chromaticity range is indicated by the target angle range and the target length range.
  • the computer device can determine that the corresponding pixel chromaticity parameter is the target chromaticity parameter, that is, it is determined to belong to the skin color area.
  • the target angle range can be 0 ⁇ tan ⁇ 2.14; the target length range can be 0 ⁇ r 2 ⁇ 36.
  • a is 30 and b is 20 in the pixel chromaticity parameters corresponding to pixel point A, it can be determined that tan ⁇ is 1.5, which belongs to the target angle range, and r 2 is 13, which belongs to the target length range, and it is determined that pixel point A belongs to the skin color area.
  • r 2 is 13 which belongs to the target length range
  • pixel point A belongs to the skin color area.
  • its corresponding pixel chromaticity parameter is the target chromaticity parameter.
  • some target chromaticity parameters belonging to the target angle range and the target length range can be obtained to form local chromaticity parameters.
  • Step 204 Perform color deviation correction on local chromaticity parameters to obtain corrected image parameters.
  • color deviation correction can be performed on each target chromaticity parameter in the local chromaticity parameters to obtain corrected corrected image parameters.
  • color shift correction process reference may be made to the following embodiments, which will not be described again in this embodiment.
  • the computer equipment needs to convert the Lab parameters corresponding to each pixel into color space and re-convert them into parameters in the CIE XYZ color space.
  • the corrected image parameters are the XYZ parameters after color space conversion.
  • Step 205 Perform color gamut conversion and non-linear conversion on the corrected image parameters to obtain a target HDR image under the HDR standard.
  • color gamut conversion 305 is performed to convert the XYZ parameters into HDR display linear RGB parameters under the Rec.2020 color space, where, the Rec.2020 color space Is the color space used in the HDR standard.
  • HDR display linear RGB parameters are obtained.
  • the computer equipment also needs to perform HDR nonlinear conversion 306 to obtain nonlinear RGB parameters corresponding to the target HDR image and complete the SDR2HDR process.
  • the computer device when performing color deviation correction on the skin color area, can determine the color deviation correction method based on different chromaticity information. Exemplary embodiments will be described below.
  • FIG. 5 shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application.
  • the method is used in computer equipment as an example for description. The method includes the following steps.
  • Step 501 Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters.
  • Step 502 Select local chromaticity parameters based on the chromaticity information indicated by the image chromaticity parameters in the extended image parameters.
  • steps 501 to 502 For the implementation of steps 501 to 502, reference can be made to the above steps 201 to 203, which will not be described again in this embodiment.
  • Step 503 Reduce each target chromaticity parameter in the local chromaticity parameters according to the target ratio to obtain corrected image parameters.
  • the parameter value corresponding to the target chroma parameter can be reduced to achieve the purpose of reducing saturation.
  • S is the target ratio, and schematically, the target ratio can be 80%.
  • the updated parameters of parameter a and parameter b of the target chromaticity parameters are obtained, while other pixel chromaticity parameters that do not belong to the target chromaticity parameters remain unchanged, and the color deviation correction is completed.
  • the corresponding image chromaticity parameters after correction are obtained, and the corrected image parameters are determined based on the corrected image chromaticity parameters.
  • the corrected image parameters are the XYZ parameters after color space conversion of the corrected image chrominance parameters.
  • Step 504 Determine the correction weight based on the chromaticity position indicated by the target chromaticity parameter.
  • the correction weight is positively correlated with the edge distance.
  • the edge distance refers to the distance between the chromaticity position and the edge corresponding to the target chromaticity range.
  • the computer device can determine the corresponding correction weight according to the chromaticity position indicated by the target chromaticity parameter, thereby determining the correction ratio based on the correction weight, and applying the correction weight to the target at different chromaticity positions. Colorimetric parameters are corrected at different scales.
  • the chromaticity position indicated by the first target chromaticity parameter is the first position 402
  • the chromaticity position indicated by the second target chromaticity parameter is the second position 403.
  • the computer device is based on the target chromaticity.
  • the chromaticity position indicated by the parameter determines the correction weight.
  • the chromaticity position is related to the distance between edges indicated by the target chromaticity range. If reduced at the same target ratio, the edges of the target chromaticity range will appear color-unsmooth.
  • the second position 403 indicated by the second target chromaticity parameter is located at the edge of the target area indicated by the target chromaticity range, which belongs to the target area. Therefore, the second target color will be Color deviation correction is performed on the chromaticity parameters.
  • the second target chromaticity parameter is reduced by 80%, and the pixel chromaticity parameters located outside the edge position and adjacent to the second target chromaticity parameter will not be adjusted.
  • the computer equipment can determine the correction weight based on the distance between the chromaticity position and the edge indicated by the target chromaticity range. The closer to the edge, the lower the correction weight, and the color. The smaller the bias adjustment ratio. It should be noted that the computer device may determine the correction weight according to the minimum value of the distance between the chromaticity position and each edge indicated by the target chromaticity range.
  • the angle weight can be determined according to the angle parameter indicated by the target chromaticity parameter, and the length weight can be determined according to the length parameter indicated by the target chromaticity parameter, so that the correction weight can be determined based on the angle weight and the length weight.
  • This method may include steps 504a to 504b (not shown in the figure):
  • Step 504a Determine the angle weight based on the angle parameter of the target chromaticity parameter.
  • the angle weight is positively correlated with the angle difference.
  • the angle difference refers to the difference between the angle parameter and the boundary parameter of the target angle range.
  • the angle weight is related to the angle difference
  • the computer device can determine the corresponding relationship between the angle weight and the angle parameter based on the angle difference between the angle parameter and the boundary parameter of the target angle range, thereby avoiding angle edge color.
  • the angle difference may be the minimum value of the difference between the angle parameter and the target angle range boundary parameter. That is, the corresponding relationship between the angle weight and the angle parameter is determined based on its distance from the target angle range.
  • the adjustment can be made at a larger reduction ratio, that is, the angle weight is larger, and if the angle parameter differs from the boundary parameter of the target angle range, When it is smaller, it indicates that it is closer to the edge. In order to smooth the angular edge, it can be adjusted with a smaller reduction ratio, that is, the angular weight is smaller.
  • the angle weight corresponding to the angle parameter is determined based on the first angle curve, and the angle parameter under the first angle curve has a positive correlation with the angle weight.
  • the angle weight corresponding to the angle parameter can be determined by the first angle curve.
  • An angle curve indicates the corresponding relationship between the angle parameter and the angle weight within the first angle range, which indicates that the angle parameter and the angle weight are positively correlated, and the angle weight is less than or equal to Weight threshold.
  • the computer device determines the angle weight as the weight threshold, and the second angle range is greater than the first angle range.
  • the angle weight is the weight threshold, that is, it is determined The angle weight is the maximum value.
  • the weight threshold can be 1.
  • the computer device determines the angle weight corresponding to the angle parameter based on the second angle curve.
  • the angle parameter under the second angle curve has a negative correlation with the angle weight.
  • the third angle The range is greater than the second angle range.
  • the third angle range is larger than the second angle range.
  • the computer device may determine the angle weight corresponding to the angle parameter based on the second angle curve.
  • the second angle curve indicates the corresponding relationship between the angle parameter and the angle weight within the third angle range, wherein the angle parameter and the angle weight are negatively correlated, and the angle The weight is less than or equal to the weight threshold.
  • f ⁇ is the angle weight.
  • the first angle range is 0 ⁇ tan ⁇ 0.132; the second angle range is 0.132 ⁇ tan ⁇ 1.73; and the third angle range is 1.73 ⁇ tan ⁇ 2.14.
  • Step 504b Determine the length weight based on the length parameter of the target chromaticity parameter.
  • the length weight is positively correlated with the length difference.
  • the length difference refers to the difference between the length parameter and the boundary parameter of the target length range.
  • the length weight is related to the length difference.
  • the computer device can determine the corresponding relationship between the length weight and the length parameter based on the length difference between the length parameter and the boundary parameter of the target length range, thereby avoiding the problem of uneven color at the length edge.
  • the length difference may be the minimum value of the difference between the length parameter and the target length range boundary parameter. That is, the corresponding relationship between the length weight and the length parameter is determined based on its distance from the target length range.
  • the length parameter differs greatly from the boundary parameter of the target length range, it indicates that it is far away from the edge, so it can be adjusted with a larger reduction ratio, that is, the length weight is larger, and if the length parameter differs from the boundary parameter of the target length range, When it is smaller, it indicates that it is closer to the edge. In order to smooth the length edge, it can be adjusted by a smaller reduction ratio, that is, the length weight is smaller.
  • the computer device determines the length weight corresponding to the length parameter based on the first length curve, and the length parameter under the first length curve has a positive correlation with the length weight.
  • the computer device can based on the first The length curve determines the length weight corresponding to the length parameter.
  • the first length curve indicates the corresponding relationship between the length parameter and the length weight within the first length range, where the length parameter and the length weight are positively correlated, and the length weight is less than or equal to the weight threshold. .
  • the length weight is determined to be the weight threshold, and the second length range is greater than the first length range.
  • the length weight can be determined to be the weight threshold, that is, it is determined The length weight is the maximum value.
  • the weight threshold can be 1.
  • the computer device determines the length weight corresponding to the length parameter based on the second length curve.
  • the length parameter under the second length curve has a negative correlation with the length weight, and the third angle range is greater than the second length curve. angle range.
  • the third length range is greater than the second length range.
  • the length weight corresponding to the length parameter can be determined with a second length curve, and the second length curve indicates the corresponding relationship between the length parameter and the length weight within the third length range, wherein the length parameter and the length weight have a negative correlation, and the length weight is less than or equal to the weight threshold.
  • the first length range is 0 ⁇ r 2 ⁇ 1
  • the second length range is 1 ⁇ r 2 ⁇ 30
  • the third length range is 30 ⁇ r 2 ⁇ 36.
  • Step 504c Determine the correction weight based on the angle weight and the length weight.
  • the computer device can determine the correction weight based on the angle weight and the length weight, and the correction weight can be the product of the angle weight and the length weight.
  • Step 505 Based on the correction weight, reduce the target chromaticity parameter to obtain the corrected image parameters.
  • the correction weight has a positive correlation with the reduction ratio.
  • the computer device reduces the target chromaticity parameter according to the correction weight, where the correction weight is used to adjust the reduction ratio of the reduced parameter value.
  • S is the reduction ratio.
  • Step 506 Perform color gamut conversion and non-linear conversion on the corrected image parameters to obtain a target HDR image under the HDR standard.
  • step 205 For the implementation of this step, reference can be made to the above-mentioned step 205, which will not be described again in this embodiment.
  • the corresponding angle weight and length weight are determined respectively based on the angle parameter and the length parameter.
  • the angle weight becomes smaller, thereby smoothing the angle edge.
  • the length parameter gradually approaches the target length range, the angle weight becomes smaller.
  • the length weight is smaller, thus smoothing the length edges, making the image after color shift adjustment more natural, and improving the visual effect.
  • the correction weight is determined only based on the chromaticity parameter, and the target chromaticity parameter is corrected based on the correction weight.
  • the pixel chromaticity parameter belongs to the target chromaticity range
  • the brightness value of the corresponding pixel may be very small, that is, the pixel is dark. In this case, it may not belong to the skin color area. Therefore, in a possible implementation, when correcting the target chromaticity parameter, a brightness parameter corresponding to the target chromaticity parameter is introduced, and the reduced target ratio is adjusted based on the brightness parameter. This method includes the following steps:
  • Step 1 Determine the brightness weight based on the target brightness parameter corresponding to each target chroma parameter in the local chroma parameter.
  • the brightness weight has a positive correlation with the pixel brightness, and the brightness weight has a positive correlation with the reduction ratio.
  • the computer equipment can determine the brightness weight according to the target brightness parameter of the pixel corresponding to the target chromaticity parameter.
  • the brightness of the pixel is darker, the probability that it is a non-skin color area is greater. Therefore, the brightness weight is correspondingly lower, thus affecting the target.
  • the chromaticity parameters are reduced by a lower percentage.
  • the method of determining the brightness weight based on the target brightness parameter L is as follows:
  • f L is the brightness weight
  • L ref is the reference brightness value
  • L ref 100.
  • the brightness weight is less than or equal to 1.
  • Step 2 Based on the brightness weight and the correction weight, reduce each target chromaticity parameter in the local chromaticity parameters to obtain the corrected image parameters.
  • the computer device determines the reduction ratio corresponding to the target chromaticity parameter based on the brightness weight and the correction weight, thereby correcting the target chromaticity parameter, and determines the corrected image parameters based on the corrected parameters.
  • the color shift correction process includes: first performing color space conversion 601, converting the XYZ parameters in the CIE XYZ space into Lab parameters in the Lab color space, and then performing color shift correction based on the Lab parameters. 602.
  • first determine whether correction is required based on the chromaticity parameters a and b that is, determine whether it belongs to the target angle range and the target length range based on the angle parameter and length parameter. If it belongs to the target angle range and If it falls within the target length range, it is determined that correction is required.
  • the angle weight and length weight are determined respectively according to parameters a and b, and the brightness weight is determined according to parameter L.
  • the reduction ratio is determined based on the angle weight, length weight, and brightness weight, and the color shift correction is performed with the reduction ratio.
  • color space conversion 603 is performed to convert the Lab parameters in the Lab color space into XYZ parameters in the CIE XYZ space.
  • the brightness parameter when correcting the target chromaticity parameter, the brightness parameter is introduced at the same time, and the brightness weight is determined based on the brightness parameter, thereby further improving the accuracy of color deviation correction based on the brightness information.
  • FIG. 7 shows a structural block diagram of a color shift correction device provided by an exemplary embodiment of the present application.
  • the device includes:
  • the dynamic expansion module 701 is configured to dynamically expand the brightness of the image parameters of the target SDR image, where the target SDR image includes portraits, to obtain the expanded image parameters;
  • the parameter selection module 702 is configured to select a local chroma parameter based on the chroma information indicated by the image chroma parameter in the extended image parameter, where the local chroma parameter is a chroma parameter corresponding to the skin color area of the portrait. ;
  • the color deviation correction module 703 is configured to perform color deviation correction on the local chromaticity parameters to obtain corrected image parameters;
  • the image generation module 704 is configured to generate a target HDR image corresponding to the target SDR image based on the corrected image parameters.
  • parameter selection module 702 is also configured as:
  • the image chromaticity parameters are used to indicate image color information.
  • the image chromaticity parameters include pixel chromaticity parameters corresponding to each pixel point. ;
  • a target chromaticity parameter is selected from each of the pixel chromaticity parameters to obtain the local chromaticity parameter, wherein the chromaticity information indicated by each of the target chromaticity parameters belongs to the target chromaticity scope.
  • parameter selection module 702 is also configured as:
  • the angle parameter and the length parameter are used to indicate the chromaticity position of the chromaticity in the Lab color space.
  • the angle parameter and the length The parameters are determined based on the a channel parameters and b channel parameters among the pixel chromaticity parameters;
  • the target chromaticity parameter is selected to obtain the local chromaticity parameter.
  • the angle parameter corresponding to the target chromaticity parameter belongs to the target angle range, and the length parameter belongs to The target length range.
  • the color shift correction module 703 is also configured to:
  • a correction weight is determined.
  • the correction weight is positively correlated with the edge distance.
  • the edge distance refers to the correspondence between the chromaticity position and the target chromaticity range. The distance between the edges;
  • the target chromaticity parameter is reduced to obtain the corrected image parameter, and the correction weight has a positive correlation with the reduction ratio.
  • the color shift correction module 703 is also configured to:
  • an angle weight is determined, the angle weight is the same as The angle difference is positively correlated, and the angle difference refers to the difference between the angle parameter and the boundary parameter of the target angle range;
  • a length weight is determined.
  • the length weight is positively correlated with the length difference.
  • the length difference refers to the distance between the length parameter and the boundary parameter of the target length range. difference;
  • the correction weight is determined based on the angle weight and the length weight.
  • the color shift correction module 703 is also configured to:
  • the angle weight corresponding to the angle parameter is determined based on the first angle curve, and the angle parameter under the first angle curve has a positive correlation with the angle weight;
  • the angle parameter belongs to a second angle range
  • the angle weight corresponding to the angle parameter is determined based on the second angle curve, and the angle parameter under the second angle curve has a negative correlation with the angle weight, so The third angular range is larger than the second angular range.
  • the color shift correction module 703 is also configured to:
  • the length weight corresponding to the length parameter is determined based on the first length curve, and the length parameter under the first length curve is positively correlated with the length weight;
  • the length parameter belongs to a second length range
  • the length weight corresponding to the length parameter is determined based on the second length curve, and the length parameter under the second length curve has a negative correlation with the length weight, so The third angle range is larger than the second angle range.
  • the color shift correction module 703 is also configured to:
  • each of the target chromaticity parameters in the local chromaticity parameters is reduced to obtain the corrected image parameters.
  • the image generation module 704 is also configured to:
  • the computer device can determine the skin color in the target SDR image based on the chromaticity information indicated by the chromaticity parameters in the expanded image parameters.
  • the local chroma parameters corresponding to the area are used to perform color deviation correction on the local chroma parameters to reduce the saturation of the skin color area. That is, the computer equipment can determine the skin color area based on the chroma information indicated by the image chroma parameters after brightness expansion, thereby correcting the color deviation of the skin color area, reducing the problem of high saturation in the skin color area caused by the increase in brightness, and improving the visual effect . and can only be used for skin color Correct the area to avoid affecting other areas.
  • the device provided in the above embodiments is only exemplified by the division of the above functional modules.
  • the above function allocation can be completed by different functional modules as needed, that is, the internal structure of the device is divided into Different functional modules to complete all or part of the functions described above.
  • the apparatus and method embodiments provided in the above embodiments belong to the same concept, and the implementation process can be found in the method embodiments, which will not be described again here.
  • An embodiment of the present application provides a computer device.
  • the computer device includes a processor and a memory. At least one instruction is stored in the memory. The at least one instruction is loaded and executed by the processor to implement the above aspects. The color shift correction method described above.
  • Embodiments of the present application provide a computer-readable storage medium in which at least one instruction is stored, and the at least one instruction is loaded and executed by a processor to implement color shift correction as described above. method.
  • Embodiments of the present application provide a computer program product or computer program.
  • the computer program product or computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium.
  • the processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the color shift correction method provided in various optional implementations of the above aspect.
  • Computer-readable media includes computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another.
  • Storage media can be any available media that can be accessed by a general purpose or special purpose computer.

Landscapes

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

Abstract

The embodiments of the present application disclose a color cast correction method and apparatus, a device, a storage medium and a program product, and belong to the technical field of images. The method comprises: dynamically expanding the brightness of an image parameter of a target SDR image to obtain an expanded image parameter, the target SDR image comprising a human portrait (101); on the basis of chrominance information indicated by an image chrominance parameter in the expanded image parameter, selecting a local chrominance parameter, the local chrominance parameter being a chrominance parameter corresponding to a skin color region of the human portrait (102); performing color cast correction on the local chrominance parameter to obtain a corrected image parameter (103); and based on the corrected image parameter, generating a target HDR image corresponding to the target SDR image (104). The embodiments of the present application allow for performing color cast correction on a skin color region, thereby reducing the problem of an increase in brightness causing higher saturation of the skin color region, thus improving visual effect.

Description

色偏校正方法、装置、设备、存储介质及程序产品Color shift correction methods, devices, equipment, storage media and program products
本申请要求于2022年06月13日提交的申请号为202210660459.9、发明名称为“色偏校正方法、装置、设备、存储介质及程序产品”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims priority to the Chinese patent application with application number 202210660459.9 and the invention title "Color deviation correction method, device, equipment, storage medium and program product" submitted on June 13, 2022, the entire content of which is incorporated by reference. in this application.
技术领域Technical field
本申请实施例涉及图像技术领域,特别涉及一种色偏校正方法、装置、设备、存储介质及程序产品。Embodiments of the present application relate to the field of image technology, and in particular to a color shift correction method, device, equipment, storage medium and program product.
背景技术Background technique
目前,存在标准动态范围(Standard Dynamic Range,SDR)显示屏与高动态范围(High Dynamic Range,HDR)显示屏对图片/视频进行显示,其中,HDR显示屏可展示更多的亮度信息,相较于SDR显示屏的展示效果更优,因此,通常将SDR图像转换为对应的HDR图像后进行显示。Currently, there are Standard Dynamic Range (SDR) displays and High Dynamic Range (HDR) displays to display pictures/videos. Among them, HDR displays can display more brightness information. Compared with The display effect is better on an SDR display. Therefore, the SDR image is usually converted into the corresponding HDR image and then displayed.
在图像转换过程中,在将亮度进行扩展后,图像的色调与饱和度将发生变换,对于图像的肤色区域,容易出现偏黄或偏红现象,因此,在图像转换过程中,需进行色偏校正。During the image conversion process, after the brightness is expanded, the hue and saturation of the image will change. For the skin color area of the image, it is easy to appear yellowish or reddish. Therefore, during the image conversion process, color cast needs to be performed. Correction.
发明内容Contents of the invention
本申请实施例提供了一种色偏校正方法、装置、设备、存储介质及程序产品,所述技术方案如下:The embodiments of the present application provide a color shift correction method, device, equipment, storage medium and program product. The technical solution is as follows:
一方面,本申请实施例提供了一种色偏校正方法,所述方法包括:On the one hand, embodiments of the present application provide a color shift correction method, which method includes:
对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数,所述目标SDR图像中包含人像;Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters, where the target SDR image contains portraits;
基于所述扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数,所述局部色度参数是所述人像的肤色区域所对应的色度参数;Based on the chromaticity information indicated by the image chromaticity parameter in the extended image parameters, select a local chromaticity parameter, where the local chromaticity parameter is a chromaticity parameter corresponding to the skin color area of the portrait;
对所述局部色度参数进行色偏校正,得到校正图像参数;Perform color deviation correction on the local chromaticity parameters to obtain corrected image parameters;
基于所述校正图像参数,生成所述目标SDR图像对应的目标HDR图像。Based on the corrected image parameters, a target HDR image corresponding to the target SDR image is generated.
另一方面,本申请实施例提供了一种色偏校正装置,所述装置包括:On the other hand, embodiments of the present application provide a color shift correction device, which includes:
动态扩展模块,配置为对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数,所述目标SDR图像中包含人像;A dynamic expansion module configured to dynamically expand the brightness of the image parameters of the target SDR image, where the target SDR image includes portraits, to obtain the expanded image parameters;
参数选取模块,配置为基于所述扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数,所述局部色度参数是所述人像的肤色区域所对应的色度参数;A parameter selection module configured to select a local chromaticity parameter based on the chromaticity information indicated by the image chromaticity parameter in the extended image parameter, where the local chromaticity parameter is a chromaticity parameter corresponding to the skin color area of the portrait;
色偏校正模块,配置为对所述局部色度参数进行色偏校正,得到校正图像参数;A color deviation correction module configured to perform color deviation correction on the local chromaticity parameters to obtain corrected image parameters;
图像生成模块,配置为基于所述校正图像参数,生成所述目标SDR图像对应的目标HDR图像。 An image generation module configured to generate a target HDR image corresponding to the target SDR image based on the corrected image parameters.
另一方面,本申请实施例提供了一种计算机设备,所述计算机设备包括处理器和存储器,所述存储器中存储有至少一条指令,所述至少一条指令由所述处理器加载并执行以实现如上述方面所述的色偏校正方法。On the other hand, embodiments of the present application provide a computer device. The computer device includes a processor and a memory. At least one instruction is stored in the memory. The at least one instruction is loaded and executed by the processor to implement Color shift correction method as described above.
另一方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质中存储有至少一条指令,所述至少一条指令由处理器加载并执行以实现如上述方面所述的色偏校正方法。On the other hand, embodiments of the present application provide a computer-readable storage medium in which at least one instruction is stored, and the at least one instruction is loaded and executed by a processor to implement the above aspects. color cast correction method.
另一方面,本申请实施例提供了一种计算机程序产品或计算机程序,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行上述方面的各种可选实现方式中提供的色偏校正方法。On the other hand, embodiments of the present application provide a computer program product or computer program. The computer program product or computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the color shift correction method provided in various optional implementations of the above aspect.
附图说明Description of the drawings
图1示出了本申请一个示例性实施例提供的色偏校正方法的流程图;Figure 1 shows a flow chart of a color shift correction method provided by an exemplary embodiment of the present application;
图2示出了本申请另一个示例性实施例提供的色偏校正方法的流程图;Figure 2 shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application;
图3示出了本申请一个示例性实施例提供的目标SDR图像转换为目标HDR图像过程的示意图;Figure 3 shows a schematic diagram of the process of converting a target SDR image into a target HDR image provided by an exemplary embodiment of the present application;
图4示出了本申请一个示例性实施例提供的Lab颜色空间下目标色度范围的示意图;Figure 4 shows a schematic diagram of the target chromaticity range in the Lab color space provided by an exemplary embodiment of the present application;
图5示出了本申请另一个示例性实施例提供的色偏校正方法的流程图;Figure 5 shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application;
图6示出了本申请一个示例性实施例提供的色偏校正过程的的示意图;Figure 6 shows a schematic diagram of the color shift correction process provided by an exemplary embodiment of the present application;
图7示出了本申请一个实施例提供的色偏校正装置的结构框图。Figure 7 shows a structural block diagram of a color shift correction device provided by an embodiment of the present application.
具体实施方式Detailed ways
为便于对本申请实施例提供方案的理解,下面对本申请实施例涉及的名词进行解释说明。In order to facilitate understanding of the solutions provided by the embodiments of the present application, the terms involved in the embodiments of the present application are explained below.
SDR:SDR通过传统的伽马gamma曲线描述图像/视频的动态范围,其中SDR内容使用8bit表示。SDR内容一般使用的色域有Rec.601、Rec.709、sRGB,不同色域对应的gamma曲线不同。SDR内容一般在亮度为100nit的屏幕上进行显示。SDR: SDR describes the dynamic range of the image/video through the traditional gamma gamma curve, where the SDR content is represented by 8bit. The color gamuts generally used for SDR content include Rec.601, Rec.709, and sRGB. Different color gamuts correspond to different gamma curves. SDR content is generally displayed on a screen with a brightness of 100nit.
HDR:HDR使用混合对数伽马方法(Hybrid Log-Gamma,HLG)或感知量化器(Perceptual Quantizer,PQ)描述图像/视频的动态范围,相较于gamma曲线,可描述的动态范围更大。本申请实施例中,动态范围是指亮度范围。即HDR标准可显示的亮度范围大于SDR标准可显示的亮度范围。HDR内容可使用10bit、12bit以及14bit表示。目前,主要使用10bit表示。HDR内容一般在亮度为1000nit-10000nit的屏幕上进行显示。HDR: HDR uses the hybrid log-gamma method (Hybrid Log-Gamma, HLG) or the perceptual quantizer (Perceptual Quantizer, PQ) to describe the dynamic range of the image/video. Compared with the gamma curve, the dynamic range that can be described is larger. In the embodiment of this application, the dynamic range refers to the brightness range. That is, the brightness range that can be displayed by the HDR standard is larger than the brightness range that can be displayed by the SDR standard. HDR content can be represented in 10bit, 12bit and 14bit. Currently, 10bit representation is mainly used. HDR content is generally displayed on a screen with a brightness of 1000nit-10000nit.
SDR2HDR:SDR转HDR,即将传统的SDR内容转换为HDR内容。SDR2HDR: SDR to HDR, which converts traditional SDR content into HDR content.
亨特效应(Hunt effect):指物体的色貌随整体亮度变化而发生明显变化,即色度随亮度的变化而变化。传统的HSV/HSL/Lab/YUV/ICbCr颜色模型虽然一定程度上能够将颜色中的亮度信息和色度信息(色相和饱和度)进行分离,但是这种分离并不完美,亮度的改变仍然会带来色度的改变。此外,人眼本身 对颜色的感知和亮度是紧密相关的,难以进行彻底分离。Hunt effect: refers to the obvious change in the color appearance of an object as the overall brightness changes, that is, the chromaticity changes with the change in brightness. Although the traditional HSV/HSL/Lab/YUV/ICbCr color model can separate the brightness information and chroma information (hue and saturation) in the color to a certain extent, this separation is not perfect, and changes in brightness will still cause Bring about a change in color. In addition, the human eye itself The perception of color and brightness are closely related and difficult to completely separate.
YUV颜色编码:一种颜色编码方法,常用于影像处理组件中。其中,Y表示亮度,U和V表示色度。YUV color coding: A color coding method commonly used in image processing components. Among them, Y represents brightness, U and V represent chroma.
YCbCr颜色编码:YCbCr是YUV颜色编码的一种格式,经常使用YUV来代表YCbCr。YCbCr color encoding: YCbCr is a format of YUV color encoding, and YUV is often used to represent YCbCr.
色偏校正:即对色度进行调整的过程。由于亨特效应,在将SDR图像转换为HDR图像后,随着整体亮度的改变,人眼主观感知的颜色的色相和饱和度也会发生变化,能感知到明显的色彩偏移,因此,需进行色偏校正。Color deviation correction: the process of adjusting the chroma. Due to the Hunter effect, after the SDR image is converted into an HDR image, as the overall brightness changes, the hue and saturation of the color subjectively perceived by the human eye will also change, and an obvious color shift can be perceived. Therefore, it is necessary to Perform color cast correction.
Lab颜色空间:即CIE LAB,也称CIE L*a*b*。Lab由一个亮度通道与两个颜色通道组成。在Lab颜色空间中,每个颜色用L、a、b三个分量表示,其中,L表示亮度;a表示从绿色到红色的分量;b表示从蓝色到黄色的分量。Lab color space: CIE LAB, also called CIE L*a*b*. Lab consists of a brightness channel and two color channels. In the Lab color space, each color is represented by three components: L, a, and b, where L represents brightness; a represents the component from green to red; b represents the component from blue to yellow.
CIE XYZ:由国际照明委员会(CIE)于1931年创立的一种颜色空间,CIE XYZ空间包含了人眼能够看到的全部颜色,每种颜色以X、Y、Z三个分量来表示。CIE XYZ: A color space created by the International Commission on Illumination (CIE) in 1931. The CIE XYZ space contains all colors that can be seen by the human eye. Each color is represented by three components: X, Y, and Z.
在将SDR视频转换为HDR图像时,由于进行亮度动态范围扩展,亮度将提升。而在亮度提升后,相应色度将发生变化,图像饱和度将提升。对于大部分图像区域,饱和度的提升可使图像更为自然,视觉效果较好。然而,对于肤色区域,将引起肤色区域偏红现象,图像真实性较差,与真实场景不符。When converting SDR video to HDR images, the brightness will be increased due to brightness dynamic range expansion. After the brightness is increased, the corresponding chroma will change and the image saturation will increase. For most image areas, increasing saturation can make the image more natural and have better visual effects. However, for skin color areas, it will cause the skin color area to appear reddish, making the image less realistic and inconsistent with the real scene.
因此,本申请实施例中,提供一种色偏校正方法,在对目标SDR图像进行亮度动态扩展后,将进一步对其中人像的肤色区域进行色偏校正,从而使转换后的HDR图像更贴近真实场景;且仅对图像中肤色区域进行校正,可避免对其他区域的影响,提高视觉效果。Therefore, in the embodiment of the present application, a color deviation correction method is provided. After dynamically expanding the brightness of the target SDR image, the color deviation correction will be further performed on the skin color area of the portrait, so that the converted HDR image is closer to reality. Scene; and only correct the skin color area in the image, which can avoid the impact on other areas and improve the visual effect.
本申请实施例提供的方法可适用于视频转换过程中,将已拍摄的SDR视频转换为HDR视频过程中,对视频帧中肤色区域进行色偏校正。且还可适用于直播场景的实时转换,在直播过程中,可对直播画面进行实时转换,将SDR画面转化为HDR画面过程中,对其中的肤色区域进行色偏校正,提高直播观看的视觉效果。除此之外,本申请实施例提供的方法还可用于其他将SDR图像/视频转换为HDR图像/视频的场景中,本申请实施例对此不做限定。The method provided by the embodiments of the present application can be applied to the process of converting a captured SDR video into an HDR video to perform color deviation correction on the skin color area in the video frame. It can also be used for real-time conversion of live broadcast scenes. During the live broadcast process, the live broadcast image can be converted in real time. During the process of converting the SDR image into an HDR image, the color cast of the skin color area can be corrected to improve the visual effect of live broadcast viewing. . In addition, the methods provided by the embodiments of the present application can also be used in other scenarios of converting SDR images/videos into HDR images/videos, which are not limited by the embodiments of the present application.
本申请实施例提供的方法由计算机设备执行,其中,计算机设备可具有视频转换功能。其可为智能手机、平板电脑、智能电视、数码播放器、膝上型便携计算机或台式计算机等等,本申请实施例对此不做限定。The method provided by the embodiment of the present application is executed by a computer device, where the computer device may have a video conversion function. It can be a smart phone, a tablet computer, a smart TV, a digital player, a laptop computer or a desktop computer, etc., which are not limited in the embodiments of the present application.
请参考图1,其示出了本申请一个示例性实施例提供的色偏校正方法的流程图。本实施例以该方法用于计算机设备为例进行说明。该方法包括如下步骤。Please refer to FIG. 1 , which shows a flow chart of a color shift correction method provided by an exemplary embodiment of the present application. In this embodiment, the method is used in computer equipment as an example for description. The method includes the following steps.
步骤101,对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数,目标SDR图像中包含人像。Step 101: Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters. The target SDR image includes portraits.
本申请实施例提供的方法适用于SDR图像转HDR图像过程中,其中,SDR图像转HDR图像过程中涉及亮度动态扩展过程。亮度动态扩展是指将SDR图 像的亮度扩展至HDR标准所支持的亮度动态范围,从而使图像更接近人眼所感知到的场景。而在亮度动态范围扩展后,图像亮度提升,由于亨利效应,色度将相应提升,即饱和度将提升。而在大多数场景下,饱和度提升会使图像更自然。但对于人像的肤色区域,饱和度的提升将导致肤色偏红现象,因此,需进行色偏校正。The method provided by the embodiment of the present application is suitable for the process of converting an SDR image to an HDR image, where the process of converting an SDR image to an HDR image involves a brightness dynamic expansion process. Brightness dynamic expansion refers to converting the SDR image into The brightness of the image extends to the brightness dynamic range supported by the HDR standard, making the image closer to the scene perceived by the human eye. After the brightness dynamic range is expanded, the image brightness increases, and due to the Henry effect, the chroma will increase accordingly, that is, the saturation will increase. In most scenes, increasing saturation will make the image more natural. However, for the skin color area of the portrait, the increase in saturation will cause the skin color to appear reddish, so color cast correction is required.
当对包含人像的目标SDR图像进行亮度动态扩展后,可对扩展后的扩展图像参数进一步进行色偏校正,从而使转换后图像与人眼所感知场景更加贴近。When the brightness of the target SDR image containing portraits is dynamically expanded, the expanded image parameters can be further corrected for color deviation, so that the converted image is closer to the scene perceived by the human eye.
步骤102,基于扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数,局部色度参数是人像的肤色区域所对应的色度参数。Step 102: Select local chromaticity parameters based on the chromaticity information indicated by the image chromaticity parameters in the extended image parameters. The local chromaticity parameters are the chromaticity parameters corresponding to the skin color area of the portrait.
通常情况下,人体的肤色具有一定的颜色范围,本申请实施例中,计算机设备可根据肤色对应颜色范围,识别目标SDR图像中的肤色区域(包括人脸、颈部、手臂等),从而对肤色区域进行色偏校正。Normally, the skin color of the human body has a certain color range. In the embodiment of the present application, the computer device can identify the skin color area (including the face, neck, arms, etc.) in the target SDR image according to the corresponding color range of the skin color, so as to Color cast correction for skin tone areas.
在一种可能的实施方式中,扩展图像参数包含各个像素点对应的图像色度参数,用于指示该像素点的色度信息。计算机设备可根据所指示的像素的色度信息,确定是否属于肤色对应的颜色范围。若确定属于肤色的颜色范围时,则确定该像素点属于肤色区域。即计算机设备可根据图像色度参数与肤色的颜色范围,筛选得到局部色度参数,局部色度参数所指示的色度信息与肤色的颜色范围相匹配,局部色度参数对应像素点所组成的区域即为目标SDR图像中的肤色区域,可实现对肤色区域的色偏校正。In a possible implementation, the extended image parameters include image chromaticity parameters corresponding to each pixel point, which are used to indicate the chromaticity information of the pixel point. The computer device can determine whether the indicated pixel belongs to the color range corresponding to the skin color based on the chromaticity information of the indicated pixel. If the color range belonging to skin color is determined, it is determined that the pixel belongs to the skin color area. That is, the computer device can filter out the local chromaticity parameters according to the image chromaticity parameters and the color range of the skin color. The chromaticity information indicated by the local chromaticity parameters matches the color range of the skin color. The local chromaticity parameters correspond to the pixels composed of The area is the skin color area in the target SDR image, which can realize color deviation correction of the skin color area.
相较于相关技术中,对整幅图像进行色偏校正,可仅对肤色区域进行色偏校正,降低因饱和度提升而造成肤色不自然的问题,且可避免对其他区域的影响。Compared with related technologies, color cast correction is performed on the entire image, and color cast correction can be performed only on the skin color area, which reduces the problem of unnatural skin color caused by increased saturation and avoids the impact on other areas.
步骤103,对局部色度参数进行色偏校正,得到校正图像参数。Step 103: Perform color deviation correction on local chromaticity parameters to obtain corrected image parameters.
选取得到局部色度参数后,计算机设备可对局部色度参数进行色偏校正。在一种可能的实施方式中,由于亮度的提升将带来饱和度的提升,因此,可通过降低色度参数的方式降低饱和度。After selecting and obtaining the local chromaticity parameters, the computer device can perform color deviation correction on the local chromaticity parameters. In a possible implementation, since an increase in brightness will lead to an increase in saturation, the saturation can be reduced by reducing the chroma parameter.
在一种可能的实施方式中,可对局部色度参数以相同比例进行降低,完成对肤色区域的色偏校正。而在另一种可能的实施方式中,由于局部色度参数中不同色度参数指示的色度信息不同,比如,部分色度较为鲜艳,部分色度较为暗淡,因此,计算机设备还可根据局部色度参数中不同像素点对应的色度参数所指示的色度信息确定降低比例,根据对应的降低比例进行色偏校正。即对不同肤色区域采用不同方式进行色偏校正,使校正后的图像更加自然,提高视觉效果。In a possible implementation, the local chromaticity parameters can be reduced in the same proportion to complete the color deviation correction of the skin color area. In another possible implementation, since the chromaticity information indicated by different chromaticity parameters in the local chromaticity parameters is different, for example, some chromaticities are brighter and some chromaticities are duller, therefore, the computer device can also use the local chromaticity parameters according to the local chromaticity parameters. The chromaticity information indicated by the chromaticity parameters corresponding to different pixel points in the chromaticity parameters determines the reduction ratio, and the color deviation is corrected according to the corresponding reduction ratio. That is, different methods are used to correct color casts in different skin color areas to make the corrected image more natural and improve the visual effect.
步骤104,基于校正图像参数,生成目标SDR图像对应的目标HDR图像。Step 104: Generate a target HDR image corresponding to the target SDR image based on the corrected image parameters.
得到校正图像参数后,计算机设备可进一步基于校正后的图像参数,生成目标SDR图像对应的目标HDR图像,完成SDR图像的转换。After obtaining the corrected image parameters, the computer device can further generate a target HDR image corresponding to the target SDR image based on the corrected image parameters to complete the conversion of the SDR image.
综上所述,本申请实施例中,在对目标SDR图像的图像参数进行亮度动态扩展后,计算机设备可基于扩展后图像参数中色度参数所指示的色度信息,确定目标SDR图像中肤色区域对应的局部色度参数,从而对局部色度参数进行色 偏校正,以降低肤色区域的饱和度。即计算机设备可基于亮度扩展后图像色度参数指示的色度信息,确定肤色区域,从而对肤色区域进行色偏校正,减少因亮度提升所引起的肤色区域饱和度较高的问题,提高视觉效果。且可仅对肤色区域进行校正,避免对其他区域的影响。To sum up, in the embodiments of the present application, after dynamically expanding the brightness of the image parameters of the target SDR image, the computer device can determine the skin color in the target SDR image based on the chromaticity information indicated by the chromaticity parameters in the expanded image parameters. local chromaticity parameters corresponding to the area, thereby colorizing the local chromaticity parameters Bias correction to desaturate areas of skin tone. That is, the computer equipment can determine the skin color area based on the chroma information indicated by the image chroma parameters after brightness expansion, thereby correcting the color deviation of the skin color area, reducing the problem of high saturation in the skin color area caused by the increase in brightness, and improving the visual effect . And it can only correct the skin color area to avoid affecting other areas.
本申请实施例中,进行色偏校正前,计算机设备首先确定图像中的肤色区域,从而对肤色区域进行色偏校正。在一种可能的实施方式中,计算机设备根据各个像素点所指示的色度信息,确定是否属于肤色区域。下面将以示例性实施例进行说明。In the embodiment of the present application, before performing color deviation correction, the computer device first determines the skin color area in the image, thereby performing color deviation correction on the skin color area. In a possible implementation, the computer device determines whether it belongs to the skin color area based on the chromaticity information indicated by each pixel point. Exemplary embodiments will be described below.
请参考图2,其示出了本申请另一个示例性实施例提供的色偏校正方法的流程图。本实施例以该方法用于计算机设备为例进行说明。该方法包括如下步骤。Please refer to FIG. 2 , which shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application. In this embodiment, the method is used in computer equipment as an example for description. The method includes the following steps.
步骤201,对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数。Step 201: Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters.
通常情况下,获取的目标SDR图像的图像参数为非线性RGB参数。在对图像参数进行亮度动态扩展过程中,如图3所示,计算机设备首先对非线性RGB参数进行线性化301,得到显示线性RGB参数,显示线性RGB参数即用于指示在显示屏内显示时的颜色以及亮度信息。在线性化处理后,将进行颜色空间转换302,将显示线性RGB参数转换为CIE XYZ空间下的显示线性XYZ参数,并基于显示线性XYZ参数进行亮度动态扩展(即亮度动态范围调整)303,得到扩展图像参数。扩展图像参数即为亮度动态扩展后的XYZ参数,其属于CIE XYZ空间。Usually, the image parameters of the acquired target SDR image are nonlinear RGB parameters. In the process of dynamically expanding the brightness of the image parameters, as shown in Figure 3, the computer device first linearizes the nonlinear RGB parameters 301 to obtain the display linear RGB parameters. The display linear RGB parameters are used to indicate when displayed in the display screen. color and brightness information. After the linearization process, the color space conversion 302 will be performed to convert the display linear RGB parameters into the display linear XYZ parameters in the CIE Extended image parameters. The extended image parameters are the XYZ parameters after the brightness is dynamically expanded, which belongs to the CIE XYZ space.
步骤202,对扩展图像参数进行颜色空间转换,得到Lab空间下的图像色度参数,图像色度参数用于指示图像颜色信息,图像色度参数包含各个像素点对应的像素色度参数。Step 202: Perform color space conversion on the extended image parameters to obtain image chromaticity parameters in Lab space. The image chromaticity parameters are used to indicate image color information. The image chromaticity parameters include pixel chromaticity parameters corresponding to each pixel point.
Lab空间下,图像参数由亮度参数L以及色度参数a,b组成。本申请实施例中,根据色度参数a,b所指示的色度信息,判断是否属于肤色区域。In Lab space, the image parameters consist of the brightness parameter L and the chrominance parameters a, b. In the embodiment of the present application, based on the chromaticity information indicated by the chromaticity parameters a and b, it is determined whether it belongs to the skin color area.
在一种可能的实施方式中,计算机设备首先对扩展图像参数进行颜色空间转换,即将CIE颜色空间下扩展图像参数对应的XYZ参数转换为Lab颜色空间下的L,a,b参数。In a possible implementation, the computer device first performs color space conversion on the extended image parameters, that is, converts the XYZ parameters corresponding to the extended image parameters in the CIE color space into L, a, and b parameters in the Lab color space.
其中,各个像素点的a,b参数组成图像色度参数,用于指示图像颜色信息,即图像色度参数中包含各个像素点对应像素色度参数,分别包含各个像素点对应的a,b参数。Among them, the a and b parameters of each pixel constitute the image chromaticity parameters, which are used to indicate the image color information. That is, the image chromaticity parameters include the pixel chromaticity parameters corresponding to each pixel, respectively, including the a and b parameters corresponding to each pixel. .
步骤203,基于目标色度范围,从各个像素色度参数中选取目标色度参数,得到局部色度参数,其中,各个目标色度参数所指示的色度信息属于目标色度范围。Step 203: Based on the target chromaticity range, select the target chromaticity parameters from each pixel chromaticity parameter to obtain local chromaticity parameters, where the chromaticity information indicated by each target chromaticity parameter belongs to the target chromaticity range.
在一种可能的实施方式中,对于肤色预先设定有对应的目标色度范围。通常情况下,肤色区域位于偏黄区域内,如图4所示,其为Lab颜色空间示意图,可根据肤色的颜色属性,在Lab颜色空间中设定肤色区域对应的目标色度范围。比如,目标色度范围可如区域401所示。当像素点对应的像素色度参数所指示 的颜色信息在目标色度范围对应的区域内时,确定其属于肤色区域,即可将其确定为目标色度参数。其中,基于目标色度范围,选取目标色度参数的方式可包括步骤203a-203b(图中未示出):In a possible implementation, a corresponding target chromaticity range is preset for the skin color. Normally, the skin color area is located in the yellowish area, as shown in Figure 4, which is a schematic diagram of the Lab color space. According to the color attributes of the skin color, the target chromaticity range corresponding to the skin color area can be set in the Lab color space. For example, the target chromaticity range may be shown as area 401. When the pixel chromaticity parameter corresponding to the pixel points indicates When the color information is within the area corresponding to the target chromaticity range, it is determined to belong to the skin color area, and it can be determined as the target chromaticity parameter. Among them, based on the target chromaticity range, the method of selecting the target chromaticity parameters may include steps 203a-203b (not shown in the figure):
步骤203a,确定各个像素色度参数对应的角度参数以及长度参数,角度参数以及长度参数用于指示色度在Lab颜色空间内的色度位置,角度参数以及长度参数根据像素色度参数中a通道参数与b通道参数确定。Step 203a, determine the angle parameter and length parameter corresponding to the chromaticity parameter of each pixel. The angle parameter and the length parameter are used to indicate the chromaticity position of the chromaticity in the Lab color space. The angle parameter and the length parameter are based on the a channel in the pixel chromaticity parameter. The parameters are determined with the b channel parameters.
在一种可能的实施方式中,在确定像素色度参数(a,b)是否属于目标色度范围时,可判断像素色度参数(a,b)在Lab颜色空间内的色度位置是否位于目标色度范围在Lab颜色空间内对应的目标区域内。In a possible implementation, when determining whether the pixel chromaticity parameter (a, b) belongs to the target chromaticity range, it can be determined whether the chromaticity position of the pixel chromaticity parameter (a, b) in the Lab color space is located The target chromaticity range is within the corresponding target area in the Lab color space.
可选的,计算机设备可根据a,b通道参数,确定像素色度参数对应的角度参数以及长度参数,从而根据角度参数与长度参数所指示的角度信息以及长度信息,确定是否位于目标色度范围对应的目标区域内。Optionally, the computer device can determine the angle parameter and length parameter corresponding to the pixel chromaticity parameter based on the a and b channel parameters, thereby determining whether it is within the target chromaticity range based on the angle information and length information indicated by the angle parameter and the length parameter. within the corresponding target area.
其中,根据参数a,b确定角度参数以及长度参数的方式如下所示:

Among them, the way to determine the angle parameter and length parameter according to the parameters a and b is as follows:

其中,tanθ即为角度参数,r2即为长度参数。Among them, tanθ is the angle parameter, and r 2 is the length parameter.
即本申请实施例中,无需直接计算角度信息以及长度信息,减少复杂的计算过程,节省计算开销。That is to say, in the embodiment of the present application, there is no need to directly calculate the angle information and length information, thereby reducing the complex calculation process and saving calculation overhead.
步骤203b,基于目标角度范围与目标长度范围,选取目标色度参数,得到局部色度参数,目标色度参数对应的角度参数属于目标角度范围,且长度参数属于目标长度范围。Step 203b: Based on the target angle range and the target length range, select the target chromaticity parameter to obtain the local chromaticity parameter. The angle parameter corresponding to the target chromaticity parameter belongs to the target angle range, and the length parameter belongs to the target length range.
在一种可能的实施方式中,在得到各个像素点对应的角度参数以及长度参数后,可根据角度参数以及长度参数进行判断。可选的,目标色度范围对应的目标区域通过目标角度范围以及目标长度范围指示。当角度参数属于目标角度范围,且长度参数属于目标长度范围时,计算机设备即可确定对应的像素色度参数为目标色度参数,即确定属于肤色区域。In a possible implementation, after obtaining the angle parameter and length parameter corresponding to each pixel point, the judgment can be made based on the angle parameter and the length parameter. Optionally, the target area corresponding to the target chromaticity range is indicated by the target angle range and the target length range. When the angle parameter belongs to the target angle range and the length parameter belongs to the target length range, the computer device can determine that the corresponding pixel chromaticity parameter is the target chromaticity parameter, that is, it is determined to belong to the skin color area.
示意性的,目标角度范围可为0<tanθ<2.14;目标长度范围可为0<r2<36。当像素点A对应的像素色度参数中a为30,b为20时,则可确定tanθ为1.5,属于目标角度范围,且r2为13,属于目标长度范围,确定像素点A属于肤色区域,其对应的像素色度参数为目标色度参数。Illustratively, the target angle range can be 0<tanθ<2.14; the target length range can be 0<r 2 <36. When a is 30 and b is 20 in the pixel chromaticity parameters corresponding to pixel point A, it can be determined that tanθ is 1.5, which belongs to the target angle range, and r 2 is 13, which belongs to the target length range, and it is determined that pixel point A belongs to the skin color area. , and its corresponding pixel chromaticity parameter is the target chromaticity parameter.
在基于各个像素点的像素色度参数所指示的角度参数与长度参数筛选后,可得到部分属于目标角度范围以及目标长度范围的目标色度参数,组成局部色度参数。After filtering based on the angle parameters and length parameters indicated by the pixel chromaticity parameters of each pixel, some target chromaticity parameters belonging to the target angle range and the target length range can be obtained to form local chromaticity parameters.
步骤204,对局部色度参数进行色偏校正,得到校正图像参数。Step 204: Perform color deviation correction on local chromaticity parameters to obtain corrected image parameters.
在选取得到局部色度参数后,可对局部色度参数中各个目标色度参数进行色偏校正,得到校正后的校正图像参数。色偏校正过程可参考下述实施例,本实施例不再赘述。 After the local chromaticity parameters are selected and obtained, color deviation correction can be performed on each target chromaticity parameter in the local chromaticity parameters to obtain corrected corrected image parameters. For the color shift correction process, reference may be made to the following embodiments, which will not be described again in this embodiment.
需要说明的是,在进行色偏校正后,计算机设备需将各个像素点对应的Lab参数进行颜色空间转换,重新转换为CIE XYZ颜色空间下的参数。校正图像参数即为颜色空间转换后的XYZ参数。It should be noted that after color shift correction, the computer equipment needs to convert the Lab parameters corresponding to each pixel into color space and re-convert them into parameters in the CIE XYZ color space. The corrected image parameters are the XYZ parameters after color space conversion.
步骤205,对校正图像参数进行色域转换以及非线性转换,得到HDR标准下的目标HDR图像。Step 205: Perform color gamut conversion and non-linear conversion on the corrected image parameters to obtain a target HDR image under the HDR standard.
在SDR2HDR过程中,如图3所示,在进行色偏校正304后,进行色域转换305,将XYZ参数转换为Rec.2020颜色空间下的HDR显示线性RGB参数,其中,Rec.2020颜色空间是HDR标准中使用的颜色空间。色域转换后,得到HDR显示线性RGB参数,计算机设备还需进行HDR非线性化转换306,得到目标HDR图像对应的非线性RGB参数,完成SDR2HDR过程。In the SDR2HDR process, as shown in Figure 3, after color shift correction 304, color gamut conversion 305 is performed to convert the XYZ parameters into HDR display linear RGB parameters under the Rec.2020 color space, where, the Rec.2020 color space Is the color space used in the HDR standard. After color gamut conversion, HDR display linear RGB parameters are obtained. The computer equipment also needs to perform HDR nonlinear conversion 306 to obtain nonlinear RGB parameters corresponding to the target HDR image and complete the SDR2HDR process.
在一种可能的实施方式中,对肤色区域进行色偏校正时,计算机设备可根据色度信息的不同,确定色偏校正的方式。下面将以示例性实施例进行说明。In a possible implementation, when performing color deviation correction on the skin color area, the computer device can determine the color deviation correction method based on different chromaticity information. Exemplary embodiments will be described below.
请参考图5,其示出了本申请另一个示例性实施例提供的色偏校正方法的流程图。本实施例以该方法用于计算机设备为例进行说明。该方法包括如下步骤。Please refer to FIG. 5 , which shows a flow chart of a color shift correction method provided by another exemplary embodiment of the present application. In this embodiment, the method is used in computer equipment as an example for description. The method includes the following steps.
步骤501,对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数。Step 501: Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters.
步骤502,基于扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数。Step 502: Select local chromaticity parameters based on the chromaticity information indicated by the image chromaticity parameters in the extended image parameters.
步骤501至步骤502的实施方式可参考上述步骤201至203,本实施例不再赘述。For the implementation of steps 501 to 502, reference can be made to the above steps 201 to 203, which will not be described again in this embodiment.
步骤503,以目标比例降低局部色度参数中各个目标色度参数,得到校正图像参数。Step 503: Reduce each target chromaticity parameter in the local chromaticity parameters according to the target ratio to obtain corrected image parameters.
由于亮度提升引起饱和度提升,因此,可降低目标色度参数对应的参数值,从而达到降低饱和度的目的。在一种可能的实施方式中,计算机设备可以目标比例降低各个目标色度参数对应的参数值。如下式所示:
anew=a*S
bnew=b*S
Since the increase in brightness causes an increase in saturation, the parameter value corresponding to the target chroma parameter can be reduced to achieve the purpose of reducing saturation. In a possible implementation, the computer device can reduce the parameter value corresponding to each target chromaticity parameter at a target ratio. As shown in the following formula:
a new =a*S
b new =b*S
其中,S即为目标比例,示意性的,目标比例可为80%。Among them, S is the target ratio, and schematically, the target ratio can be 80%.
在对目标色度参数进行色偏校正后,得到目标色度参数的参数a以及参数b更新后的参数,而其他不属于目标色度参数的像素色度参数保持不变,完成色偏校正,得到校正后对应的图像色度参数,从而根据校正后的图像色度参数,确定校正图像参数。校正图像参数即为对校正后的图像色度参数进行颜色空间转换后的XYZ参数。After color deviation correction is performed on the target chromaticity parameters, the updated parameters of parameter a and parameter b of the target chromaticity parameters are obtained, while other pixel chromaticity parameters that do not belong to the target chromaticity parameters remain unchanged, and the color deviation correction is completed. The corresponding image chromaticity parameters after correction are obtained, and the corrected image parameters are determined based on the corrected image chromaticity parameters. The corrected image parameters are the XYZ parameters after color space conversion of the corrected image chrominance parameters.
步骤504,基于目标色度参数所指示的色度位置,确定校正权重,校正权重与边缘距离呈正相关关系,边缘距离是指色度位置与目标色度范围对应的边缘间的距离。Step 504: Determine the correction weight based on the chromaticity position indicated by the target chromaticity parameter. The correction weight is positively correlated with the edge distance. The edge distance refers to the distance between the chromaticity position and the edge corresponding to the target chromaticity range.
对于不同目标色度参数,目标色度参数所指示在Lab颜色空间内的色度位置不同,目标色度参数所对应的色彩鲜艳程度不同,若以相同的目标比例对各 个目标色度参数降低,可能存在色偏校正后图像不自然的现象。因此,在另一种可能的实施方式中,计算机设备可根据目标色度参数所指示的色度位置,确定其对应的校正权重,从而基于校正权重确定校正比例,对不同色度位置处的目标色度参数以不同比例进行校正。如图4所示,其中,第一目标色度参数所指示的色度位置为第一位置402,第二目标色度参数所指示的色度位置为第二位置403,计算机设备根据目标色度参数所指示的色度位置,确定校正权重。For different target chromaticity parameters, the chromaticity positions indicated by the target chromaticity parameters in the Lab color space are different, and the color brightness corresponding to the target chromaticity parameters is different. If the same target ratio is used to compare each If the target chromaticity parameters are reduced, the image may be unnatural after color shift correction. Therefore, in another possible implementation, the computer device can determine the corresponding correction weight according to the chromaticity position indicated by the target chromaticity parameter, thereby determining the correction ratio based on the correction weight, and applying the correction weight to the target at different chromaticity positions. Colorimetric parameters are corrected at different scales. As shown in Figure 4, the chromaticity position indicated by the first target chromaticity parameter is the first position 402, and the chromaticity position indicated by the second target chromaticity parameter is the second position 403. The computer device is based on the target chromaticity. The chromaticity position indicated by the parameter determines the correction weight.
且确定校正权重时,色度位置与目标色度范围所指示的边缘间距离相关。若以相同的目标比例降低,目标色度范围边缘将出现色彩不平滑的现象。示意性的,如图4所示,第二目标色度参数所指示的第二位置403位于目标色度范围所指示的目标区域的边缘位置,其属于目标区域,因此,将对第二目标色度参数进行色偏校正,比如,以80%比例降低第二目标色度参数,而位于边缘位置外且与第二目标色度参数相邻色度位置处的像素色度参数将不进行调整,二者存在一定差距,转换后的图像色彩差异较为明显,因此,计算机设备可根据色度位置与目标色度范围所指示的边缘间距离确定校正权重,与边缘越近,校正权重越低,色偏调整比例越小。需要说明的是,计算机设备可根据色度位置与目标色度范围所指示的各个边缘间距离的最小值确定校正权重。And when determining the correction weight, the chromaticity position is related to the distance between edges indicated by the target chromaticity range. If reduced at the same target ratio, the edges of the target chromaticity range will appear color-unsmooth. Schematically, as shown in Figure 4, the second position 403 indicated by the second target chromaticity parameter is located at the edge of the target area indicated by the target chromaticity range, which belongs to the target area. Therefore, the second target color will be Color deviation correction is performed on the chromaticity parameters. For example, the second target chromaticity parameter is reduced by 80%, and the pixel chromaticity parameters located outside the edge position and adjacent to the second target chromaticity parameter will not be adjusted. There is a certain gap between the two, and the color difference of the converted image is more obvious. Therefore, the computer equipment can determine the correction weight based on the distance between the chromaticity position and the edge indicated by the target chromaticity range. The closer to the edge, the lower the correction weight, and the color. The smaller the bias adjustment ratio. It should be noted that the computer device may determine the correction weight according to the minimum value of the distance between the chromaticity position and each edge indicated by the target chromaticity range.
在另一种可能的实施方式中,可分别根据目标色度参数所指示角度参数确定角度权重,以及根据目标色度参数所指示长度参数确定长度权重,从而根据角度权重与长度权重,确定校正权重。该方式可包括步骤504a-步骤504b(图中未示出):In another possible implementation, the angle weight can be determined according to the angle parameter indicated by the target chromaticity parameter, and the length weight can be determined according to the length parameter indicated by the target chromaticity parameter, so that the correction weight can be determined based on the angle weight and the length weight. . This method may include steps 504a to 504b (not shown in the figure):
步骤504a,基于目标色度参数的角度参数,确定角度权重,角度权重与角度差值呈正相关关系,角度差值是指角度参数与目标角度范围的边界参数间差值。Step 504a: Determine the angle weight based on the angle parameter of the target chromaticity parameter. The angle weight is positively correlated with the angle difference. The angle difference refers to the difference between the angle parameter and the boundary parameter of the target angle range.
在一种可能的实施方式中,角度权重与角度差值相关,计算机设备可根据角度参数与目标角度范围的边界参数间的角度差值确定角度权重与角度参数的对应关系,从而避免角度边缘色彩不平滑的问题。其中,角度差值可为角度参数与目标角度范围边界参数间差值的最小值。即根据其与目标角度范围的距离,确定角度权重与角度参数的对应关系。若角度参数与目标角度范围的边界参数相差较大时,表明与边缘相距较远,从而可以较大的降低比例进行调整,即角度权重较大,而若角度参数与目标角度范围的边界参数相差较小时,表明与边缘相距较近,为使角度边缘平滑,可以较小的降低比例进行调整,即角度权重较小。In a possible implementation, the angle weight is related to the angle difference, and the computer device can determine the corresponding relationship between the angle weight and the angle parameter based on the angle difference between the angle parameter and the boundary parameter of the target angle range, thereby avoiding angle edge color. Not smooth problem. The angle difference may be the minimum value of the difference between the angle parameter and the target angle range boundary parameter. That is, the corresponding relationship between the angle weight and the angle parameter is determined based on its distance from the target angle range. If the angle parameter differs greatly from the boundary parameter of the target angle range, it indicates that it is far away from the edge, so the adjustment can be made at a larger reduction ratio, that is, the angle weight is larger, and if the angle parameter differs from the boundary parameter of the target angle range, When it is smaller, it indicates that it is closer to the edge. In order to smooth the angular edge, it can be adjusted with a smaller reduction ratio, that is, the angular weight is smaller.
可选的,在角度参数属于第一角度范围的情况下,基于第一角度曲线确定角度参数对应的角度权重,第一角度曲线下的角度参数与角度权重呈正相关关系。Optionally, when the angle parameter belongs to the first angle range, the angle weight corresponding to the angle parameter is determined based on the first angle curve, and the angle parameter under the first angle curve has a positive correlation with the angle weight.
在角度参数属于第一角度范围的情况下,角度参数逐渐增大时,其与目标角度范围的边界参数的差值逐渐增大,因此,可以第一角度曲线确定角度参数对应的角度权重,第一角度曲线指示在第一角度范围内角度参数与角度权重的对应关系,其指示角度参数与角度权重为正相关关系,且角度权重小于或等于 权重阈值。在角度参数属于第一角度范围内的情况下,角度参数越大,与目标角度范围的边缘差值越大,相应的角度权重越大。When the angle parameter belongs to the first angle range, when the angle parameter gradually increases, the difference between it and the boundary parameter of the target angle range gradually increases. Therefore, the angle weight corresponding to the angle parameter can be determined by the first angle curve. An angle curve indicates the corresponding relationship between the angle parameter and the angle weight within the first angle range, which indicates that the angle parameter and the angle weight are positively correlated, and the angle weight is less than or equal to Weight threshold. When the angle parameter belongs to the first angle range, the larger the angle parameter is, the larger the edge difference from the target angle range is, and the greater the corresponding angle weight is.
可选的,在角度参数属于第二角度范围的情况下,计算机设备确定角度权重为权重阈值,第二角度范围大于第一角度范围。Optionally, when the angle parameter belongs to the second angle range, the computer device determines the angle weight as the weight threshold, and the second angle range is greater than the first angle range.
在角度参数属于第二角度范围的情况下,第二角度范围大于第一角度范围,角度参数与目标角度范围的边界参数的差值相对较大,因此,可确定角度权重为权重阈值,即确定角度权重为最大值,可选的,权重阈值可为1。When the angle parameter belongs to the second angle range, the second angle range is larger than the first angle range, and the difference between the angle parameter and the boundary parameter of the target angle range is relatively large. Therefore, it can be determined that the angle weight is the weight threshold, that is, it is determined The angle weight is the maximum value. Optional, the weight threshold can be 1.
可选的,在角度参数属于第三角度范围的情况下,计算机设备基于第二角度曲线确定角度参数对应的角度权重,第二角度曲线下的角度参数与角度权重呈负相关关系,第三角度范围大于第二角度范围。Optionally, when the angle parameter belongs to the third angle range, the computer device determines the angle weight corresponding to the angle parameter based on the second angle curve. The angle parameter under the second angle curve has a negative correlation with the angle weight. The third angle The range is greater than the second angle range.
在角度参数属于第三角度范围的情况下,第三角度范围大于第二角度范围,在角度参数逐渐增大的情况下,角度参数与目标角度范围的边界参数的差值逐渐减小,因此,计算机设备可以基于第二角度曲线确定角度参数对应的角度权重,第二角度曲线指示在第三角度范围内角度参数与角度权重的对应关系,其中,角度参数与角度权重为负相关关系,且角度权重小于或等于权重阈值。在角度参数属于第三角度范围内的情况下,角度参数越大,与目标角度范围的边缘差值越小,相应的角度权重越小。When the angle parameter belongs to the third angle range, the third angle range is larger than the second angle range. When the angle parameter gradually increases, the difference between the angle parameter and the boundary parameter of the target angle range gradually decreases. Therefore, The computer device may determine the angle weight corresponding to the angle parameter based on the second angle curve. The second angle curve indicates the corresponding relationship between the angle parameter and the angle weight within the third angle range, wherein the angle parameter and the angle weight are negatively correlated, and the angle The weight is less than or equal to the weight threshold. When the angle parameter belongs to the third angle range, the larger the angle parameter is, the smaller the edge difference with the target angle range is, and the smaller the corresponding angle weight is.
示意性的,基于角度参数确定角度权重的方式如下:
Schematically, the way to determine the angle weight based on the angle parameters is as follows:
其中,fθ即为角度权重。第一角度范围为0<tanθ<0.132;第二角度范围为0.132≤tanθ≤1.73;第三角度范围为1.73<tanθ<2.14。Among them, f θ is the angle weight. The first angle range is 0<tanθ<0.132; the second angle range is 0.132≤tanθ≤1.73; and the third angle range is 1.73<tanθ<2.14.
步骤504b,基于目标色度参数的长度参数,确定长度权重,长度权重与长度差值呈正相关关系,长度差值是指长度参数与目标长度范围的边界参数间差值。Step 504b: Determine the length weight based on the length parameter of the target chromaticity parameter. The length weight is positively correlated with the length difference. The length difference refers to the difference between the length parameter and the boundary parameter of the target length range.
同样的,长度权重与长度差值相关,计算机设备可根据长度参数与目标长度范围的边界参数间的长度差值确定长度权重与长度参数的对应关系,从而避免长度边缘色彩不平滑的问题。其中,长度差值可为长度参数与目标长度范围边界参数间差值的最小值。即根据其与目标长度范围的距离,确定长度权重与长度参数的对应关系。若长度参数与目标长度范围的边界参数相差较大时,表明与边缘相距较远,从而可以较大的降低比例进行调整,即长度权重较大,而若长度参数与目标长度范围的边界参数相差较小时,表明与边缘相距较近,为使长度边缘平滑,可以较小的降低比例进行调整,即长度权重较小。Similarly, the length weight is related to the length difference. The computer device can determine the corresponding relationship between the length weight and the length parameter based on the length difference between the length parameter and the boundary parameter of the target length range, thereby avoiding the problem of uneven color at the length edge. The length difference may be the minimum value of the difference between the length parameter and the target length range boundary parameter. That is, the corresponding relationship between the length weight and the length parameter is determined based on its distance from the target length range. If the length parameter differs greatly from the boundary parameter of the target length range, it indicates that it is far away from the edge, so it can be adjusted with a larger reduction ratio, that is, the length weight is larger, and if the length parameter differs from the boundary parameter of the target length range, When it is smaller, it indicates that it is closer to the edge. In order to smooth the length edge, it can be adjusted by a smaller reduction ratio, that is, the length weight is smaller.
可选的,在长度参数属于第一长度范围的情况下,计算机设备基于第一长度曲线确定长度参数对应的长度权重,第一长度曲线下的长度参数与长度权重呈正相关关系。Optionally, when the length parameter belongs to the first length range, the computer device determines the length weight corresponding to the length parameter based on the first length curve, and the length parameter under the first length curve has a positive correlation with the length weight.
在长度参数属于第一长度范围的情况下,长度参数逐渐增大时,长度参数与目标长度范围的边界参数的差值逐渐增大,因此,计算机设备可以基于第一 长度曲线确定长度参数对应的长度权重,第一长度曲线指示在第一长度范围内长度参数与长度权重的对应关系,其中,长度参数与长度权重为正相关关系,且长度权重小于或等于权重阈值。在长度参数属于第一长度范围内的情况下,长度参数越大,与目标长度范围的边缘差值越大,相应的长度权重越大。In the case where the length parameter belongs to the first length range, when the length parameter gradually increases, the difference between the length parameter and the boundary parameter of the target length range gradually increases. Therefore, the computer device can based on the first The length curve determines the length weight corresponding to the length parameter. The first length curve indicates the corresponding relationship between the length parameter and the length weight within the first length range, where the length parameter and the length weight are positively correlated, and the length weight is less than or equal to the weight threshold. . When the length parameter belongs to the first length range, the larger the length parameter is, the larger the edge difference from the target length range is, and the corresponding length weight is larger.
可选的,在长度参数属于第二长度范围的情况下,确定长度权重为权重阈值,第二长度范围大于第一长度范围。Optionally, when the length parameter belongs to the second length range, the length weight is determined to be the weight threshold, and the second length range is greater than the first length range.
在长度参数属于第二长度范围的情况下,第二长度范围大于第一长度范围,长度参数与目标长度范围的边界参数的差值相对较大,因此,可确定长度权重为权重阈值,即确定长度权重为最大值,可选的,权重阈值可为1。When the length parameter belongs to the second length range, the second length range is greater than the first length range, and the difference between the length parameter and the boundary parameter of the target length range is relatively large. Therefore, the length weight can be determined to be the weight threshold, that is, it is determined The length weight is the maximum value. Optional, the weight threshold can be 1.
在长度参数属于第三长度范围的情况下,计算机设备基于第二长度曲线确定长度参数对应的长度权重,第二长度曲线下的长度参数与长度权重呈负相关关系,第三角度范围大于第二角度范围。When the length parameter belongs to the third length range, the computer device determines the length weight corresponding to the length parameter based on the second length curve. The length parameter under the second length curve has a negative correlation with the length weight, and the third angle range is greater than the second length curve. angle range.
在长度参数属于第三长度范围的情况下,第三长度范围大于第二长度范围,在长度参数逐渐增大的情况下,长度参数与目标长度范围的边界参数的差值逐渐减小,因此,可以第二长度曲线确定长度参数对应的长度权重,第二长度曲线指示在第三长度范围内长度参数与长度权重的对应关系,其中,长度参数与长度权重为负相关关系,且长度权重小于或等于权重阈值。在长度参数属于第三长度范围内的情况下,长度参数越大,与目标长度范围的边缘差值越小,相应的长度权重越小。When the length parameter belongs to the third length range, the third length range is greater than the second length range. When the length parameter gradually increases, the difference between the length parameter and the boundary parameter of the target length range gradually decreases. Therefore, The length weight corresponding to the length parameter can be determined with a second length curve, and the second length curve indicates the corresponding relationship between the length parameter and the length weight within the third length range, wherein the length parameter and the length weight have a negative correlation, and the length weight is less than or equal to the weight threshold. When the length parameter belongs to the third length range, the larger the length parameter, the smaller the edge difference with the target length range, and the smaller the corresponding length weight.
示意性的,基于长度参数确定长度权重的方式如下:
Schematically, the way to determine the length weight based on the length parameter is as follows:
其中,为长度权重。第一长度范围为0<r2<1,第二长度范围为1≤r2≤30,第三长度范围为30<r2<36。in, is the length weight. The first length range is 0<r 2 <1, the second length range is 1≤r 2 ≤30, and the third length range is 30<r 2 <36.
步骤504c,基于角度权重与长度权重,确定校正权重。Step 504c: Determine the correction weight based on the angle weight and the length weight.
在得到角度权重与校正权重后,计算机设备可基于角度权重与长度权重,确定校正权重,校正权重可为角度权重与长度权重的乘积。After obtaining the angle weight and the correction weight, the computer device can determine the correction weight based on the angle weight and the length weight, and the correction weight can be the product of the angle weight and the length weight.
步骤505,基于校正权重,降低目标色度参数,得到校正图像参数,校正权重与降低比例呈正相关关系。Step 505: Based on the correction weight, reduce the target chromaticity parameter to obtain the corrected image parameters. The correction weight has a positive correlation with the reduction ratio.
计算机设备根据校正权重,降低目标色度参数,其中,校正权重用于调整降低参数值的降低比例,校正权重越高,降低比例越大。The computer device reduces the target chromaticity parameter according to the correction weight, where the correction weight is used to adjust the reduction ratio of the reduced parameter value. The higher the correction weight, the greater the reduction ratio.
可选的,基于校正权重,降低目标色度参数的方式如下:
S=1-0.2*fθ*fr2
anew=a*S
bnew=b*S
Optional, based on the correction weight, the method of reducing the target chromaticity parameters is as follows:
S=1-0.2*f θ *f r2
a new =a*S
b new =b*S
其中,S即为降低比例。Among them, S is the reduction ratio.
步骤506,对校正图像参数进行色域转换以及非线性转换,得到HDR标准下的目标HDR图像。 Step 506: Perform color gamut conversion and non-linear conversion on the corrected image parameters to obtain a target HDR image under the HDR standard.
本步骤实施方式可参考上述步骤205,本实施例不再赘述。For the implementation of this step, reference can be made to the above-mentioned step 205, which will not be described again in this embodiment.
本实施例中,分别根据角度参数以及长度参数确定对应的角度权重以及长度权重,在角度参数逐渐接近目标角度范围时,角度权重越小,从而使角度边缘平滑,在长度参数逐渐接近目标长度范围时,长度权重越小,从而使长度边缘平滑,使色偏调整后的图像更加自然,提高视觉效果。In this embodiment, the corresponding angle weight and length weight are determined respectively based on the angle parameter and the length parameter. When the angle parameter gradually approaches the target angle range, the angle weight becomes smaller, thereby smoothing the angle edge. When the length parameter gradually approaches the target length range, the angle weight becomes smaller. When , the length weight is smaller, thus smoothing the length edges, making the image after color shift adjustment more natural, and improving the visual effect.
上述实施例中,在对目标色度参数进行调整时,仅根据色度参数,确定校正权重,并基于校正权重校正目标色度参数。而在一种可能的情况下,当像素色度参数属于目标色度范围时,其对应像素点的亮度值可能很小,即该像素点较暗,这种情况下,可能并非属于肤色区域,因此,在一种可能的实施方式中,在对目标色度参数进行校正时,引入目标色度参数对应的亮度参数,基于亮度参数调整降低的目标比例。该方式包括如下步骤:In the above embodiment, when adjusting the target chromaticity parameter, the correction weight is determined only based on the chromaticity parameter, and the target chromaticity parameter is corrected based on the correction weight. In one possible case, when the pixel chromaticity parameter belongs to the target chromaticity range, the brightness value of the corresponding pixel may be very small, that is, the pixel is dark. In this case, it may not belong to the skin color area. Therefore, in a possible implementation, when correcting the target chromaticity parameter, a brightness parameter corresponding to the target chromaticity parameter is introduced, and the reduced target ratio is adjusted based on the brightness parameter. This method includes the following steps:
步骤一、基于局部色度参数中各个目标色度参数对应的目标亮度参数,确定亮度权重,亮度权重与像素亮度呈正相关关系,亮度权重与降低比例呈正相关关系。Step 1: Determine the brightness weight based on the target brightness parameter corresponding to each target chroma parameter in the local chroma parameter. The brightness weight has a positive correlation with the pixel brightness, and the brightness weight has a positive correlation with the reduction ratio.
计算机设备可根据目标色度参数对应像素点的目标亮度参数,确定亮度权重,在像素亮度越暗的情况下,其为非肤色区域的概率越大,因此,亮度权重相应越低,从而对目标色度参数降低的降低比例越低。The computer equipment can determine the brightness weight according to the target brightness parameter of the pixel corresponding to the target chromaticity parameter. When the brightness of the pixel is darker, the probability that it is a non-skin color area is greater. Therefore, the brightness weight is correspondingly lower, thus affecting the target. The chromaticity parameters are reduced by a lower percentage.
可选的,基于目标亮度参数L确定亮度权重的方式如下:
Optionally, the method of determining the brightness weight based on the target brightness parameter L is as follows:
其中,fL为亮度权重,Lref为参考亮度值,Lref=100。Among them, f L is the brightness weight, L ref is the reference brightness value, and L ref =100.
且需要说明的是,亮度权重小于或等于1。It should be noted that the brightness weight is less than or equal to 1.
步骤二、基于亮度权重与校正权重,降低局部色度参数中各个目标色度参数,得到校正图像参数。Step 2: Based on the brightness weight and the correction weight, reduce each target chromaticity parameter in the local chromaticity parameters to obtain the corrected image parameters.
在一种可能的实施方式中,计算机设备基于亮度权重与校正权重,确定目标色度参数对应的降低比例,从而对目标色度参数进行校正,并基于校正后的参数,确定校正图像参数。In a possible implementation, the computer device determines the reduction ratio corresponding to the target chromaticity parameter based on the brightness weight and the correction weight, thereby correcting the target chromaticity parameter, and determines the corrected image parameters based on the corrected parameters.
基于亮度权重与校正权重,确定降低比例的方式如下:
S=1-0.2*fθ*fr2*fL
Based on the brightness weight and correction weight, the reduction ratio is determined as follows:
S=1-0.2*f θ *f r2 *f L
示意性的,如图6所示,色偏校正的过程包括:首先进行颜色空间转换601,将CIE XYZ空间下的XYZ参数转换为Lab颜色空间下的Lab参数,再基于Lab参数进行色偏校正602,在色偏校正过程中,首先根据色度参数a,b确定是否需进行校正,即根据所组成的角度参数与长度参数判断是否属于目标角度范围以及目标长度范围,在属于目标角度范围且属于目标长度范围的情况下,确定需进行校正。在校正时,根据参数a,b分别确定角度权重以及长度权重,且根据参数L确定亮度权重,最终基于角度权重、长度权重以及亮度权重等确定降低比例,并以降低比例进行色偏校正。校正后,再进行颜色空间转换603,将Lab颜色空间下的Lab参数转换为CIE XYZ空间下的XYZ参数。 Schematically, as shown in Figure 6, the color shift correction process includes: first performing color space conversion 601, converting the XYZ parameters in the CIE XYZ space into Lab parameters in the Lab color space, and then performing color shift correction based on the Lab parameters. 602. In the color deviation correction process, first determine whether correction is required based on the chromaticity parameters a and b, that is, determine whether it belongs to the target angle range and the target length range based on the angle parameter and length parameter. If it belongs to the target angle range and If it falls within the target length range, it is determined that correction is required. During correction, the angle weight and length weight are determined respectively according to parameters a and b, and the brightness weight is determined according to parameter L. Finally, the reduction ratio is determined based on the angle weight, length weight, and brightness weight, and the color shift correction is performed with the reduction ratio. After correction, color space conversion 603 is performed to convert the Lab parameters in the Lab color space into XYZ parameters in the CIE XYZ space.
本实施例中,在对目标色度参数进行校正时,同时引入亮度参数,并基于亮度参数确定亮度权重,从而根据亮度信息进一步提高色偏校正的准确性。In this embodiment, when correcting the target chromaticity parameter, the brightness parameter is introduced at the same time, and the brightness weight is determined based on the brightness parameter, thereby further improving the accuracy of color deviation correction based on the brightness information.
请参考图7,其示出了本申请一个示例性实施例提供的色偏校正装置的结构框图。该装置包括:Please refer to FIG. 7 , which shows a structural block diagram of a color shift correction device provided by an exemplary embodiment of the present application. The device includes:
动态扩展模块701,配置为对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数,所述目标SDR图像中包含人像;The dynamic expansion module 701 is configured to dynamically expand the brightness of the image parameters of the target SDR image, where the target SDR image includes portraits, to obtain the expanded image parameters;
参数选取模块702,配置为基于所述扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数,所述局部色度参数是所述人像的肤色区域所对应的色度参数;The parameter selection module 702 is configured to select a local chroma parameter based on the chroma information indicated by the image chroma parameter in the extended image parameter, where the local chroma parameter is a chroma parameter corresponding to the skin color area of the portrait. ;
色偏校正模块703,配置为对所述局部色度参数进行色偏校正,得到校正图像参数;The color deviation correction module 703 is configured to perform color deviation correction on the local chromaticity parameters to obtain corrected image parameters;
图像生成模块704,配置为基于所述校正图像参数,生成所述目标SDR图像对应的目标HDR图像。The image generation module 704 is configured to generate a target HDR image corresponding to the target SDR image based on the corrected image parameters.
可选的,所述参数选取模块702,还配置为:Optionally, the parameter selection module 702 is also configured as:
对所述扩展图像参数进行颜色空间转换,得到Lab空间下的图像色度参数,所述图像色度参数用于指示图像颜色信息,所述图像色度参数包含各个像素点对应的像素色度参数;Perform color space conversion on the extended image parameters to obtain image chromaticity parameters in Lab space. The image chromaticity parameters are used to indicate image color information. The image chromaticity parameters include pixel chromaticity parameters corresponding to each pixel point. ;
基于目标色度范围,从各个所述像素色度参数中选取目标色度参数,得到所述局部色度参数,其中,各个所述目标色度参数所指示的色度信息属于所述目标色度范围。Based on the target chromaticity range, a target chromaticity parameter is selected from each of the pixel chromaticity parameters to obtain the local chromaticity parameter, wherein the chromaticity information indicated by each of the target chromaticity parameters belongs to the target chromaticity scope.
可选的,所述参数选取模块702,还配置为:Optionally, the parameter selection module 702 is also configured as:
确定各个所述像素色度参数对应的角度参数以及长度参数,所述角度参数以及所述长度参数用于指示色度在所述Lab颜色空间内的色度位置,所述角度参数以及所述长度参数根据所述像素色度参数中a通道参数与b通道参数确定;Determine the angle parameter and length parameter corresponding to each pixel chromaticity parameter. The angle parameter and the length parameter are used to indicate the chromaticity position of the chromaticity in the Lab color space. The angle parameter and the length The parameters are determined based on the a channel parameters and b channel parameters among the pixel chromaticity parameters;
基于目标角度范围与目标长度范围,选取所述目标色度参数,得到所述局部色度参数,所述目标色度参数对应的所述角度参数属于所述目标角度范围,且所述长度参数属于所述目标长度范围。Based on the target angle range and the target length range, the target chromaticity parameter is selected to obtain the local chromaticity parameter. The angle parameter corresponding to the target chromaticity parameter belongs to the target angle range, and the length parameter belongs to The target length range.
可选的,所述色偏校正模块703,还配置为:Optionally, the color shift correction module 703 is also configured to:
以目标比例降低所述局部色度参数中各个所述目标色度参数,得到所述校正图像参数;Reduce each of the target chromaticity parameters in the local chromaticity parameters by a target ratio to obtain the corrected image parameters;
或,or,
基于所述目标色度参数所指示的所述色度位置,确定校正权重,所述校正权重与边缘距离呈正相关关系,所述边缘距离是指所述色度位置与所述目标色度范围对应的边缘间的距离;Based on the chromaticity position indicated by the target chromaticity parameter, a correction weight is determined. The correction weight is positively correlated with the edge distance. The edge distance refers to the correspondence between the chromaticity position and the target chromaticity range. The distance between the edges;
基于所述校正权重,降低所述目标色度参数,得到所述校正图像参数,所述校正权重与降低比例呈正相关关系。Based on the correction weight, the target chromaticity parameter is reduced to obtain the corrected image parameter, and the correction weight has a positive correlation with the reduction ratio.
可选的,所述色偏校正模块703,还配置为:Optionally, the color shift correction module 703 is also configured to:
基于所述目标色度参数的所述角度参数,确定角度权重,所述角度权重与 角度差值呈正相关关系,所述角度差值是指所述角度参数与所述目标角度范围的边界参数间差值;Based on the angle parameter of the target chromaticity parameter, an angle weight is determined, the angle weight is the same as The angle difference is positively correlated, and the angle difference refers to the difference between the angle parameter and the boundary parameter of the target angle range;
基于所述目标色度参数的所述长度参数,确定长度权重,所述长度权重与长度差值呈正相关关系,所述长度差值是指所述长度参数与所述目标长度范围的边界参数间差值;Based on the length parameter of the target chromaticity parameter, a length weight is determined. The length weight is positively correlated with the length difference. The length difference refers to the distance between the length parameter and the boundary parameter of the target length range. difference;
基于所述角度权重与所述长度权重,确定所述校正权重。The correction weight is determined based on the angle weight and the length weight.
可选的,所述色偏校正模块703,还配置为:Optionally, the color shift correction module 703 is also configured to:
在所述角度参数属于第一角度范围的情况下,基于第一角度曲线确定所述角度参数对应的所述角度权重,所述第一角度曲线下的角度参数与角度权重呈正相关关系;When the angle parameter belongs to the first angle range, the angle weight corresponding to the angle parameter is determined based on the first angle curve, and the angle parameter under the first angle curve has a positive correlation with the angle weight;
在所述角度参数属于第二角度范围的情况下,确定所述角度权重为权重阈值,所述第二角度范围大于所述第一角度范围;In the case where the angle parameter belongs to a second angle range, determine the angle weight as a weight threshold, and the second angle range is greater than the first angle range;
在所述角度参数属于第三角度范围的情况下,基于第二角度曲线确定所述角度参数对应的所述角度权重,所述第二角度曲线下的角度参数与角度权重呈负相关关系,所述第三角度范围大于所述第二角度范围。When the angle parameter belongs to the third angle range, the angle weight corresponding to the angle parameter is determined based on the second angle curve, and the angle parameter under the second angle curve has a negative correlation with the angle weight, so The third angular range is larger than the second angular range.
可选的,所述色偏校正模块703,还配置为:Optionally, the color shift correction module 703 is also configured to:
在所述长度参数属于第一长度范围的情况下,基于第一长度曲线确定所述长度参数对应的所述长度权重,所述第一长度曲线下的长度参数与长度权重呈正相关关系;When the length parameter belongs to the first length range, the length weight corresponding to the length parameter is determined based on the first length curve, and the length parameter under the first length curve is positively correlated with the length weight;
在所述长度参数属于第二长度范围的情况下,确定所述长度权重为权重阈值,所述第二长度范围大于所述第一长度范围;In the case where the length parameter belongs to a second length range, determine the length weight as a weight threshold, and the second length range is greater than the first length range;
在所述长度参数属于第三长度范围的情况下,基于第二长度曲线确定所述长度参数对应的所述长度权重,所述第二长度曲线下的长度参数与长度权重呈负相关关系,所述第三角度范围大于所述第二角度范围。When the length parameter belongs to the third length range, the length weight corresponding to the length parameter is determined based on the second length curve, and the length parameter under the second length curve has a negative correlation with the length weight, so The third angle range is larger than the second angle range.
可选的,所述色偏校正模块703,还配置为:Optionally, the color shift correction module 703 is also configured to:
基于所述局部色度参数中各个目标色度参数对应的目标亮度参数,确定亮度权重,所述亮度权重与像素亮度呈正相关关系,所述亮度权重与所述降低比例呈正相关关系;Determine a brightness weight based on the target brightness parameter corresponding to each target chroma parameter in the local chroma parameters, the brightness weight is positively correlated with the pixel brightness, and the brightness weight is positively correlated with the reduction ratio;
基于所述亮度权重与所述校正权重,降低所述局部色度参数中各个所述目标色度参数,得到所述校正图像参数。Based on the brightness weight and the correction weight, each of the target chromaticity parameters in the local chromaticity parameters is reduced to obtain the corrected image parameters.
可选的,所述图像生成模块704,还配置为:Optionally, the image generation module 704 is also configured to:
对所述校正图像参数进行色域转换以及非线性转换,得到HDR标准下的所述目标HDR图像。Perform color gamut conversion and non-linear conversion on the corrected image parameters to obtain the target HDR image under the HDR standard.
综上所述,本申请实施例中,在对目标SDR图像的图像参数进行亮度动态扩展后,计算机设备可基于扩展后图像参数中色度参数所指示的色度信息,确定目标SDR图像中肤色区域对应的局部色度参数,从而对局部色度参数进行色偏校正,以降低肤色区域的饱和度。即计算机设备可基于亮度扩展后图像色度参数指示的色度信息,确定肤色区域,从而对肤色区域进行色偏校正,减少因亮度提升所引起的肤色区域饱和度较高的问题,提高视觉效果。且可仅对肤色 区域进行校正,避免对其他区域的影响。To sum up, in the embodiments of the present application, after dynamically expanding the brightness of the image parameters of the target SDR image, the computer device can determine the skin color in the target SDR image based on the chromaticity information indicated by the chromaticity parameters in the expanded image parameters. The local chroma parameters corresponding to the area are used to perform color deviation correction on the local chroma parameters to reduce the saturation of the skin color area. That is, the computer equipment can determine the skin color area based on the chroma information indicated by the image chroma parameters after brightness expansion, thereby correcting the color deviation of the skin color area, reducing the problem of high saturation in the skin color area caused by the increase in brightness, and improving the visual effect . and can only be used for skin color Correct the area to avoid affecting other areas.
需要说明的是:上述实施例提供的装置,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。另外,上述实施例提供的装置与方法实施例属于同一构思,其实现过程详见方法实施例,这里不再赘述。It should be noted that the device provided in the above embodiments is only exemplified by the division of the above functional modules. In practical applications, the above function allocation can be completed by different functional modules as needed, that is, the internal structure of the device is divided into Different functional modules to complete all or part of the functions described above. In addition, the apparatus and method embodiments provided in the above embodiments belong to the same concept, and the implementation process can be found in the method embodiments, which will not be described again here.
本申请实施例提供了一种计算机设备,所述计算机设备包括处理器和存储器,所述存储器中存储有至少一条指令,所述至少一条指令由所述处理器加载并执行以实现如上述方面所述的色偏校正方法。An embodiment of the present application provides a computer device. The computer device includes a processor and a memory. At least one instruction is stored in the memory. The at least one instruction is loaded and executed by the processor to implement the above aspects. The color shift correction method described above.
本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质中存储有至少一条指令,所述至少一条指令由处理器加载并执行以实现如上述方面所述的色偏校正方法。Embodiments of the present application provide a computer-readable storage medium in which at least one instruction is stored, and the at least one instruction is loaded and executed by a processor to implement color shift correction as described above. method.
本申请实施例提供了一种计算机程序产品或计算机程序,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行上述方面的各种可选实现方式中提供的色偏校正方法。Embodiments of the present application provide a computer program product or computer program. The computer program product or computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the color shift correction method provided in various optional implementations of the above aspect.
本领域技术人员应该可以意识到,在上述一个或多个示例中,本申请实施例所描述的功能可以用硬件、软件、固件或它们的任意组合来实现。当使用软件实现时,可以将这些功能存储在计算机可读介质中或者作为计算机可读介质上的一个或多个指令或代码进行传输。计算机可读介质包括计算机存储介质和通信介质,其中通信介质包括便于从一个地方向另一个地方传送计算机程序的任何介质。存储介质可以是通用或专用计算机能够存取的任何可用介质。 Those skilled in the art should realize that in one or more of the above examples, the functions described in the embodiments of the present application can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. Storage media can be any available media that can be accessed by a general purpose or special purpose computer.

Claims (13)

  1. 一种色偏校正方法,其中,所述方法包括:A color shift correction method, wherein the method includes:
    对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数,所述目标SDR图像中包含人像;Dynamically expand the brightness of the image parameters of the target SDR image to obtain the expanded image parameters, where the target SDR image contains portraits;
    基于所述扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数,所述局部色度参数是所述人像的肤色区域所对应的色度参数;Based on the chromaticity information indicated by the image chromaticity parameter in the extended image parameters, select a local chromaticity parameter, where the local chromaticity parameter is a chromaticity parameter corresponding to the skin color area of the portrait;
    对所述局部色度参数进行色偏校正,得到校正图像参数;Perform color deviation correction on the local chromaticity parameters to obtain corrected image parameters;
    基于所述校正图像参数,生成所述目标SDR图像对应的目标HDR图像。Based on the corrected image parameters, a target HDR image corresponding to the target SDR image is generated.
  2. 根据权利要求1所述的方法,其中,所述基于所述扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数,包括:The method according to claim 1, wherein the selecting local chromaticity parameters based on the chromaticity information indicated by the image chromaticity parameters in the extended image parameters includes:
    对所述扩展图像参数进行颜色空间转换,得到Lab空间下的图像色度参数,所述图像色度参数用于指示图像颜色信息,所述图像色度参数包含各个像素点对应的像素色度参数;Perform color space conversion on the extended image parameters to obtain image chromaticity parameters in Lab space. The image chromaticity parameters are used to indicate image color information. The image chromaticity parameters include pixel chromaticity parameters corresponding to each pixel point. ;
    基于目标色度范围,从各个所述像素色度参数中选取目标色度参数,得到所述局部色度参数,其中,各个所述目标色度参数所指示的色度信息属于所述目标色度范围。Based on the target chromaticity range, a target chromaticity parameter is selected from each of the pixel chromaticity parameters to obtain the local chromaticity parameter, wherein the chromaticity information indicated by each of the target chromaticity parameters belongs to the target chromaticity scope.
  3. 根据权利要求2所述的方法,其中,所述基于目标色度范围,从各个所述像素色度参数中选取目标色度参数,得到所述局部色度参数,包括:The method according to claim 2, wherein, based on the target chromaticity range, selecting a target chromaticity parameter from each of the pixel chromaticity parameters to obtain the local chromaticity parameters includes:
    确定各个所述像素色度参数对应的角度参数以及长度参数,所述角度参数以及所述长度参数用于指示色度在所述Lab颜色空间内的色度位置,所述角度参数以及所述长度参数根据所述像素色度参数中a通道参数与b通道参数确定;Determine the angle parameter and length parameter corresponding to each pixel chromaticity parameter. The angle parameter and the length parameter are used to indicate the chromaticity position of the chromaticity in the Lab color space. The angle parameter and the length The parameters are determined based on the a channel parameters and b channel parameters among the pixel chromaticity parameters;
    基于目标角度范围与目标长度范围,选取所述目标色度参数,得到所述局部色度参数,所述目标色度参数对应的所述角度参数属于所述目标角度范围,且所述长度参数属于所述目标长度范围。Based on the target angle range and the target length range, the target chromaticity parameter is selected to obtain the local chromaticity parameter. The angle parameter corresponding to the target chromaticity parameter belongs to the target angle range, and the length parameter belongs to The target length range.
  4. 根据权利要求3所述的方法,其中,所述对所述局部色度参数进行色偏校正,得到校正图像参数,包括:The method according to claim 3, wherein performing color deviation correction on the local chromaticity parameters to obtain corrected image parameters includes:
    以目标比例降低所述局部色度参数中各个所述目标色度参数,得到所述校正图像参数;Reduce each of the target chromaticity parameters in the local chromaticity parameters by a target ratio to obtain the corrected image parameters;
    或,or,
    基于所述目标色度参数所指示的所述色度位置,确定校正权重,所述校正权重与边缘距离呈正相关关系,所述边缘距离是指所述色度位置与所述目标色度范围对应的边缘间的距离;Based on the chromaticity position indicated by the target chromaticity parameter, a correction weight is determined. The correction weight is positively correlated with the edge distance. The edge distance refers to the correspondence between the chromaticity position and the target chromaticity range. The distance between the edges;
    基于所述校正权重,降低所述目标色度参数,得到所述校正图像参数,所述校正权重与降低比例呈正相关关系。 Based on the correction weight, the target chromaticity parameter is reduced to obtain the corrected image parameter, and the correction weight has a positive correlation with the reduction ratio.
  5. 根据权利要求4所述的方法,其中,所述基于所述目标色度参数所指示的所述色度位置,确定校正权重,包括:The method of claim 4, wherein determining a correction weight based on the chromaticity position indicated by the target chromaticity parameter includes:
    基于所述目标色度参数的所述角度参数,确定角度权重,所述角度权重与角度差值呈正相关关系,所述角度差值是指所述角度参数与所述目标角度范围的边界参数间差值;An angle weight is determined based on the angle parameter of the target chromaticity parameter. The angle weight is positively correlated with the angle difference. The angle difference refers to the difference between the angle parameter and the boundary parameter of the target angle range. difference;
    基于所述目标色度参数的所述长度参数,确定长度权重,所述长度权重与长度差值呈正相关关系,所述长度差值是指所述长度参数与所述目标长度范围的边界参数间差值;Based on the length parameter of the target chromaticity parameter, a length weight is determined. The length weight is positively correlated with the length difference. The length difference refers to the distance between the length parameter and the boundary parameter of the target length range. difference;
    基于所述角度权重与所述长度权重,确定所述校正权重。The correction weight is determined based on the angle weight and the length weight.
  6. 根据权利要求5所述的方法,其中,所述基于所述目标色度参数的所述角度参数,确定角度权重,包括:The method of claim 5, wherein determining an angle weight based on the angle parameter of the target chromaticity parameter includes:
    在所述角度参数属于第一角度范围的情况下,基于第一角度曲线确定所述角度参数对应的所述角度权重,所述第一角度曲线下的角度参数与角度权重呈正相关关系;When the angle parameter belongs to the first angle range, the angle weight corresponding to the angle parameter is determined based on the first angle curve, and the angle parameter under the first angle curve has a positive correlation with the angle weight;
    在所述角度参数属于第二角度范围的情况下,确定所述角度权重为权重阈值,所述第二角度范围大于所述第一角度范围;In the case where the angle parameter belongs to a second angle range, determine the angle weight as a weight threshold, and the second angle range is greater than the first angle range;
    在所述角度参数属于第三角度范围的情况下,基于第二角度曲线确定所述角度参数对应的所述角度权重,所述第二角度曲线下的角度参数与角度权重呈负相关关系,所述第三角度范围大于所述第二角度范围。When the angle parameter belongs to the third angle range, the angle weight corresponding to the angle parameter is determined based on the second angle curve, and the angle parameter under the second angle curve has a negative correlation with the angle weight, so The third angle range is larger than the second angle range.
  7. 根据权利要求5所述的方法,其中,所述基于所述目标色度参数的所述长度参数,确定长度权重,包括:The method of claim 5, wherein determining a length weight based on the length parameter of the target chromaticity parameter includes:
    在所述长度参数属于第一长度范围的情况下,基于第一长度曲线确定所述长度参数对应的所述长度权重,所述第一长度曲线下的长度参数与长度权重呈正相关关系;When the length parameter belongs to the first length range, the length weight corresponding to the length parameter is determined based on the first length curve, and the length parameter under the first length curve is positively correlated with the length weight;
    在所述长度参数属于第二长度范围的情况下,确定所述长度权重为权重阈值,所述第二长度范围大于所述第一长度范围;In the case where the length parameter belongs to a second length range, determine the length weight as a weight threshold, and the second length range is greater than the first length range;
    在所述长度参数属于第三长度范围的情况下,基于第二长度曲线确定所述长度参数对应的所述长度权重,所述第二长度曲线下的长度参数与长度权重呈负相关关系,所述第三角度范围大于所述第二角度范围。When the length parameter belongs to the third length range, the length weight corresponding to the length parameter is determined based on the second length curve, and the length parameter under the second length curve has a negative correlation with the length weight, so The third angle range is larger than the second angle range.
  8. 根据权利要求4所述的方法,其中,所述对所述局部色度参数进行色偏校正,得到校正图像参数,包括:The method according to claim 4, wherein performing color deviation correction on the local chromaticity parameters to obtain corrected image parameters includes:
    基于所述局部色度参数中各个目标色度参数对应的目标亮度参数,确定亮度权重,所述亮度权重与像素亮度呈正相关关系,所述亮度权重与所述降低比例呈正相关关系;Determine a brightness weight based on the target brightness parameter corresponding to each target chroma parameter in the local chroma parameters, the brightness weight is positively correlated with the pixel brightness, and the brightness weight is positively correlated with the reduction ratio;
    基于所述亮度权重与所述校正权重,降低所述局部色度参数中各个所述目标色度参数,得到所述校正图像参数。 Based on the brightness weight and the correction weight, each of the target chromaticity parameters in the local chromaticity parameters is reduced to obtain the corrected image parameters.
  9. 根据权利要求1至8任一所述的方法,其中,所述基于所述校正图像参数,生成所述目标SDR图像对应的目标HDR图像,包括:The method according to any one of claims 1 to 8, wherein generating a target HDR image corresponding to the target SDR image based on the corrected image parameters includes:
    对所述校正图像参数进行色域转换以及非线性转换,得到HDR标准下的所述目标HDR图像。Perform color gamut conversion and non-linear conversion on the corrected image parameters to obtain the target HDR image under the HDR standard.
  10. 一种色偏校正装置,其中,所述装置包括:A color shift correction device, wherein the device includes:
    动态扩展模块,配置为对目标SDR图像的图像参数进行亮度动态扩展,得到扩展图像参数,所述目标SDR图像中包含人像;A dynamic expansion module configured to dynamically expand the brightness of the image parameters of the target SDR image, where the target SDR image includes portraits, to obtain the expanded image parameters;
    参数选取模块,配置为基于所述扩展图像参数中图像色度参数所指示的色度信息,选取局部色度参数,所述局部色度参数是所述人像的肤色区域所对应的色度参数;A parameter selection module configured to select a local chromaticity parameter based on the chromaticity information indicated by the image chromaticity parameter in the extended image parameter, where the local chromaticity parameter is a chromaticity parameter corresponding to the skin color area of the portrait;
    色偏校正模块,配置为对所述局部色度参数进行色偏校正,得到校正图像参数;A color deviation correction module configured to perform color deviation correction on the local chromaticity parameters to obtain corrected image parameters;
    图像生成模块,配置为基于所述校正图像参数,生成所述目标SDR图像对应的目标HDR图像。An image generation module configured to generate a target HDR image corresponding to the target SDR image based on the corrected image parameters.
  11. 一种计算机设备,其中,所述计算机设备包括处理器和存储器,所述存储器中存储有至少一段程序,所述至少一段程序由所述处理器加载并执行以实现如权利要求1至9任一所述的色偏校正方法。A computer device, wherein the computer device includes a processor and a memory, at least one program is stored in the memory, and the at least one program is loaded and executed by the processor to implement any one of claims 1 to 9 Described color shift correction method.
  12. 一种计算机可读存储介质,其中,所述计算机可读存储介质中存储有至少一段程序,所述至少一段程序由处理器加载并执行以实现如权利要求1至9任一所述的色偏校正方法。A computer-readable storage medium, wherein at least one program is stored in the computer-readable storage medium, and the at least one program is loaded and executed by a processor to achieve the color shift as claimed in any one of claims 1 to 9. Correction method.
  13. 一种计算机程序产品,其中,所述计算机程序产品包括计算机指令,所述计算机指令存储在计算机可读存储介质中,计算机设备的处理器从所述计算机可读存储介质读取所述计算机指令,所述处理器执行所述计算机指令以实现如权利要求1至9任一所述的色偏校正方法。 A computer program product, wherein the computer program product includes computer instructions stored in a computer-readable storage medium from which a processor of a computer device reads the computer instructions, The processor executes the computer instructions to implement the color shift correction method according to any one of claims 1 to 9.
PCT/CN2023/096662 2022-06-13 2023-05-26 Color cast correction method and apparatus, device, storage medium and program product WO2023241339A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210660459.9 2022-06-13
CN202210660459.9A CN114999363A (en) 2022-06-13 2022-06-13 Color shift correction method, device, equipment, storage medium and program product

Publications (1)

Publication Number Publication Date
WO2023241339A1 true WO2023241339A1 (en) 2023-12-21

Family

ID=83032291

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/096662 WO2023241339A1 (en) 2022-06-13 2023-05-26 Color cast correction method and apparatus, device, storage medium and program product

Country Status (2)

Country Link
CN (1) CN114999363A (en)
WO (1) WO2023241339A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114999363A (en) * 2022-06-13 2022-09-02 百果园技术(新加坡)有限公司 Color shift correction method, device, equipment, storage medium and program product

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008257680A (en) * 2007-11-06 2008-10-23 Mitsubishi Electric Corp Image processor and program storage medium
CN111263952A (en) * 2017-09-25 2020-06-09 韦斯特尔电子工业和贸易有限责任公司 Method, processing system and computer program for processing images
CN111583127A (en) * 2020-04-03 2020-08-25 浙江大华技术股份有限公司 Face skin color correction method and device, computer equipment and readable storage medium
CN113518185A (en) * 2020-12-30 2021-10-19 腾讯科技(深圳)有限公司 Video conversion processing method and device, computer readable medium and electronic equipment
CN114999363A (en) * 2022-06-13 2022-09-02 百果园技术(新加坡)有限公司 Color shift correction method, device, equipment, storage medium and program product

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007328200A (en) * 2006-06-08 2007-12-20 Sharp Corp Display apparatus
CN101251898B (en) * 2008-03-25 2010-09-15 腾讯科技(深圳)有限公司 Skin color detection method and apparatus
JP4831259B1 (en) * 2011-03-10 2011-12-07 オムロン株式会社 Image processing apparatus, image processing method, and control program
US9142012B2 (en) * 2012-05-31 2015-09-22 Apple Inc. Systems and methods for chroma noise reduction
US20130321675A1 (en) * 2012-05-31 2013-12-05 Apple Inc. Raw scaler with chromatic aberration correction
CN104038704B (en) * 2014-06-12 2018-08-07 小米科技有限责任公司 The shooting processing method and processing device of backlight portrait scene
CN104267933A (en) * 2014-08-21 2015-01-07 深圳市金立通信设备有限公司 Flashlight adjusting method
WO2019028700A1 (en) * 2017-08-09 2019-02-14 深圳市大疆创新科技有限公司 Image processing method, device and computer readable storage medium
US11321813B2 (en) * 2018-08-02 2022-05-03 Apple Inc. Angular detection using sum of absolute difference statistics systems and methods
DE102018010197A1 (en) * 2018-12-18 2020-06-18 GRID INVENT gGmbH Electronic element and electrically controlled display element
JP2021168448A (en) * 2020-04-10 2021-10-21 キヤノン株式会社 Image processing device, image processing method, and program
CN114051126B (en) * 2021-12-06 2023-12-19 北京达佳互联信息技术有限公司 Video processing method and video processing device
CN114511479A (en) * 2021-12-31 2022-05-17 阿里巴巴(中国)有限公司 Image enhancement method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008257680A (en) * 2007-11-06 2008-10-23 Mitsubishi Electric Corp Image processor and program storage medium
CN111263952A (en) * 2017-09-25 2020-06-09 韦斯特尔电子工业和贸易有限责任公司 Method, processing system and computer program for processing images
CN111583127A (en) * 2020-04-03 2020-08-25 浙江大华技术股份有限公司 Face skin color correction method and device, computer equipment and readable storage medium
CN113518185A (en) * 2020-12-30 2021-10-19 腾讯科技(深圳)有限公司 Video conversion processing method and device, computer readable medium and electronic equipment
CN114999363A (en) * 2022-06-13 2022-09-02 百果园技术(新加坡)有限公司 Color shift correction method, device, equipment, storage medium and program product

Also Published As

Publication number Publication date
CN114999363A (en) 2022-09-02

Similar Documents

Publication Publication Date Title
US10019785B2 (en) Method of processing high dynamic range images using dynamic metadata
TWI538474B (en) Methods and apparatus for image data transformation
CN109274985B (en) Video transcoding method and device, computer equipment and storage medium
KR100453038B1 (en) An apparatus and method for saturation correction in color image
US8902247B2 (en) Method and apparatus for brightness-controlling image conversion
CN107154059A (en) A kind of high dynamic range video processing method
WO2006059573A1 (en) Color adjusting device and method
WO2020007166A1 (en) Video signal processing method and apparatus
JP2009055465A (en) Image processing device and method
CN114866809B (en) Video conversion method, apparatus, device, storage medium, and program product
US7613338B2 (en) Image processing method and apparatus, program, and storage medium
JP2006229925A (en) Dynamic image saturation enhancement apparatus
CN110349097B (en) Color enhancement method for image significance and image processing device
WO2023241339A1 (en) Color cast correction method and apparatus, device, storage medium and program product
CN113132696A (en) Image tone mapping method, device, electronic equipment and storage medium
WO2019012112A1 (en) Method and system for color gamut mapping
CN107592517B (en) Skin color processing method and device
US7633555B2 (en) Method and device for automatic color correction
KR102617117B1 (en) color change color gamut mapping
WO2018114509A1 (en) Method of color gamut mapping input colors of an input ldr content into output colors forming an output hdr content
JP2012119818A (en) Image processing device, image processing method, and image processing program
TWI697873B (en) Image saturation adjusting method and device
CN116167950B (en) Image processing method, device, electronic equipment and storage medium
CN117440118B (en) Image processing method, device, electronic equipment and storage medium
US11769464B2 (en) Image processing

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: 23822909

Country of ref document: EP

Kind code of ref document: A1