WO2019041112A1 - Image processing method and apparatus - Google Patents

Image processing method and apparatus Download PDF

Info

Publication number
WO2019041112A1
WO2019041112A1 PCT/CN2017/099365 CN2017099365W WO2019041112A1 WO 2019041112 A1 WO2019041112 A1 WO 2019041112A1 CN 2017099365 W CN2017099365 W CN 2017099365W WO 2019041112 A1 WO2019041112 A1 WO 2019041112A1
Authority
WO
WIPO (PCT)
Prior art keywords
value
display content
nonlinear
display
target parameter
Prior art date
Application number
PCT/CN2017/099365
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 华为技术有限公司
Priority to PCT/CN2017/099365 priority Critical patent/WO2019041112A1/en
Publication of WO2019041112A1 publication Critical patent/WO2019041112A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/40Analysis of texture
    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G5/00Control arrangements or circuits for visual indicators common to cathode-ray tube indicators and other visual indicators

Definitions

  • the embodiments of the present invention relate to the field of image processing technologies, and in particular, to an image processing method and apparatus.
  • a High Dynamic Range (HDR) image is a type of image that represents a large dynamic range of brightness changes from direct sunlight to the darkest shadow, which can represent a range of brightness from 10 -3 to 10 6 candelas. / square meter (cd/m 2 ).
  • the dynamic range of the image that can be displayed by the display device is limited, that is, the dynamic range represented by one HDR image cannot be displayed. Therefore, it is generally necessary to compress the dynamic range of the HDR image to adjust the high dynamic range of the HDR image to display within the display capability of the display device.
  • Adjusting the dynamic range of the HDR image generally needs to be performed according to the target parameters carried in the video stream.
  • the target parameter carried by the video code stream is obtained by the image processing device by calculating pixels of all image frames in the code stream, and the target parameter is used to represent the code stream.
  • Display content performance indicators of all image frames generally, the target parameters carried by the code stream may also be referred to as metadata carried by the code stream.
  • the scenes of different image frames in the code stream may be different. Therefore, it is difficult to ensure the effect of adjusting the dynamic range of each image frame using the target parameters carried by the code stream.
  • the code stream obtained by the image processing device may be missing all or part of the target parameters. Therefore, the existing image processing device uses the target parameter adjustment of the image frame.
  • the target parameter of the image frame is used to characterize the display content performance indicator of the image frame.
  • the image processing device acquires a statistical value of the target parameter of the current image frame, and uses the reference value of the target parameter of the previous image frame and a fixed update coefficient (generally 0.1) to calculate the update of the target parameter of the current image frame.
  • the statistical value and then adjust the dynamic range of the current image frame according to the calculated updated statistical value. Due to the need for real-time playback, the statistical value of the target parameter of the current image frame is generally approximated using the target parameter of the previous adjacent frame of the current frame.
  • the value of the existing update coefficient is a fixed value. If the fixed value is selected to be small, the update value of the target value of the HDR image is slower.
  • the statistical value of the target parameter of the HDR image frame is HDR image frames cannot be synchronized, resulting in large delays in HDR image frames. If the fixed value is selected to be large, the statistical value of the target parameter of the HDR image is updated faster, so that when the image scene is switched, the statistical value of the target parameter of the HDR image frame cannot be synchronized with the HDR image frame, causing the HDR image frame to flicker. .
  • the present application provides an image processing method and apparatus, which effectively solve the problems of delay, flicker, and the like of an HDR image frame.
  • an image processing method acquires a reference value of a target parameter of a previous adjacent frame of an image frame to be processed, and calculates a to-be-processed image frame according to the pixel value of the acquired image frame. Head After the statistical value of the parameter is calculated, the absolute value of the difference between the reference value and the statistical value is calculated.
  • the target parameter is used to represent the display content performance index of the image frame; the image processing device uses the double according to the calculated absolute value.
  • a curve tangent function calculating an update coefficient, and further calculating an updated statistical value of a target parameter of the image frame to be processed by using a time domain filter function according to the update coefficient, the reference value, and the statistical value, so that the image processing device can Based on the calculated updated statistical value, a display adaptation parameter for adjusting a dynamic range and a color of the image frame to be processed is calculated, so that the image processing apparatus adjusts the image frame to be processed according to the display adaptation parameter.
  • Image scene switching refers to a significant change in the content of an image. Generally, when the image scene is switched, the difference between the statistical values of the target parameters of the adjacent two image frames is large.
  • the image processing apparatus in the embodiment of the present application calculates an absolute value of a difference between a reference value of a target parameter of a previous adjacent frame of a to-be-processed image frame and a statistical value of a target parameter of the image frame to be processed, and according to the absolute Value, using the hyperbolic tangent function to calculate the update coefficient. Since the hyperbolic tangent function has a monotonous increment, and the change characteristic of the curve is that the two ends are more intense and the middle is more gradual, the image processing apparatus can also obtain a larger update coefficient when the absolute value is large.
  • the image processing apparatus can quickly update the statistical value of the target parameter of the image frame to be processed, and quickly realize the synchronization between the statistical value of the target parameter of the image frame to be processed and the adjusted image frame to be processed, thereby effectively solving the image delay.
  • the “image processing apparatus calculates a update coefficient by using a hyperbolic tangent function according to the calculated absolute value” is: the image processing apparatus calculates according to the following formula: Update factor:
  • A is the above update coefficient
  • x is the above absolute value
  • a is the first preset value
  • b is the second preset value.
  • the image processing apparatus can accurately recognize whether or not the image scene is switched according to the hyperbolic tangent function.
  • the image processing apparatus obtains a code stream corresponding to the multiple image frames before acquiring the reference value of the target parameter of the previous adjacent frame of the image frame to be processed.
  • the image frame to be processed is the t-th image frame of the plurality of image frames corresponding to the code stream, and t is a non-negative integer.
  • the image processing apparatus may determine a parameter preset in the system as a statistical value of the target parameter of the image frame, or obtain a statistical value of the target parameter of the image frame by parsing the code stream. .
  • the image processing device needs to utilize the statistical value of the target parameter of the image frame, and the target parameter of the previous adjacent image frame of the image frame.
  • the reference value and the update coefficient are used to determine an updated statistical value of the target parameter of the image frame, and the update determined by the method is The subsequent statistics are more accurate.
  • the parameter value of the target parameter of the previous adjacent image frame of the image frame to be processed is substantially: the image processing device calculates the dynamic range and color of the previous image frame of the image frame to be processed before adjusting the dynamic range and color of the previous image frame of the image frame to be processed.
  • the updated statistical value of the target parameter of the previous adjacent image frame of the image frame to be processed is expressed by reference values.
  • the foregoing “image processing apparatus is configured according to the acquired image frame.
  • a pixel value a method for calculating a statistical value of a target parameter of an image frame to be processed”: the image processing device calculates a target parameter of the tith image frame according to a pixel value of the tith image frame in the plurality of image frames, and
  • the target parameter of the tith image frame is a statistical value of the target parameter of the image frame to be processed, and i is a positive integer.
  • the image processing apparatus processes the code stream in real time
  • the image frame to be processed includes more pixels
  • the image processing apparatus calculates the statistical value of the target parameter of the image frame to be processed, which takes a long time, and is easy to appear. Delayed issue.
  • the image processing device can calculate the statistical value of the target parameter of the image frame to be processed in time.
  • the image processing apparatus uses the target parameter of the t-ith image frame as the statistical value of the target parameter of the t-th image frame.
  • the target parameter includes a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, and a nonlinear brightness component of the display content.
  • Minimum value, display content nonlinear brightness component average value, display content nonlinear brightness component standard variance value, display content nonlinear brightness scaling quantization, display content nonlinear brightness gamma value and display content nonlinear chromaticity scaling At least one of the quantifications.
  • the non-linear luminance component of the display content is a non-linear Y component of the display content
  • the non-linear chrominance component of the display content is a non-linear Cb/Cr component of the display content.
  • an image processing apparatus including an acquisition unit, a calculation unit, and an adjustment unit.
  • the acquiring unit is configured to acquire a plurality of image frames, and obtain reference values of target parameters of a previous adjacent frame of the image frames to be processed in the plurality of image frames, where the target parameters are used to represent display content performance of the image frames. index.
  • the calculating unit is configured to calculate a statistic value of the target parameter of the image frame to be processed according to the pixel value of the acquired image frame acquired by the acquiring unit, and calculate a difference between the reference value and the statistic value acquired by the acquiring unit.
  • An absolute value of the value and a method for calculating an update coefficient by using a hyperbolic tangent function according to the absolute value, and for calculating a target parameter of the image frame to be processed by using a time domain filter function according to the update coefficient, the reference value, and the statistical value
  • the updated statistical value is used to calculate display adaptation parameters of the image frame to be processed according to the updated statistical value
  • the display adaptation parameter is used to adjust the dynamic range and color of the image frame to be processed.
  • the adjusting unit is configured to adjust an image frame to be processed according to the display adaptation parameter calculated by the calculating unit.
  • the calculating unit is specifically configured to:
  • A is the above update coefficient
  • x is the above absolute value
  • a is the first preset value
  • b is the second preset value.
  • the acquiring unit is further configured to obtain a code stream corresponding to multiple image frames, where the image frame to be processed is in a plurality of image frames corresponding to the code stream.
  • the tth image frame, t is a non-negative integer.
  • the calculating unit is further configured to use the multiple images according to the foregoing The pixel value of the tith image frame in the frame, and the target parameter of the tith image frame is calculated, and i is a positive integer.
  • the image processing apparatus in the present application further includes a determining unit, configured to use the target parameter of the t-ith image frame calculated by the calculating unit as a statistical value of a target parameter of the image frame to be processed.
  • the target parameter includes a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, and a minimum value of the nonlinear brightness component of the display content. At least one of a display content nonlinear luminance component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization .
  • the non-linear luminance component of the display content is a non-linear Y component of the display content
  • the non-linear chrominance component of the display content is a non-linear Cb/Cr component of the display content.
  • an image processing method acquires display parameters of a display device, and the image processing device acquires, from the code stream, target parameters for characterizing display content performance indicators of all image frames in the code stream;
  • the processing device calculates an adjustment coefficient according to the display parameter and the target parameter, and updates the acquired target parameter according to the adjustment coefficient;
  • the image processing device sends the updated target parameter to the display device, so that the display device adjusts according to the updated target parameter.
  • the dynamic range and color of the image frame is provided, the image processing device acquires display parameters of a display device, and the image processing device acquires, from the code stream, target parameters for characterizing display content performance indicators of all image frames in the code stream;
  • the processing device calculates an adjustment coefficient according to the display parameter and the target parameter, and updates the acquired target parameter according to the adjustment coefficient;
  • the image processing device sends the updated target parameter to the display device, so that the display device adjusts according to the updated target parameter.
  • the image processing device calculates an adjustment coefficient according to the display parameter of the current display device and the target parameter acquired from the code stream, and then updates the target parameter according to the adjustment coefficient, so that the updated target parameter is adapted to the display parameter of the display device, which is convenient.
  • the display device directly adjusts each image frame with the updated target parameters.
  • the foregoing display parameter includes a maximum display brightness value of the display device, where the target parameter includes a maximum brightness value of the display content, and the adjustment coefficient includes a linear domain adjustment coefficient and a nonlinear domain adjustment.
  • the above method "the image processing device calculates the adjustment parameter according to the display parameter” is: the image processing device calculates the linear domain adjustment coefficient and the nonlinearity respectively according to the maximum brightness value of the display content and the maximum display brightness value of the image processing device
  • the domain adjustment coefficient specifically, the image processing device calculates the linear domain adjustment coefficient by the following formula:
  • the linear_adjust_factor is the linear domain adjustment coefficient
  • the Max_Display_Target_Luminance is the maximum display brightness value of the display device
  • the Max_Content_Light_Level is the maximum brightness value of the display content.
  • Min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) indicates the minimum value of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level.
  • the image processing apparatus calculates the nonlinear domain adjustment coefficient using the following formula:
  • the nonlinear_adjust_factor is the above-mentioned nonlinear domain adjustment coefficient
  • the OETF ( ⁇ ) represents the photoelectric conversion function
  • the target parameter further includes: a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, and a display content.
  • a nonlinear luminance component average value At least one of a nonlinear luminance component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization.
  • the method for updating the target parameter according to the adjustment coefficient by the image processing apparatus is specifically: the image processing apparatus multiplies the linear domain adjustment coefficient by the maximum brightness value of the display content, and quantizes it into an unsigned integer to obtain an updated display.
  • the maximum brightness value of the content when the target parameter includes the maximum image average brightness value of the display content, the image processing device multiplies the linear domain adjustment coefficient by the maximum image average brightness value of the display content, and quantizes it into an unsigned integer to obtain an updated display.
  • the image processing device multiplies the nonlinear domain adjustment coefficient by the display content nonlinear brightness component maximum value, and quantizes to an unsigned integer, Obtaining a maximum value of the non-linear luminance component of the updated display content; when the target parameter includes a minimum value of the nonlinear luminance component of the display content, the image processing device multiplies the nonlinear domain adjustment coefficient by the minimum value of the nonlinear luminance component of the display content, and Quantify as an unsigned integer and get updated The display content non-linear luminance component minimum value; when the target parameter includes the average value of the display content nonlinear luminance component, the image processing device multiplies the nonlinear domain adjustment coefficient by the display content nonlinear luminance component average value, and quantizes to none a symbol integer, which obtains an average value of the updated non-linear luminance component of the display content; when the target parameter includes a standard variance value of the non-linear
  • an image processing apparatus comprising an acquisition unit, a calculation unit, an update unit, and a transmission unit.
  • the acquiring unit is configured to acquire display parameters of the display device, and to obtain a target parameter from the code stream, where the target parameter is used to represent a display content performance indicator of all image frames in the code stream.
  • the calculating unit is configured to calculate an adjustment coefficient according to the display parameter and the target parameter acquired by the acquiring unit.
  • the updating unit is configured to update the target parameter acquired by the acquiring unit according to the adjustment coefficient calculated by the calculating unit.
  • the sending unit is configured to send, to the display device, the updated target parameter obtained by the updating unit, so that the display device adjusts the dynamic range and color of the image frame according to the updated target parameter.
  • the foregoing display parameter includes a display device
  • the display unit displays a brightness value
  • the target parameter displays a maximum brightness value of the content.
  • the adjustment coefficient includes a linear domain adjustment coefficient and a nonlinear domain adjustment coefficient.
  • the calculation unit is specifically configured to: display a maximum brightness value according to the content and a maximum display brightness value of the image processing device. Calculate the linear domain adjustment factor using the following formula:
  • linear_adjust_factor is a linear domain adjustment coefficient
  • Max_Display_Target_Luminance is a maximum display brightness value of the display device
  • Max_Content_Light_Level is a maximum brightness value of the display content
  • min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) represents a minimum value of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level
  • the nonlinear domain adjustment coefficient is calculated by the following formula:
  • the nonlinear_adjust_factor is the nonlinear domain adjustment coefficient
  • the OETF ( ⁇ ) represents the photoelectric conversion function
  • the target parameter further includes: a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, and a non-display content. At least one of a linear luminance component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization.
  • the updating unit is specifically configured to: multiply the linear domain adjustment coefficient by the maximum brightness value of the display content, and quantize to an unsigned integer to obtain an updated maximum brightness value of the display content; and when the target parameter includes the maximum image of the display content.
  • the linear domain adjustment coefficient is multiplied by the maximum image average brightness value of the display content, and quantized into an unsigned integer to obtain an updated image maximum brightness value of the display content; when the target parameter includes the above-mentioned display content nonlinear brightness
  • the nonlinear domain adjustment coefficient is multiplied by the maximum value of the nonlinear luminance component of the display content, and quantized into an unsigned integer, and the updated maximum nonlinear luminance component of the display content is obtained; when the target parameter includes the above display content When the nonlinear luminance component is the minimum value, the nonlinear domain adjustment coefficient is multiplied by the minimum value of the nonlinear luminance component of the display content, and quantized into an unsigned integer, and
  • an image processing apparatus comprising: one or more processors, a memory, and a communication interface.
  • the memory, communication interface is coupled to one or more processors;
  • the image processing device is in communication with other devices via a communication interface;
  • the memory is for storing computer program code, the computer program code comprising instructions, when the one or more processors perform the
  • the image processing apparatus performs the image processing method as described in the foregoing first aspect and any one of its possible implementations or the image processing method as described in the foregoing third aspect and any one of its possible implementations.
  • a computer storage medium having stored therein computer program code.
  • the processor of the image processing apparatus in the fifth aspect executes the computer program code, the image processing apparatus performs the image processing method as described in the foregoing first aspect and any one of its possible implementation manners or performs the third aspect as described above And an image processing method as described in any of the possible implementations.
  • a seventh aspect further provides a computer program product comprising instructions, when executed on an image processing device, causing the image processing device to perform an image processing method as described in the first aspect above and any one of its possible implementations Or an image processing method as described in the foregoing third aspect and any one of the possible implementations.
  • the name of the above image processing apparatus is not limited to the device or the function module itself. In actual implementation, these devices or function modules may appear under other names. As long as the functions of the respective devices or functional modules are similar to the present application, they are within the scope of the claims and their equivalents.
  • FIG. 1 is a schematic structural diagram of an image processing system according to an embodiment of the present application.
  • FIG. 2 is a schematic structural diagram of hardware of an electronic device according to an embodiment of the present application.
  • FIG. 3 is a schematic flowchart 1 of an image processing method according to an embodiment of the present disclosure
  • FIG. 5 is a second schematic flowchart of an image processing method according to an embodiment of the present disclosure.
  • FIG. 6 is a schematic structural diagram of an image processing apparatus according to an embodiment of the present application.
  • the words “exemplary” or “such as” are used to mean an example, illustration, or illustration. Any embodiment or design described as “exemplary” or “for example” in the embodiments of the present application should not be construed as preferred or advantageous over other embodiments or designs. Rather, the use of the words “exemplary” or “such as” is intended to present the concepts in a particular manner.
  • the dynamic range is represented by the ratio between the maximum and minimum values of a variable.
  • the dynamic range of an image can be represented by the ratio between the maximum brightness value and the minimum brightness value of the displayed image.
  • An HDR image is an image with a very wide range of brightness, which is different from the storage format of a normal image.
  • Joint Photographic Experts Group (JPEG), image file format (Bitmap, BMP) images use 8-bit integer data to store individual channel components, for example: for red (R, R) channel components, green (Green) , G) and blue (Blue, B), each channel component of the ordinary image is saved with 8-bit shaping data, and a single pixel has a total of 24 bits.
  • Each channel component of the HDR image is represented by a floating point number, and each channel component is stored in 32-bit data, so that the dynamic range of the image is preserved to the utmost extent.
  • the luminance of the HDR image ranges from 10 -3 to 10 6 cd/m 2 , so the HDR image can realistically represent the real world.
  • the HDR image is capable of recording brightness over the entire visible range and is capable of supporting dynamic range and color gamut equivalent to the color gamut of human visual features.
  • a display device having a display dynamic range of less than 0.1 to 400 cd/m 2 is referred to as an LDR display device, and a display device having a display dynamic range of more than 0.01 to 540 cd/m 2 is referred to as an HDR display device.
  • the display dynamic range of different HDR display devices is different, for example, an HDR display device of 0.01 to 540 cd/m 2 , an HDR display device of 0.005 to 1000 cd/m 2 , and the like.
  • the display dynamic range of different HDR display devices is different. Therefore, when the HDR image is displayed by the LDR display device and the HDR display device, adaptive adjustment (compression or stretching is required). The dynamic range of the HDR image is sufficient to display the HDR image clearly and perfectly.
  • image processing devices use the target parameters of an image frame to adjust the dynamic range of an image frame.
  • the target parameter of the image frame is used to characterize the display content performance indicator of the image frame.
  • the image processing device acquires a statistical value of the target parameter of the current image frame, and uses the reference value of the target parameter of the previous image frame and a fixed update coefficient (generally 0.1) to calculate the update of the target parameter of the current image frame.
  • the statistical value and then adjust the dynamic range of the current image frame according to the calculated updated statistical value. Due to the need for real-time playback, the statistical value of the target parameter of the current image frame is generally approximated using the target parameter of the previous adjacent frame of the current frame.
  • the value of the existing update coefficient is a fixed value.
  • the fixed value is selected to be small, the update value of the target value of the HDR image is slower.
  • the statistical value of the target parameter of the HDR image frame is HDR image frames cannot be synchronized, resulting in a large delay in the HDR image.
  • the fixed value is selected to be large, the statistical value of the target parameter of the HDR image is updated faster, so that when the image scene is switched, the statistical value of the target parameter of the HDR image frame cannot be synchronized with the HDR image frame, resulting in flickering of the HDR image.
  • the image processing device provides an image processing method and device, and the image processing device obtains a reference value of a target parameter of a previous adjacent frame of the image frame to be processed and a statistical value of a target parameter of the image frame to be processed, And calculating an absolute value of the difference between the two, and then the image processing device calculates the update coefficient by using the hyperbolic tangent function, and further calculates the update coefficient, the reference value, and The statistical value is used to calculate the updated statistical value of the target parameter of the image frame to be processed by using the time domain filter function. Finally, the image processing apparatus calculates the image frame to be processed according to the calculated updated statistical value.
  • the dynamic range and color display adaptation parameters cause the image processing device to adjust the image frame to be processed according to the display adaptation parameters.
  • the image processing apparatus can also obtain an appropriate update coefficient when the absolute value is large. In this way, the image processing apparatus can quickly update the statistical value of the target parameter of the image frame to be processed, and quickly realize the statistical value of the target parameter of the image frame to be processed and the adjusted image frame to be processed. Synchronization effectively solves the problem of image delay; and it does not cause the image frame to flicker due to the excessive selection of the update coefficient, effectively avoiding the problem of image flicker.
  • FIG. 1 is a schematic structural diagram of an image processing system according to an embodiment of the present application. As shown in FIG. 1, the image processing system includes an image processing device 10 and a display device 11, and the image processing device 10 communicates with the display device 11.
  • connection between the image processing apparatus 10 and the display device 11 may be a wired connection or a wireless connection, and the connection relationship between the image processing apparatus 10 and the display apparatus 11 is conveniently and intuitively represented in FIG. It is indicated by a solid line.
  • the image processing device 10 can acquire the dynamic range supported by the display device 11, and after acquiring the code streams corresponding to the plurality of image frames, the image processing device 10 adjusts the dynamic range of each image frame to adjust The dynamic range of each subsequent image frame is matched with the dynamic range supported by the display device 11, and the image processing device 10 transmits each of the adjusted image frames to the display device 11 after acquiring the adjusted image frames. It is convenient for the display device 11 to display the adjusted image frame clearly and completely.
  • the image processing apparatus 10 may acquire a code stream corresponding to multiple image frames from a network accessed by the image processing apparatus, or may receive corresponding multiples sent by other electronic devices that establish a communication connection with the image processing apparatus.
  • the code stream of the image frame is not specifically limited in this embodiment of the present application.
  • the image processing device 10 and the display device 11 in the embodiments of the present application may each be an electronic device.
  • the image processing device 10 and the display device 11 in the embodiment of the present application may be independent of each other, or may be integrated in the same electronic device.
  • the image processing apparatus 10 and the display device 11 are independently provided as an example.
  • the image processing apparatus 10 and the display device 11 in the embodiment of the present application are independent of each other, the image processing apparatus 10 in the embodiment of the present application may be a set top box, and the display apparatus 11 may be a television set.
  • the electronic device may be a mobile phone, a camera, a wearable device, an augmented reality (AR), a virtual reality (VR) device, or a tablet.
  • Any device having an image display function such as a computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, and a personal digital assistant (PDA), is not limited in this embodiment.
  • the image processing device 10 and the display device 11 in the embodiments of the present application may each be an electronic device.
  • For the hardware structure of the electronic device in the embodiment of the present application reference may be made to the constituent components of the electronic device shown in FIG. 2.
  • the illustrated electronic device is only one example of the image processing device 10 and the display device 11, and the electronic device may have more or fewer components than those shown in the figures, and two or more may be combined. Many components, or can have different component configurations.
  • the various components shown in FIG. 2 may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
  • the electronic device may specifically include: a processor 21, a power source 22, a memory 23, an input unit 24, an audio circuit 25, and the like. It will be understood by those skilled in the art that the electronic device structure illustrated in FIG. 2 does not constitute a limitation to the electronic device, and may include more or less components than those illustrated, or a combination of certain components, or different component arrangements.
  • the processor 21 is a control center of the electronic device, and connects various parts of the entire electronic device by using various interfaces and lines.
  • the electronic device is integrally monitored by running or executing software programs and/or modules stored in the memory 23, and recalling data stored in the memory 23, performing various functions and processing data of the electronic device.
  • processor 21 may include one or more processing units.
  • the processor 21 can integrate an application processor and a modem processor.
  • the application processor mainly processes an operating system, a user interface, an application, and the like; the modem processor mainly processes wireless communication. It can be understood that the above-mentioned modem processor and processor 21 can also be independent of each other.
  • the electronic device includes a power source 22 (such as a battery) for supplying power to each component.
  • a power source 22 can be logically connected to the processor 21 through a power management system to manage functions such as charging, discharging, and power management through the power management system. .
  • the memory 23 can be used to store software programs and modules, and the processor 21 executes various functional applications and data processing of the electronic device by running software programs and modules stored in the memory 23.
  • the memory 23 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function (such as receiving data function, image processing function, etc.), and the like; the storage data area may be stored according to Data created by the use of electronic devices (such as images, videos, etc.).
  • the memory 23 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
  • the input unit 24 can be configured to receive input numeric or character information and to generate key signal inputs related to user settings and function control of the electronic device.
  • the input unit 24 may include a touch screen 241 and other input devices 242.
  • the touch screen 241 also referred to as a touch panel, can collect touch operations on or near the user (such as the operation of the user using any suitable object or accessory on the touch screen 241 or near the touch screen 241 using a finger, a stylus, etc.), and according to The preset program drives the corresponding connection device.
  • the touch screen 241 may include two parts of a touch detection device and a touch controller.
  • the touch detection device detects the touch orientation of the user, and detects a signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts the touch information into contact coordinates, and sends the touch information.
  • the processor 21 is provided and can receive commands from the processor 21 and execute them.
  • the touch screen 241 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves.
  • the audio circuit 25 can include a speaker 251 and a microphone 252 for providing an audio interface between the user and the electronic device.
  • the audio circuit 25 can transmit the converted electrical data of the received audio data to the speaker 251, and is converted by the speaker 251 into a sound signal output; on the other hand, the microphone 252 converts the collected sound signal into an electrical signal, and the audio circuit 25 After receiving, it is converted into audio data, and the audio data is output to the memory 23 for further processing.
  • the electronic device further includes a display unit 25 and a camera 26. Since the display unit 26 and the camera 27 are optional, they are indicated by dashed lines in FIG.
  • the display unit 26 can be used to display information input by the user or information provided to the user as well as various menus of the electronic device.
  • the display unit 26 can include a display panel 261.
  • the display panel 261 can be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like.
  • the touch screen 241 may cover the display panel 261, and when the touch screen 241 detects a touch operation on or near it, transmits to the processor 21 to determine the type of the touch event, and then the processor 21 displays the panel according to the type of the touch event. A corresponding visual output is provided on the 261.
  • touch screen 241 and the display panel 261 are implemented as two separate components to implement input and output functions of the electronic device, but in some embodiments, the touch screen 241 can be integrated with the display panel 261 to implement input and output of the electronic device.
  • the camera 27 can also be used as an input device for converting the collected analog video or image signal into a digital signal and storing it in the memory 23.
  • the camera 27 may include a front camera, a rear camera, a built-in camera, an external camera, and the like, which are not limited in this embodiment.
  • FIG. 3 is a schematic flowchart diagram of an image processing method according to an embodiment of the present disclosure, and the image processing method can be applied to the image processing system shown in FIG. 2 .
  • the image processing method includes:
  • the image processing device obtains a code stream corresponding to the plurality of image frames.
  • the image frames involved in the embodiments of the present application all refer to HDR image frames.
  • the image processing device may acquire a code stream corresponding to the plurality of image frames from a network accessed by the image processing device, or may receive a corresponding plurality of images sent by other electronic devices that establish a communication connection with the image processing device.
  • the code stream of the frame is not specifically limited in this embodiment of the present application.
  • the digital set top box receives the high frequency signal from the wired network, and obtains a code stream corresponding to the plurality of image frames by demodulating the received high frequency signal.
  • the image processing apparatus can acquire the dynamic range supported by the display device by communicating with the display device.
  • the image processing device performs a process of adjusting the dynamic range of each image frame. Specifically, the image processing apparatus repeatedly performs the following S301-S306 to complete the adjustment of the dynamic range of the image frame.
  • the processing procedure of the image processing apparatus is the same for each image frame.
  • the embodiment of the present application is only described by taking an example in which the image processing apparatus adjusts the dynamic range of the image frame to be processed.
  • the image frame to be processed is any one of the plurality of image frames described above.
  • the image processing apparatus acquires a reference value of a target parameter of a previous adjacent frame of the image frame to be processed.
  • the target parameter is used to characterize the display content performance indicator of the image frame.
  • the image processing apparatus cannot acquire the reference value if the image frame to be processed is the first image frame among the plurality of image frames.
  • the image processing device After obtaining the code stream corresponding to the plurality of image frames, the image processing device adjusts the dynamic range and color of each image frame in the code stream one by one.
  • the image processing apparatus performs the adjustment of the dynamic range and color of the image frame to be processed
  • the image processing apparatus has adjusted the dynamic range and color of the previous adjacent frame of the image frame to be processed, and therefore, the image processing apparatus can directly acquire the to-be-processed The reference value of the target parameter of the previous adjacent frame of the image frame.
  • the parameter value of the target parameter of the previous adjacent image frame of the image frame to be processed is substantially: the image processing device calculates the image frame to be processed before adjusting the dynamic range and color of the previous image frame of the image frame to be processed.
  • the updated statistical value of the target parameter of the previous adjacent image frame is expressed by reference values.
  • the image processing apparatus calculates a statistical value of a target parameter of the image frame to be processed according to the pixel value of the acquired image frame.
  • the pixel value of the acquired image frame may be the pixel value of the image frame to be processed.
  • the image processing device processes the obtained code stream in real time
  • the image processing device calculates the statistical value of the target parameter of the image frame to be processed in real time. For a long time, it is easy to have a delay. If the image frame to be processed includes few pixels, the image processing device can calculate the statistical data of the image frame to be processed in time.
  • the image processing apparatus calculates the ti image according to the pixel value of the tith image frame in the plurality of image frames.
  • the target parameter of the frame, and the target parameter of the ti image frame is used as the statistical value of the target parameter of the image frame to be processed, t is a non-negative integer, and i is a positive integer.
  • the target parameters in the embodiment of the present application include a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, an average value of the nonlinear brightness component of the display content, and a display.
  • the non-linear luminance components of the display content involved in the embodiments of the present application are both used to represent the non-linear Y component of the display content, and the non-linear chrominance components of the display content are used to represent the non-linear Cb/Cr component of the display content.
  • the maximum brightness value of the content which is used to indicate the maximum brightness of the displayed content.
  • the maximum brightness value of the display content is represented by Max_Content_Light_Level
  • the Max_Content_Light_Level is a 16-bit unsigned integer ranging from 1 cd/m 2 to 65535 cd/m 2 .
  • Max_Content_Light_Level is the maximum value of the maximum brightness (Picture_Max_Light_Level) of all display images of a certain display content.
  • the Picture_Max_Light_Level of the display image is calculated by calculating red (Red, R), green (Green, G), blue (for each pixel in the effective display area of the display image)
  • the maximum value maxRGB of the Blue, B) component, the value of Picture_Max_Light_Level of the display image is equal to the maximum value of maxRGB of all the pixels in the effective display area of the display image.
  • the effective display area refers to an effective display area of the display device.
  • the method for calculating the maximum value maxRGB of the R, G, and B components of each pixel in the effective display area of the display image is: converting the nonlinear (R', G', B') values of the pixel points into linear
  • the (R, G, B) value is calibrated to a value of 1 cd/m 2 ; the maximum value maxRGB of the pixel R, G, and B components is calculated from the (R, G, B) values after pixel calibration.
  • the maximum image average brightness of the displayed content is used to indicate the maximum image average brightness of the displayed content.
  • the maximum image average brightness of the display content is represented by Max_Picture_Average_Light_Level, and the Max_Picture_Average_Light_Level is a 16-bit unsigned integer ranging from 1 cd/m 2 to 65535 cd/m 2 .
  • Max_Picture_Average_Light_Level is the maximum value of the image average brightness Picture_Average_Light_Level of all display images of a certain display content.
  • the calculation method of the Picture_Average_Light_Level of the display image is: calculating the maximum value maxRGB of the R, G, and B components of each pixel in the effective display area of the display image, and the Picture_Max_Light_Level of the display image The value is equal to the average of the maxRGB of all the pixels in the effective display area of the display image.
  • content_Nonlinear_Max_Luminance is used to represent the maximum value of the nonlinear luminance component of the display content
  • Content_Nonlinear_Max_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
  • Content_Nonlinear_Min_Luminance is used to indicate the minimum value of the nonlinear luminance component of the display content
  • Content_Nonlinear_Min_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
  • Content_Nonlinear_Average_Luminance is used to represent the average value of the nonlinear luminance component of the display content
  • Content_Nonlinear_Average_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
  • nonlinear variance of the component Y component indicating that the nonlinear (R', G', B') value of the pixel of the display content is converted to a nonlinear (Y', Cb, Cr) value, and the nonlinear Y' component Standard variance.
  • content_Nonlinear_Variance_Luminance is used to represent the average value of the nonlinear luminance component of the display content
  • Content_Nonlinear_Variance_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
  • the display content is non-linear luminance scaling quantization, indicating whether the nonlinear Y' component of the pixel of the display content is quantized by luminance scaling.
  • the embodiment of the present application uses Content_Nonlinear_Scaling_Luminance to represent the non-linear luminance scaling quantization of the display content.
  • the value of Content_Nonlinear_Scaling_Luminance is 1, indicating that the pixel is subjected to luminance scaling quantization
  • the value of Content_Nonlinear_Scaling_Luminance is 0, indicating that the pixel is not subjected to luminance scaling quantization.
  • the display content is non-linear chrominance scaling quantization, indicating whether the nonlinear Y' component of the pixel of the display content is subjected to chrominance scaling quantization.
  • the embodiment of the present application uses Content_Nonlinear_Scaling_Chrominance to represent the non-linear chrominance scaling quantization of the display content.
  • the value of Content_Nonlinear_Scaling_Chrominance is 1, indicating that the pixel is subjected to chrominance scaling quantization
  • the value of Content_Nonlinear_Scaling_Chrominance is 0, indicating that the pixel is not subjected to chrominance scaling quantization.
  • a non-linear luminance gamma value is displayed, which represents a non-linear Y' component of the pixel of the displayed content, and a quantized gamma value.
  • the embodiment of the present application uses Content_Nonlinear_Scaling_Gamma to represent the non-linear luminance gamma value of the display content, and Content_Nonlinear_Scaling_Gamma is an 8-bit unsigned integer in units of 1.0/128.
  • the image processing apparatus calculates an absolute value of a difference between the reference value in the above S301 and the statistical value in the above S302.
  • the image processing device calculates the update coefficient by using the hyperbolic tangent function based on the absolute value calculated in S303.
  • the hyperbolic tangent function in the embodiment of the present application is as shown in formula (1):
  • A is the update coefficient
  • x is the above absolute value
  • a is the first preset value
  • b is the second preset value.
  • the image processing apparatus can calculate the update coefficient based on the above formula.
  • Fig. 4 shows the curve of the above formula (2).
  • the hyperbolic tangent function has a monotonous increase, and the change characteristic of the curve is that the both ends are more intense and the middle is gentle.
  • the value of the independent variable x of the above formula (2) is small, the value of the dependent variable A is also small; when the value of the independent variable x is large, the value of the dependent variable A is also large.
  • the argument x of the function represents the above absolute value
  • the value of the argument x can indirectly indicate whether a scene switch occurs between the image frame to be processed and the previous adjacent frame of the image frame to be processed. Generally, if the scenes of two adjacent image frames are different, the difference between the statistical values of the target parameters of the two image frames is large.
  • the hyperbolic tangent function is used to calculate the update coefficient. In the case where the absolute value is large, the image processing apparatus can also acquire a large update coefficient, so that the image processing apparatus can quickly update the target parameter of the image frame to be processed. Statistics.
  • the image processing apparatus calculates an updated statistical value of the target parameter of the image frame to be processed by using the time domain filter function according to the update coefficient, the reference value, and the statistical value.
  • the image processing apparatus when the image frame to be processed is the first image frame of the plurality of image frames, the image processing apparatus cannot acquire the reference value. Specifically, when the image frame to be processed is the first image frame of the plurality of image frames, the image processing apparatus may determine that the updated statistical value of the target parameter of the image frame to be processed is C 0 . Wherein C 0 is a fourth preset value, or C 0 is obtained by the image processing device by parsing the code stream.
  • the image processing apparatus calculates the updated statistical value M t of the target parameter of the image frame to be processed by using the following formula (3):
  • A is the above update coefficient
  • C t is the statistical value of the target parameter of the image frame to be processed
  • B is the third preset value
  • M t-1 is the reference of the target parameter of the previous adjacent frame of the image frame to be processed. value.
  • B 1-A.
  • the image processing apparatus can perform weighting according to the update coefficient in time, and more accurately calculate the updated statistical value M t of the target parameter of the image frame to be processed.
  • the image processing apparatus calculates a display adaptation parameter of the image frame to be processed according to the updated statistical value of the target parameter of the image frame to be processed.
  • the display adaptation parameters are used to adjust the dynamic range and color of the image frame to be processed.
  • the image processing apparatus adjusts the image frame to be processed according to the display adaptation parameter.
  • the image processing device calculates the updated statistical value of the target parameter of the image frame to be processed, according to the calculation
  • the updated statistical value completes the adjustment of the dynamic range and color of the image frame to be processed.
  • the method for the image processing device to calculate the display adaptation parameter of the image frame to be processed according to the updated statistical value of the target parameter of the image frame to be processed may refer to the existing method for calculating the display adaptation parameter, and details are not described herein again.
  • the image processing apparatus acquires the adjusted image frame to be processed, and sends the adjusted image frame to be processed to the display device.
  • the display device displays the adjusted image frame to be processed.
  • the image processing apparatus in the embodiment of the present application calculates the absolute value of the difference between the reference value and the statistical value in real time, and calculates the update coefficient by using the hyperbolic tangent function according to the absolute value. Since the hyperbolic tangent function has a monotonous increment, and the change characteristic of the curve is that the two ends are relatively sharp and the middle is gentle, the image processing apparatus can also obtain an appropriate update coefficient when the absolute value is large, so that The image processing device can quickly update the statistical value of the target parameter of the image frame to be processed, realize the synchronization between the statistical value of the target parameter of the image frame to be processed and the adjusted image frame to be processed, and effectively solve the problem of image delay, and It will not cause the image to flicker because the update value is too large, which effectively avoids the problem of image flicker.
  • the dynamic range and color of each image frame are adjusted, and the target parameters carried by the code stream are not adjusted.
  • the target parameter carried by the code stream is calculated by the image processing device according to the pixel values of all image frames in the code stream, and corresponds to all the image frames in the code stream, and is used for characterizing the display content performance index of all image frames in the code stream.
  • the target parameter carried by the code stream is static data, and the target parameter corresponds to all image frames before adjustment.
  • the image processing device In order to match the target parameter carried by the code stream stored by the image processing device with the adjusted image frame, the image processing device also needs to adaptively update the target parameter carried by the stored code stream, and send the updated target parameter to the display device.
  • the display device is further adapted to adjust the dynamic range and color of the image frame according to the updated target parameter, so that the display of the image is more clear and perfect.
  • the image processing method provided by the embodiment of the present application includes:
  • the image processing device acquires display parameters of the display device.
  • the image processing device can acquire display parameters of the display device by communicating with the display device.
  • the display parameter includes the maximum display brightness value Max_Display_Target_Luminance of the display device.
  • the image processing device obtains a code stream corresponding to the plurality of image frames, and acquires a target parameter from the code stream.
  • the target parameters in this embodiment are used to characterize the display content performance indicators of all image frames.
  • the target parameter obtained from the code stream may also be referred to as metadata acquired from the code stream.
  • the target parameter in this embodiment includes a display content maximum brightness value Max_Content_Light_Level, and may also include a display content maximum image average brightness value, a display content nonlinear brightness component maximum value, a display content nonlinear brightness component minimum value, and a display content nonlinear brightness component.
  • the maximum brightness value of the display content, the maximum image average brightness value of the display content, the maximum value of the nonlinear brightness component of the display content, the minimum value of the nonlinear brightness component of the display content, the average value of the nonlinear brightness component of the display content, and the nonlinearity of the display content in this embodiment The luminance component standard variance value, the display content nonlinear luminance scaling quantization, the display content nonlinear chrominance scaling quantization, and the display content nonlinear luminance gamma value can be referred to in the embodiment shown in FIG. As described above, detailed descriptions are not repeated here.
  • the target parameter in this embodiment is a statistical value calculated by the image processing apparatus according to pixel values of all image frames in the code stream, and in the embodiment shown in FIG.
  • the target parameter is calculated by the image processing device based on the pixel value of one image frame.
  • the image processing apparatus calculates an adjustment coefficient according to the display parameter and the target parameter.
  • the adjustment coefficients include a linear domain adjustment coefficient and a nonlinear domain adjustment coefficient.
  • the image processing apparatus calculates the linear domain adjustment coefficient using the following formula:
  • min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) represents the minimum value of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level
  • the linear_adjust_factor is a linear domain adjustment coefficient
  • the image processing apparatus calculates the nonlinear domain adjustment coefficient using the following formula:
  • the nonlinear_adjust_factor is the above-mentioned nonlinear domain adjustment coefficient
  • the OETF ( ⁇ ) represents the photoelectric conversion function
  • the image processing apparatus updates the target parameter acquired in S502 according to the adjustment coefficient.
  • the image processing device multiplies the maximum brightness value of the display content by the linear domain adjustment coefficient, and quantizes it into a 16-bit unsigned integer to obtain an updated maximum brightness value of the display content.
  • the image processing device multiplies the maximum image average brightness value of the display content by the linear domain adjustment coefficient, and quantizes to a 16-bit unsigned integer.
  • the updated image maximum brightness value of the displayed content is obtained.
  • the image processing device multiplies the maximum value of the display content nonlinear luminance component by the nonlinear domain adjustment coefficient, and quantizes to 16 bits without The symbolic integer gives the maximum value of the non-linear luminance component of the updated display content.
  • the image processing device multiplies the minimum value of the nonlinear luminance component of the display content by the nonlinear domain adjustment coefficient, and quantizes to 16 bits without The symbolic integer gives the minimum value of the non-linear luminance component of the updated display content.
  • the image processing device multiplies the average value of the nonlinear luminance component of the display content by the nonlinear domain adjustment coefficient, and quantizes to 16 bits without A symbolic integer that yields an average of the non-linear luminance components of the updated display content.
  • the image processing device multiplies the standard content variance value of the display content nonlinear luminance component by the nonlinear domain adjustment coefficient, and quantizes For a 16-bit unsigned integer, the updated display component nonlinear luminance component standard variance value is obtained.
  • the image processing apparatus sets the numerical value of the display content nonlinear brightness scaling quantization to a first preset threshold.
  • the first preset threshold is 0.
  • the image The processing device sets the numerical value of the display content nonlinear chromaticity scaling quantization to a second preset threshold.
  • the second preset threshold is zero.
  • the image processing apparatus sets the value of the display content nonlinear luminance gamma value to a third preset threshold.
  • the third preset threshold is 128.
  • the image processing apparatus sends the updated target parameter to the display device.
  • the display device adjusts a dynamic range and a color of the image frame according to the updated target parameter.
  • the image processing method provided by the embodiment of the present application can ensure the matching between the target parameter carried by the code stream stored by the image processing device and the adjusted image frame.
  • the image processing device After obtaining the code stream corresponding to the plurality of image frames, the image processing device adjusts the dynamic range and color of each image frame, and the image processing device calculates the update coefficient according to the display parameters of the display device by executing the above S500-S504, and uses the update.
  • the coefficient updates the target parameter carried by the code stream, such that the updated target parameter is adapted to the display parameters of the display device.
  • the image processing apparatus performs the above S505, that is, the target parameter carried by the code stream sent by the image processing apparatus to the display device is the target parameter updated by the image processing apparatus.
  • the display device performs the above S506 to directly adjust the dynamic range and color of each image frame by using the updated target parameter, so that the display device not only makes the display device display the adjusted image frame more clearly and comprehensively, but also improves the display device. Performance.
  • An embodiment of the present application provides an image processing apparatus for performing the steps performed by the image processing apparatus in the above image processing method.
  • the image processing apparatus provided by the embodiment of the present application may include a module corresponding to the corresponding step.
  • the embodiment of the present application may divide the function module into the image processing device according to the above method example.
  • each function module may be divided according to each function, or two or more functions may be integrated into one processing module.
  • the above integrated modules can be implemented in the form of hardware or in the form of software functional modules.
  • the division of modules in the embodiments of the present application is schematic, and is only a logical function division, and may be further divided in actual implementation.
  • FIG. 6 shows a possible structural diagram of the image processing apparatus involved in the above embodiments.
  • the image processing apparatus 600 includes an acquisition unit 60, a calculation unit 61, an adjustment unit 62, an update unit 63, a transmission unit 64, and a determination unit 65.
  • the obtaining unit 60 is configured to support the image processing apparatus 600 to execute S300, S301, S325, S501, S502, etc. in the above embodiments, and/or other processes for the techniques described herein;
  • the computing unit 61 is configured to support the image
  • the processing device 600 performs S302, S303, S304, S305, S306, S503, etc.
  • the adjustment unit 62 is configured to support the image processing device 600 to perform the above-described implementation S307, etc. in the example, and/or other processes for the techniques described herein; an update unit 63 for supporting the image processing device 600 to perform S504, etc. in the above-described embodiments, and/or for the techniques described herein Other processes; the transmitting unit 64 is configured to support the image processing apparatus 600 to perform S308, S505, etc.
  • the determining unit 65 is configured to support the image processing apparatus 600, using the target parameter of the tith image frame calculated by the above calculating unit 61 as a statistical value of the target parameter of the image frame to be processed, and the like, and/or for the technique described herein Process.
  • the above method is implemented All the related content of each step involved in the example can be referred to the function description of the corresponding function module, and details are not described herein again.
  • the image processing apparatus 600 provided by the embodiment of the present application includes but is not limited to the above modules.
  • the image processing apparatus 600 may further include a storage unit 66.
  • the storage unit 66 can be used to store program codes and data of the image processing apparatus.
  • the calculation unit 61, the adjustment unit 62, the update unit 63, and the determination unit 65 in the embodiment of the present application may be the processor 21 in FIG. 2, and the acquisition unit 60 and the transmission unit 64 may be diagrams.
  • the storage unit 66 may be the memory 23 in FIG.
  • the image processing apparatus executes the image processing method of the embodiment as shown in FIG. 3 or 5.
  • the image processing apparatus executes the image processing method of the embodiment as shown in FIG. 3 or 5.
  • the image processing apparatus executes the image processing method of the embodiment as shown in FIG. 3 or 5.
  • Another embodiment of the present application further provides a computer storage medium, where the computer program code is stored, when the processor 71 in the image processing device executes the program code, the image processing device executes as shown in FIG. 3 or The image processing method shown in FIG.
  • a computer program product comprising computer executed instructions stored in a computer readable storage medium; at least one processor of the image processing apparatus is The computer readable storage medium reads the computer to execute instructions, and the at least one processor executes the computer to execute the instructions such that the image processing apparatus implements the steps of performing the image processing apparatus in the image processing method illustrated in FIG. 3 or 5.
  • the disclosed system, apparatus, and method may be implemented in other manners.
  • the device embodiments described above are merely illustrative.
  • the division of the modules or units is only a logical function division.
  • there may be another division manner for example, multiple units or components may be used. Combinations can be integrated into another system, or some features can be ignored or not executed.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, and may be in an electrical, mechanical or other form.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
  • the above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
  • the integrated unit if implemented in the form of a software functional unit and sold or used as a standalone product, may be stored in a computer readable storage medium.
  • the technical solution of the present application may contribute to the prior art or all or part of the technical solution may be in the form of a software product.
  • the computer software product is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor to perform the methods described in various embodiments of the present application. All or part of the steps.
  • the foregoing storage medium includes: a flash memory, a mobile hard disk, a read only memory, a random access memory, a magnetic disk, or an optical disk, and the like, which can store program codes.

Landscapes

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

Abstract

Embodiments of the present application relates to the technical field of image processing, and provides an image processing method and apparatus, capable of resolving the problems of image delay and flickering. The method comprises: obtaining a reference value of a target parameter of a previous adjacent frame of an image frame to be processed, the target parameter being used for representing a displayed content performance indicator of an image frame; according to a pixel value of an obtained image frame, calculating a statistical value of the target parameter of the image frame to be processed; calculating an absolute value of the difference between the reference value and the statistical value; according to the absolute value, calculating an update coefficient using a hyperbolic tangent function; according to the update coefficient, the reference value, and the statistical value, calculating an updated statistical value of the target parameter of the image frame to be processed using a time-domain filter function; according to the updated statistical value, calculating a display adaptation parameter of the image frame to be processed, the display adaptation parameter being used for adjusting the dynamic range and color of the image frame to be processed; and according to the display adaptation parameter, adjusting the image frame to be processed.

Description

一种图像处理方法及装置Image processing method and device 技术领域Technical field
本申请实施例涉及图像处理技术领域,尤其涉及一种图像处理方法及装置。The embodiments of the present invention relate to the field of image processing technologies, and in particular, to an image processing method and apparatus.
背景技术Background technique
高动态范围(High Dynamic Range,HDR)图像是一种可表示从太阳光直射到最暗的阴影这样大的动态范围亮度变化的图像类型,其可以表示的亮度范围为10-3~106坎德拉/平方米(cd/m2)。而现阶段的显示设备所能够显示的图像的动态范围是有限的,即不能将一张HDR图像所表示的动态范围全部显示出来。因此,一般都需要对HDR图像的动态范围进行压缩,以将HDR图像的高动态范围调整到显示设备的显示能力范围内进行显示。A High Dynamic Range (HDR) image is a type of image that represents a large dynamic range of brightness changes from direct sunlight to the darkest shadow, which can represent a range of brightness from 10 -3 to 10 6 candelas. / square meter (cd/m 2 ). At present, the dynamic range of the image that can be displayed by the display device is limited, that is, the dynamic range represented by one HDR image cannot be displayed. Therefore, it is generally necessary to compress the dynamic range of the HDR image to adjust the high dynamic range of the HDR image to display within the display capability of the display device.
调整HDR图像的动态范围,一般需要根据视频码流携带的目标参数进行。对于携带多个HDR图像帧的视频码流,该视频码流携带的目标参数为图像处理装置通过计算该码流中的所有图像帧的像素获得的,且该目标参数用于表征该码流的所有图像帧的显示内容性能指标(一般的,码流携带的目标参数也可称为码流携带的元数据)。但码流中不同图像帧的场景可能不同,因此,使用码流携带的目标参数调整每个图像帧的动态范围的效果难以保证。此外,在某些应用场景中,如直播应用场景、非标准码流等,图像处理装置得到的码流可能缺失全部或部分目标参数,因此,现有的图像处理装置使用图像帧的目标参数调整图像帧的动态范围。图像帧的目标参数用于表征该图像帧的显示内容性能指标。Adjusting the dynamic range of the HDR image generally needs to be performed according to the target parameters carried in the video stream. For a video code stream carrying a plurality of HDR image frames, the target parameter carried by the video code stream is obtained by the image processing device by calculating pixels of all image frames in the code stream, and the target parameter is used to represent the code stream. Display content performance indicators of all image frames (generally, the target parameters carried by the code stream may also be referred to as metadata carried by the code stream). However, the scenes of different image frames in the code stream may be different. Therefore, it is difficult to ensure the effect of adjusting the dynamic range of each image frame using the target parameters carried by the code stream. In addition, in some application scenarios, such as a live application scenario, a non-standard code stream, etc., the code stream obtained by the image processing device may be missing all or part of the target parameters. Therefore, the existing image processing device uses the target parameter adjustment of the image frame. The dynamic range of the image frame. The target parameter of the image frame is used to characterize the display content performance indicator of the image frame.
具体的,图像处理装置获取当前图像帧的目标参数的统计值,并利用上一图像帧的目标参数的参考值和固定的更新系数(一般为0.1),计算当前图像帧的目标参数的更新后的统计值,进而根据计算出的更新后的统计值调整当前图像帧的动态范围。由于实时播放的需要,当前图像帧的目标参数的统计值一般使用当前帧的前一相邻帧的目标参数近似代替。现有的更新系数的数值为固定值,如果固定值选择较小则HDR图像的目标参数的统计值的更新速度较慢,这样,在图像场景切换时,HDR图像帧的目标参数的统计值与HDR图像帧无法同步,导致HDR图像帧出现较大延迟。如果固定值选择较大,HDR图像的目标参数的统计值更新速度较快,这样,在图像场景切换时,HDR图像帧的目标参数的统计值与HDR图像帧无法同步,导致HDR图像帧出现闪烁。Specifically, the image processing device acquires a statistical value of the target parameter of the current image frame, and uses the reference value of the target parameter of the previous image frame and a fixed update coefficient (generally 0.1) to calculate the update of the target parameter of the current image frame. The statistical value, and then adjust the dynamic range of the current image frame according to the calculated updated statistical value. Due to the need for real-time playback, the statistical value of the target parameter of the current image frame is generally approximated using the target parameter of the previous adjacent frame of the current frame. The value of the existing update coefficient is a fixed value. If the fixed value is selected to be small, the update value of the target value of the HDR image is slower. Thus, when the image scene is switched, the statistical value of the target parameter of the HDR image frame is HDR image frames cannot be synchronized, resulting in large delays in HDR image frames. If the fixed value is selected to be large, the statistical value of the target parameter of the HDR image is updated faster, so that when the image scene is switched, the statistical value of the target parameter of the HDR image frame cannot be synchronized with the HDR image frame, causing the HDR image frame to flicker. .
发明内容Summary of the invention
本申请提供一种图像处理方法及装置,有效的解决了HDR图像帧的延迟、闪烁等问题。The present application provides an image processing method and apparatus, which effectively solve the problems of delay, flicker, and the like of an HDR image frame.
为达到上述目的,本申请采用如下技术方案:To achieve the above objectives, the present application adopts the following technical solutions:
第一方面,提供一种图像处理方法,图像处理装置在获取到待处理图像帧的前一相邻帧的目标参数的参考值,并根据已获取图像帧的像素值计算出待处理图像帧的目 标参数的统计值后,计算上述参考值和上述统计值的差值的绝对值,这里,目标参数用于表征图像帧的显示内容性能指标;该图像处理装置根据计算出的绝对值,利用双曲正切函数,计算更新系数,进而根据更新系数、上述参考值以及上述统计值,利用时域滤波函数,计算出待处理图像帧的目标参数的更新后的统计值,这样,该图像处理装置能够根据计算得到的更新后的统计值,计算出用于调整待处理图像帧的动态范围和色彩的显示适配参数,从而使得该图像处理装置根据显示适配参数调整待处理图像帧。In a first aspect, an image processing method is provided. The image processing device acquires a reference value of a target parameter of a previous adjacent frame of an image frame to be processed, and calculates a to-be-processed image frame according to the pixel value of the acquired image frame. Head After the statistical value of the parameter is calculated, the absolute value of the difference between the reference value and the statistical value is calculated. Here, the target parameter is used to represent the display content performance index of the image frame; the image processing device uses the double according to the calculated absolute value. a curve tangent function, calculating an update coefficient, and further calculating an updated statistical value of a target parameter of the image frame to be processed by using a time domain filter function according to the update coefficient, the reference value, and the statistical value, so that the image processing device can Based on the calculated updated statistical value, a display adaptation parameter for adjusting a dynamic range and a color of the image frame to be processed is calculated, so that the image processing apparatus adjusts the image frame to be processed according to the display adaptation parameter.
图像场景切换是指图像的内容发生明显的变化。一般的,在图像场景切换时,相邻两个图像帧的目标参数的统计值的差距较大。本申请实施例中的图像处理装置计算待处理图像帧的前一相邻帧的目标参数的参考值和待处理图像帧的目标参数的统计值之间的差值的绝对值,并根据该绝对值,利用双曲正切函数计算更新系数。由于双曲正切函数具备单调递增,且曲线的变化特征为两端较为剧烈,中间较为平缓的特性,因此,在绝对值较大的情况下,该图像处理装置也可以获取到较大的更新系数,这样,图像处理装置能够迅速的更新待处理图像帧的目标参数的统计值,快速实现待处理图像帧的目标参数的统计值与调整后的待处理图像帧的同步,有效的解决了图像延迟的问题,而且也不会因为更新系数过大,造成图像闪烁的问题。Image scene switching refers to a significant change in the content of an image. Generally, when the image scene is switched, the difference between the statistical values of the target parameters of the adjacent two image frames is large. The image processing apparatus in the embodiment of the present application calculates an absolute value of a difference between a reference value of a target parameter of a previous adjacent frame of a to-be-processed image frame and a statistical value of a target parameter of the image frame to be processed, and according to the absolute Value, using the hyperbolic tangent function to calculate the update coefficient. Since the hyperbolic tangent function has a monotonous increment, and the change characteristic of the curve is that the two ends are more intense and the middle is more gradual, the image processing apparatus can also obtain a larger update coefficient when the absolute value is large. In this way, the image processing apparatus can quickly update the statistical value of the target parameter of the image frame to be processed, and quickly realize the synchronization between the statistical value of the target parameter of the image frame to be processed and the adjusted image frame to be processed, thereby effectively solving the image delay. The problem, and it will not cause the image to flicker because the update factor is too large.
可选的,在本申请的一种可能的实现方式中,上述“图像处理装置根据计算出的绝对值,利用双曲正切函数,计算更新系数”的方法为:图像处理装置根据下述公式计算更新系数:Optionally, in a possible implementation manner of the present application, the “image processing apparatus calculates a update coefficient by using a hyperbolic tangent function according to the calculated absolute value” is: the image processing apparatus calculates according to the following formula: Update factor:
Figure PCTCN2017099365-appb-000001
Figure PCTCN2017099365-appb-000001
其中,A为上述更新系数,x为上述绝对值,a为第一预设值,b为第二预设值。Where A is the above update coefficient, x is the above absolute value, a is the first preset value, and b is the second preset value.
图像处理装置根据双曲正切函数能够准确的识别图像场景是否发生切换。可选的,在上述计算更新系数的公式中,a=3,b=0.5。The image processing apparatus can accurately recognize whether or not the image scene is switched according to the hyperbolic tangent function. Optionally, in the above formula for calculating the update coefficient, a=3, b=0.5.
可选的,在本申请的另一种可能的实现方式中,图像处理装置在获取待处理图像帧的前一相邻帧的目标参数的参考值之前,还得到对应多个图像帧的码流,上述待处理图像帧为该码流对应的多个图像帧中的第t个图像帧,t为非负整数。在这种情况下,上述“图像处理装置根据更新系数、参考值以及统计值,利用时域滤波函数,计算待处理图像帧的目标参数的更新后的统计值”的方法为:图像处理装置采用下述公式计算上述更新后的统计值Mt:当t>0时,Mt=A×Ct+B×Mt-1;当t=0时,Mt=C0;其中,A为更新系数,Ct为上述统计值,B为第三预设值,Mt-1为上述参考值,C0为第四预设值,或者,C0为通过解析上述码流获得。Optionally, in another possible implementation manner of the present application, the image processing apparatus obtains a code stream corresponding to the multiple image frames before acquiring the reference value of the target parameter of the previous adjacent frame of the image frame to be processed. The image frame to be processed is the t-th image frame of the plurality of image frames corresponding to the code stream, and t is a non-negative integer. In this case, the above-described method of "the image processing apparatus calculates the updated statistical value of the target parameter of the image frame to be processed by using the time domain filter function according to the update coefficient, the reference value, and the statistical value" is: the image processing apparatus adopts The above-mentioned updated statistical value M t is calculated by the following formula: when t>0, M t =A×C t +B×M t-1 ; when t=0, M t =C 0 ; wherein A is The update coefficient, C t is the above-mentioned statistical value, B is the third preset value, M t-1 is the above reference value, C 0 is the fourth preset value, or C 0 is obtained by parsing the above code stream.
可选的,在本申请的另一种可能的实现方式中,上述计算待处理图像帧的目标参数的更新后的统计值Mt的公式中,B=1-A。Optionally, in another possible implementation manner of the present application, in the foregoing formula for calculating the updated statistical value M t of the target parameter of the image frame to be processed, B=1-A.
对于多个图像帧中的首个图像帧,图像处理装置可以将系统中预先设置的参数确定为该图像帧的目标参数的统计值,或者通过解析码流得到该图像帧的目标参数的统计值。对于多个图像帧中除首个图像帧之外的其他任一图像帧,图像处理装置均需利用该图像帧的目标参数的统计值、该图像帧的前一相邻图像帧的目标参数的参考值以及更新系数来确定该图像帧的目标参数的更新后的统计值,采用该方法确定出的更新 后的统计值更为准确。For the first image frame of the plurality of image frames, the image processing apparatus may determine a parameter preset in the system as a statistical value of the target parameter of the image frame, or obtain a statistical value of the target parameter of the image frame by parsing the code stream. . For any image frame other than the first image frame of the plurality of image frames, the image processing device needs to utilize the statistical value of the target parameter of the image frame, and the target parameter of the previous adjacent image frame of the image frame. The reference value and the update coefficient are used to determine an updated statistical value of the target parameter of the image frame, and the update determined by the method is The subsequent statistics are more accurate.
容易理解的是,待处理图像帧的前一相邻图像帧的目标参数的参数值实质上为:图像处理装置在调整待处理图像帧的前一图像帧的动态范围和色彩之前,计算出的待处理图像帧的前一相邻图像帧的目标参数的更新后的统计值。为了便于理解,本申请均用参考值表示。It is easy to understand that the parameter value of the target parameter of the previous adjacent image frame of the image frame to be processed is substantially: the image processing device calculates the dynamic range and color of the previous image frame of the image frame to be processed before adjusting the dynamic range and color of the previous image frame of the image frame to be processed. The updated statistical value of the target parameter of the previous adjacent image frame of the image frame to be processed. For ease of understanding, the present application is expressed by reference values.
可选的,在本申请的另一种可能的实现方式中,在上述待处理图像帧为多个图像帧中的第t个图像帧的情况下,上述“图像处理装置根据已获取图像帧的像素值,计算待处理图像帧的目标参数的统计值”的方法为:图像处理装置根据多个图像帧中的第t-i个图像帧的像素值,计算第t-i个图像帧的目标参数,并将第t-i个图像帧的目标参数作为待处理图像帧的目标参数的统计值,i为正整数。Optionally, in another possible implementation manner of the present application, in the case that the to-be-processed image frame is the t-th image frame of the plurality of image frames, the foregoing “image processing apparatus is configured according to the acquired image frame. a pixel value, a method for calculating a statistical value of a target parameter of an image frame to be processed": the image processing device calculates a target parameter of the tith image frame according to a pixel value of the tith image frame in the plurality of image frames, and The target parameter of the tith image frame is a statistical value of the target parameter of the image frame to be processed, and i is a positive integer.
在图像处理装置实时处理码流的情况下,若待处理图像帧包括的像素点较多,则图像处理装置计算该待处理图像帧的目标参数的统计值需花费较长的时间,很容易出现延迟的问题。若待处理图像帧包括的像素点很少,图像处理装置则能够及时计算出该待处理图像帧的目标参数的统计值。为了避免出现延迟问题,对于第t个图像帧而言,图像处理装置将第t-i个图像帧的目标参数作为第t个图像帧的目标参数的统计值。In the case that the image processing apparatus processes the code stream in real time, if the image frame to be processed includes more pixels, the image processing apparatus calculates the statistical value of the target parameter of the image frame to be processed, which takes a long time, and is easy to appear. Delayed issue. If the image frame to be processed includes few pixels, the image processing device can calculate the statistical value of the target parameter of the image frame to be processed in time. In order to avoid the delay problem, for the t-th image frame, the image processing apparatus uses the target parameter of the t-ith image frame as the statistical value of the target parameter of the t-th image frame.
可选的,在本申请的另一种可能的实现方式中,上述目标参数包括显示内容最大亮度值、显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马(gamma)值以及显示内容非线性色度缩放量化中的至少一个。Optionally, in another possible implementation manner of the present application, the target parameter includes a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, and a nonlinear brightness component of the display content. Minimum value, display content nonlinear brightness component average value, display content nonlinear brightness component standard variance value, display content nonlinear brightness scaling quantization, display content nonlinear brightness gamma value and display content nonlinear chromaticity scaling At least one of the quantifications.
特别的,上述显示内容非线性亮度分量为显示内容非线性Y分量,显示内容非线性色度分量为显示内容非线性Cb/Cr分量。In particular, the non-linear luminance component of the display content is a non-linear Y component of the display content, and the non-linear chrominance component of the display content is a non-linear Cb/Cr component of the display content.
第二方面,提供一种图像处理装置,该图像处理装置包括获取单元、计算单元以及调整单元。具体的,上述获取单元,用于获取多个图像帧,以及获取多个图像帧中待处理图像帧的前一相邻帧的目标参数的参考值,目标参数用于表征图像帧的显示内容性能指标。上述计算单元,用于根据上述获取单元获取到的已获取图像帧的像素值,计算待处理图像帧的目标参数的统计值,以及用于计算上述获取单元获取到的参考值和统计值的差值的绝对值,以及用于根据绝对值,利用双曲正切函数,计算更新系数,以及用于根据更新系数、参考值以及统计值,利用时域滤波函数,计算待处理图像帧的目标参数的更新后的统计值,以及用于根据更新后的统计值,计算待处理图像帧的显示适配参数,显示适配参数用于调整待处理图像帧的动态范围和色彩。上述调整单元,用于根据上述计算单元计算出的显示适配参数,调整待处理图像帧。In a second aspect, an image processing apparatus is provided, the image processing apparatus including an acquisition unit, a calculation unit, and an adjustment unit. Specifically, the acquiring unit is configured to acquire a plurality of image frames, and obtain reference values of target parameters of a previous adjacent frame of the image frames to be processed in the plurality of image frames, where the target parameters are used to represent display content performance of the image frames. index. The calculating unit is configured to calculate a statistic value of the target parameter of the image frame to be processed according to the pixel value of the acquired image frame acquired by the acquiring unit, and calculate a difference between the reference value and the statistic value acquired by the acquiring unit. An absolute value of the value, and a method for calculating an update coefficient by using a hyperbolic tangent function according to the absolute value, and for calculating a target parameter of the image frame to be processed by using a time domain filter function according to the update coefficient, the reference value, and the statistical value The updated statistical value is used to calculate display adaptation parameters of the image frame to be processed according to the updated statistical value, and the display adaptation parameter is used to adjust the dynamic range and color of the image frame to be processed. The adjusting unit is configured to adjust an image frame to be processed according to the display adaptation parameter calculated by the calculating unit.
进一步地,在本申请的一种可能的实现方式中,上述计算单元具体用于:Further, in a possible implementation manner of the application, the calculating unit is specifically configured to:
根据下述公式计算更新系数:Calculate the update factor according to the following formula:
Figure PCTCN2017099365-appb-000002
Figure PCTCN2017099365-appb-000002
其中,A为上述更新系数,x为上述绝对值,a为第一预设值,b为第二预设值。Where A is the above update coefficient, x is the above absolute value, a is the first preset value, and b is the second preset value.
进一步地,在本申请的另一种可能的实现方式中,上述获取单元,还用于得到对应多个图像帧的码流,上述待处理图像帧为该码流对应的多个图像帧中的第t个图像 帧,t为非负整数。上述计算单元具体用于:采用下述公式计算上述更新后的统计值Mt:当t>0时,Mt=A×Ct+B×Mt-1;当t=0时,Mt=C0;其中,A为上述更新系数,Ct为上述统计值,B为第三预设值,Mt-1为上述参考值,C0为第四预设值,或者,C0为通过解析上述码流获得。Further, in another possible implementation manner of the present application, the acquiring unit is further configured to obtain a code stream corresponding to multiple image frames, where the image frame to be processed is in a plurality of image frames corresponding to the code stream. The tth image frame, t is a non-negative integer. The calculation unit is specifically configured to: calculate the updated statistical value M t by using the following formula: when t>0, M t =A×C t +B×M t-1 ; when t=0, M t =C 0 ; where A is the above update coefficient, C t is the above statistical value, B is the third preset value, M t-1 is the above reference value, C 0 is the fourth preset value, or C 0 is Obtained by parsing the above code stream.
进一步地,在本申请的另一种可能的实现方式中,上述计算待处理图像帧的更新后的统计值Mt的公式中,B=1-A。Further, in another possible implementation manner of the present application, in the formula for calculating the updated statistical value M t of the image frame to be processed, B=1-A.
进一步地,在本申请的另一种可能的实现方式中,在待处理图像帧为上述多个图像帧中的第t个图像帧的情况下,上述计算单元,还用于根据上述多个图像帧中的第t-i个图像帧的像素值,计算第t-i个图像帧的目标参数,i为正整数。相应的,本申请中的图像处理装置还包括确定单元,该确定单元用于将上述计算单元计算出的第t-i个图像帧的目标参数作为待处理图像帧的目标参数的统计值。Further, in another possible implementation manner of the present application, in a case that the to-be-processed image frame is the t-th image frame of the plurality of image frames, the calculating unit is further configured to use the multiple images according to the foregoing The pixel value of the tith image frame in the frame, and the target parameter of the tith image frame is calculated, and i is a positive integer. Correspondingly, the image processing apparatus in the present application further includes a determining unit, configured to use the target parameter of the t-ith image frame calculated by the calculating unit as a statistical value of a target parameter of the image frame to be processed.
进一步地,在本申请的另一种可能的实现方式中,目标参数包括显示内容最大亮度值、显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性色度缩放量化中的至少一个。Further, in another possible implementation manner of the present application, the target parameter includes a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, and a minimum value of the nonlinear brightness component of the display content. At least one of a display content nonlinear luminance component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization .
特别的,显示内容非线性亮度分量为显示内容非线性Y分量,显示内容非线性色度分量为显示内容非线性Cb/Cr分量。In particular, the non-linear luminance component of the display content is a non-linear Y component of the display content, and the non-linear chrominance component of the display content is a non-linear Cb/Cr component of the display content.
本申请中第二方面及其各种实现方式的具体描述,可以参考第一方面及其各种实现方式中的详细描述;并且,第二方面及其各种实现方式的有益效果,可以参考第一方面及其各种实现方式中的有益效果分析,此处不再赘述。For a detailed description of the second aspect and various implementations of the present application, reference may be made to the detailed description of the first aspect and various implementations thereof; and the beneficial effects of the second aspect and various implementations thereof may be referred to The analysis of the beneficial effects on the one hand and its various implementations will not be repeated here.
第三方面,提供一种图像处理方法,图像处理装置获取显示设备的显示参数;图像处理装置从码流中获取用于表征该码流中的所有图像帧的显示内容性能指标的目标参数;图像处理装置根据显示参数和目标参数,计算调整系数,并根据该调整系数更新其获取到的目标参数;图像处理装置向显示设备发送更新后的目标参数,以使得显示设备根据更新后的目标参数调整图像帧的动态范围和色彩。In a third aspect, an image processing method is provided, the image processing device acquires display parameters of a display device, and the image processing device acquires, from the code stream, target parameters for characterizing display content performance indicators of all image frames in the code stream; The processing device calculates an adjustment coefficient according to the display parameter and the target parameter, and updates the acquired target parameter according to the adjustment coefficient; the image processing device sends the updated target parameter to the display device, so that the display device adjusts according to the updated target parameter. The dynamic range and color of the image frame.
图像处理装置根据当前显示设备的显示参数和从码流中获取到的目标参数计算调整系数,进而根据调整系数更新该目标参数,这样,更新后的目标参数与显示设备的显示参数适配,便于显示设备直接利用更新后的目标参数调整每个图像帧。The image processing device calculates an adjustment coefficient according to the display parameter of the current display device and the target parameter acquired from the code stream, and then updates the target parameter according to the adjustment coefficient, so that the updated target parameter is adapted to the display parameter of the display device, which is convenient. The display device directly adjusts each image frame with the updated target parameters.
可选的,在本申请的一种可能的实现方式中,上述显示参数包括显示设备的最大显示亮度值,上述目标参数包括显示内容最大亮度值,调整系数包括线性域调整系数和非线性域调整系数,相应的,上述“图像处理装置根据显示参数,计算调整参数”的方法为:图像处理装置根据显示内容最大亮度值和图像处理装置的最大显示亮度值,分别计算线性域调整系数和非线性域调整系数,具体的,图像处理装置采用下述公式计算线性域调整系数:Optionally, in a possible implementation manner of the present application, the foregoing display parameter includes a maximum display brightness value of the display device, where the target parameter includes a maximum brightness value of the display content, and the adjustment coefficient includes a linear domain adjustment coefficient and a nonlinear domain adjustment. Coefficient, correspondingly, the above method "the image processing device calculates the adjustment parameter according to the display parameter" is: the image processing device calculates the linear domain adjustment coefficient and the nonlinearity respectively according to the maximum brightness value of the display content and the maximum display brightness value of the image processing device The domain adjustment coefficient, specifically, the image processing device calculates the linear domain adjustment coefficient by the following formula:
linear_adjust_factorLinear_adjust_factor
=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)
其中,linear_adjust_factor为上述线性域调整系数,Max_Display_Target_Luminance为上述显示设备的最大显示亮度值,Max_Content_Light_Level为上述显示内容最大亮度值, min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)表示取1.0和Max_Display_Target_Luminance/Max_Content_Light_Level的最小值。The linear_adjust_factor is the linear domain adjustment coefficient, the Max_Display_Target_Luminance is the maximum display brightness value of the display device, and the Max_Content_Light_Level is the maximum brightness value of the display content. Min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) indicates the minimum value of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level.
图像处理装置采用下述公式计算非线性域调整系数:The image processing apparatus calculates the nonlinear domain adjustment coefficient using the following formula:
Figure PCTCN2017099365-appb-000003
Figure PCTCN2017099365-appb-000003
其中,nonlinear_adjust_factor为上述非线性域调整系数,OETF(·)表示光电转换函数。Wherein, the nonlinear_adjust_factor is the above-mentioned nonlinear domain adjustment coefficient, and the OETF (·) represents the photoelectric conversion function.
可选的,在本申请的另一种可能的实现方式中,上述目标参数还包括显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性色度缩放量化中的至少一个。相应的,上述“图像处理装置根据调整系数,更新目标参数”的方法具体为:图像处理装置将线性域调整系数与显示内容最大亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大亮度值;当上述目标参数包括显示内容最大图像平均亮度值时,图像处理装置将线性域调整系数与显示内容最大图像平均亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大图像平均亮度值;当上述目标参数包括显示内容非线性亮度分量最大值时,图像处理装置将非线性域调整系数与显示内容非线性亮度分量最大值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量最大值;当上述目标参数包括显示内容非线性亮度分量最小值时,图像处理装置将非线性域调整系数与显示内容非线性亮度分量最小值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量最小值;当上述目标参数包括显示内容非线性亮度分量平均值时,图像处理装置将非线性域调整系数与显示内容非线性亮度分量平均值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量平均值;当上述目标参数包括显示内容非线性亮度分量标准方差值时,图像处理装置将非线性域调整系数与显示内容非线性亮度分量标准方差值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量标准方差值;当上述目标参数包括显示内容非线性亮度缩放量化时,图像处理装置将显示内容非线性亮度缩放量化的数值设置为第一预设阈值;当上述目标参数包括显示内容非线性色度缩放量化时,图像处理装置将显示内容非线性色度缩放量化的数值设置为第二预设阈值;当上述目标参数包括显示内容非线性亮度伽马值时,将显示内容非线性亮度伽马值的数值设置为第三预设阈值。Optionally, in another possible implementation manner of the present application, the target parameter further includes: a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, and a display content. At least one of a nonlinear luminance component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization. Correspondingly, the method for updating the target parameter according to the adjustment coefficient by the image processing apparatus is specifically: the image processing apparatus multiplies the linear domain adjustment coefficient by the maximum brightness value of the display content, and quantizes it into an unsigned integer to obtain an updated display. The maximum brightness value of the content; when the target parameter includes the maximum image average brightness value of the display content, the image processing device multiplies the linear domain adjustment coefficient by the maximum image average brightness value of the display content, and quantizes it into an unsigned integer to obtain an updated display. Content maximum image average brightness value; when the target parameter includes a maximum value of the display content nonlinear brightness component, the image processing device multiplies the nonlinear domain adjustment coefficient by the display content nonlinear brightness component maximum value, and quantizes to an unsigned integer, Obtaining a maximum value of the non-linear luminance component of the updated display content; when the target parameter includes a minimum value of the nonlinear luminance component of the display content, the image processing device multiplies the nonlinear domain adjustment coefficient by the minimum value of the nonlinear luminance component of the display content, and Quantify as an unsigned integer and get updated The display content non-linear luminance component minimum value; when the target parameter includes the average value of the display content nonlinear luminance component, the image processing device multiplies the nonlinear domain adjustment coefficient by the display content nonlinear luminance component average value, and quantizes to none a symbol integer, which obtains an average value of the updated non-linear luminance component of the display content; when the target parameter includes a standard variance value of the non-linear luminance component of the display content, the image processing apparatus sets the nonlinear domain adjustment coefficient and the display content nonlinear luminance component standard The variance values are multiplied and quantized into unsigned integers to obtain an updated standard deviation of the nonlinear luminance components of the display content; when the target parameters include non-linear luminance scaling quantization of the display content, the image processing apparatus displays the content nonlinearity The value of the brightness scaling quantization is set to a first preset threshold; when the target parameter includes the display content nonlinear chrominance scaling quantization, the image processing device sets the value of the display content nonlinear chrominance scaling quantization to a second preset threshold; When the above target parameters include non-linear brightness of display content When the value of the horse, the non-linear luminance setting value display gamma value content third predetermined threshold value.
第四方面,提供一种图像处理装置,该图像处理装置包括获取单元、计算单元、更新单元和发送单元。具体的,上述获取单元,用于获取显示设备的显示参数,以及用于从码流中获取目标参数,该目标参数用于表征码流中的所有图像帧的显示内容性能指标。上述计算单元,用于根据上述获取单元获取到的显示参数和目标参数,计算调整系数。上述更新单元,用于根据上述计算单元计算出的调整系数,更新上述获取单元获取到的目标参数。上述发送单元,用于向显示设备发送上述更新单元得到的更新后的目标参数,以使得显示设备根据更新后的目标参数调整图像帧的动态范围和色彩。In a fourth aspect, an image processing apparatus is provided, the image processing apparatus comprising an acquisition unit, a calculation unit, an update unit, and a transmission unit. Specifically, the acquiring unit is configured to acquire display parameters of the display device, and to obtain a target parameter from the code stream, where the target parameter is used to represent a display content performance indicator of all image frames in the code stream. The calculating unit is configured to calculate an adjustment coefficient according to the display parameter and the target parameter acquired by the acquiring unit. The updating unit is configured to update the target parameter acquired by the acquiring unit according to the adjustment coefficient calculated by the calculating unit. The sending unit is configured to send, to the display device, the updated target parameter obtained by the updating unit, so that the display device adjusts the dynamic range and color of the image frame according to the updated target parameter.
进一步地,在本申请的一种可能的实现方式中,上述显示参数包括显示设备的最 大显示亮度值,上述目标参数显示内容最大亮度值,调整系数包括线性域调整系数和非线性域调整系数,上述计算单元具体用于:根据显示内容最大亮度值和图像处理装置的最大显示亮度值,采用下述公式计算线性域调整系数:Further, in a possible implementation manner of the present application, the foregoing display parameter includes a display device The display unit displays a brightness value, and the target parameter displays a maximum brightness value of the content. The adjustment coefficient includes a linear domain adjustment coefficient and a nonlinear domain adjustment coefficient. The calculation unit is specifically configured to: display a maximum brightness value according to the content and a maximum display brightness value of the image processing device. Calculate the linear domain adjustment factor using the following formula:
linear_adjust_factorLinear_adjust_factor
=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)
其中,linear_adjust_factor为线性域调整系数,Max_Display_Target_Luminance为显示设备的最大显示亮度值,Max_Content_Light_Level为显示内容最大亮度值,min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)表示取1.0和Max_Display_Target_Luminance/Max_Content_Light_Level的最小值;Wherein, linear_adjust_factor is a linear domain adjustment coefficient, Max_Display_Target_Luminance is a maximum display brightness value of the display device, Max_Content_Light_Level is a maximum brightness value of the display content, and min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) represents a minimum value of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level;
根据显示内容最大亮度值和显示设备的最大显示亮度值,采用下述公式计算非线性域调整系数:According to the maximum brightness value of the display content and the maximum display brightness value of the display device, the nonlinear domain adjustment coefficient is calculated by the following formula:
Figure PCTCN2017099365-appb-000004
Figure PCTCN2017099365-appb-000004
其中,nonlinear_adjust_factor为所述非线性域调整系数,OETF(·)表示光电转换函数。Wherein, the nonlinear_adjust_factor is the nonlinear domain adjustment coefficient, and the OETF (·) represents the photoelectric conversion function.
进一步地,在本申请的另一种可能的实现方式中,上述目标参数还包括显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性色度缩放量化中的至少一个。相应的,上述更新单元具体用于:将线性域调整系数与显示内容最大亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大亮度值;当目标参数包括上述显示内容最大图像平均亮度值时,将线性域调整系数与显示内容最大图像平均亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大图像平均亮度值;当目标参数包括上述显示内容非线性亮度分量最大值时,将非线性域调整系数与显示内容非线性亮度分量最大值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量最大值;当目标参数包括上述显示内容非线性亮度分量最小值时,将非线性域调整系数与显示内容非线性亮度分量最小值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量最小值;当目标参数包括上述显示内容非线性亮度分量平均值时,将非线性域调整系数与显示内容非线性亮度分量平均值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量平均值;当目标参数包括上述显示内容非线性亮度分量标准方差值时,将非线性域调整系数与显示内容非线性亮度分量标准方差值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量标准方差值;当目标参数包括上述显示内容非线性亮度缩放量化时,将显示内容非线性亮度缩放量化的数值设置为第一预设阈值;当目标参数包括显示内容非线性色度缩放量化时,将显示内容非线性色度缩放量化的数值设置为第二预设阈值;当目标参数包括显示内容非线性亮度伽马值时,将显示内容非线性亮度伽马值的数值设置为第三预设阈值。Further, in another possible implementation manner of the present application, the target parameter further includes: a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, and a non-display content. At least one of a linear luminance component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization. Correspondingly, the updating unit is specifically configured to: multiply the linear domain adjustment coefficient by the maximum brightness value of the display content, and quantize to an unsigned integer to obtain an updated maximum brightness value of the display content; and when the target parameter includes the maximum image of the display content. When the average brightness value is obtained, the linear domain adjustment coefficient is multiplied by the maximum image average brightness value of the display content, and quantized into an unsigned integer to obtain an updated image maximum brightness value of the display content; when the target parameter includes the above-mentioned display content nonlinear brightness When the component maximum value is multiplied, the nonlinear domain adjustment coefficient is multiplied by the maximum value of the nonlinear luminance component of the display content, and quantized into an unsigned integer, and the updated maximum nonlinear luminance component of the display content is obtained; when the target parameter includes the above display content When the nonlinear luminance component is the minimum value, the nonlinear domain adjustment coefficient is multiplied by the minimum value of the nonlinear luminance component of the display content, and quantized into an unsigned integer, and the minimum value of the nonlinear luminance component of the updated display content is obtained; when the target parameter includes When the above average content of the nonlinear luminance component is displayed, The linear domain adjustment coefficient is multiplied by the average value of the nonlinear luminance component of the display content, and quantized into an unsigned integer to obtain an average value of the updated nonlinear luminance component of the display content; when the target parameter includes the standard deviation of the nonlinear luminance component of the display content described above; In the value, the nonlinear domain adjustment coefficient is multiplied by the standard variance value of the non-linear luminance component of the display content, and quantized into an unsigned integer, and the updated standard deviation of the nonlinear brightness component of the display content is obtained; when the target parameter includes the above When displaying the content nonlinear brightness scaling quantization, the value of the content non-linear brightness scaling quantization is set to a first preset threshold; when the target parameter includes the display content nonlinear chromaticity scaling quantization, the content nonlinear chromaticity scaling quantization is displayed. The value is set to a second preset threshold; when the target parameter includes the display content non-linear luminance gamma value, the value of the display content nonlinear luminance gamma value is set to a third preset threshold.
本申请中第四方面及其各种实现方式的具体描述,可以参考第三方面及其各种实现方式中的详细描述;并且,第四方面及其各种实现方式的有益效果,可以参考第三 方面及其各种实现方式中的有益效果分析,此处不再赘述。For a detailed description of the fourth aspect of the present application and various implementations thereof, reference may be made to the detailed description in the third aspect and various implementation manners thereof; and the beneficial effects of the fourth aspect and various implementation manners thereof may be referred to three The analysis of the beneficial effects in aspects and various implementations thereof will not be repeated here.
第五方面,提供一种图像处理装置,该图像处理装置包括:一个或多个处理器、存储器、通信接口。其中,存储器、通信接口与一个或多个处理器耦合;图像处理装置通过通信接口与其他设备通信;存储器用于存储计算机程序代码,计算机程序代码包括指令,当一个或多个处理器执行所述指令时,图像处理装置执行如前述第一方面及其任意一种可能的实现方式所述的图像处理方法或者执行如前述第三方面及其任意一种可能的实现方式所述的图像处理方法。In a fifth aspect, an image processing apparatus is provided, the image processing apparatus comprising: one or more processors, a memory, and a communication interface. Wherein the memory, communication interface is coupled to one or more processors; the image processing device is in communication with other devices via a communication interface; the memory is for storing computer program code, the computer program code comprising instructions, when the one or more processors perform the When instructed, the image processing apparatus performs the image processing method as described in the foregoing first aspect and any one of its possible implementations or the image processing method as described in the foregoing third aspect and any one of its possible implementations.
第六方面,提供一种计算机存储介质,该计算机存储介质中存储有计算机程序代码。当第五方面中的图像处理装置的处理器执行该计算机程序代码时,图像处理装置执行如前述第一方面及其任意一种可能的实现方式所述的图像处理方法或者执行如前述第三方面及其任意一种可能的实现方式所述的图像处理方法。In a sixth aspect, a computer storage medium is provided having stored therein computer program code. When the processor of the image processing apparatus in the fifth aspect executes the computer program code, the image processing apparatus performs the image processing method as described in the foregoing first aspect and any one of its possible implementation manners or performs the third aspect as described above And an image processing method as described in any of the possible implementations.
第七方面,还提供一种包含指令的计算机程序产品,当其在图像处理装置上运行时,使得图像处理装置执行如前述第一方面及其任意一种可能的实现方式所述的图像处理方法或者执行如前述第三方面及其任意一种可能的实现方式所述的图像处理方法。A seventh aspect, further provides a computer program product comprising instructions, when executed on an image processing device, causing the image processing device to perform an image processing method as described in the first aspect above and any one of its possible implementations Or an image processing method as described in the foregoing third aspect and any one of the possible implementations.
在本申请中,上述图像处理装置的名字对设备或功能模块本身不构成限定,在实际实现中,这些设备或功能模块可以以其他名称出现。只要各个设备或功能模块的功能和本申请类似,属于本申请权利要求及其等同技术的范围之内。In the present application, the name of the above image processing apparatus is not limited to the device or the function module itself. In actual implementation, these devices or function modules may appear under other names. As long as the functions of the respective devices or functional modules are similar to the present application, they are within the scope of the claims and their equivalents.
本申请中第五方面、第六方面、第七方面及其各种实现方式的具体描述,可以参考第一方面及其各种实现方式中的详细描述,或者参考第三方面及其各种实现方式中的详细描述;并且,第二方面、第三方面、第四方面、第五方面及其各种实现方式的有益效果,可以参考第一方面及其各种实现方式中的有益效果分析,或者参考第三方面及其各种实现方式中的有益效果分析,此处不再赘述。For a detailed description of the fifth aspect, the sixth aspect, the seventh aspect, and various implementations thereof, reference may be made to the detailed description in the first aspect and various implementations thereof, or to the third aspect and various implementations thereof. A detailed description of the manner; and the beneficial effects of the second aspect, the third aspect, the fourth aspect, the fifth aspect, and various implementations thereof, may refer to the beneficial effects analysis in the first aspect and various implementation manners thereof, Or refer to the beneficial effects analysis in the third aspect and various implementation manners thereof, and details are not described herein again.
本申请实施例的这些方面或其他方面在以下的描述中会更加简明易懂。These and other aspects of the embodiments of the present application will be more apparent from the following description.
附图说明DRAWINGS
图1为本申请实施例提供的图像处理系统的结构示意图;FIG. 1 is a schematic structural diagram of an image processing system according to an embodiment of the present application;
图2为本申请实施例提供的一种电子设备的硬件结构示意图;2 is a schematic structural diagram of hardware of an electronic device according to an embodiment of the present application;
图3为本申请实施例提供的图像处理方法的流程示意图一;FIG. 3 is a schematic flowchart 1 of an image processing method according to an embodiment of the present disclosure;
图4为本申请实施例提供的双曲正切函数的曲线图;4 is a graph of a hyperbolic tangent function provided by an embodiment of the present application;
图5为本申请实施例提供的图像处理方法的流程示意图二;FIG. 5 is a second schematic flowchart of an image processing method according to an embodiment of the present disclosure;
图6为本申请实施例提供的图像处理装置的结构示意图。FIG. 6 is a schematic structural diagram of an image processing apparatus according to an embodiment of the present application.
具体实施方式Detailed ways
本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”和“第三”等是用于区别不同对象,而不是用于限定特定顺序。The terms "first", "second", and "third" and the like in the specification and claims of the present application and the above drawings are used to distinguish different objects, and are not intended to limit the specific order.
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of the present application, the words "exemplary" or "such as" are used to mean an example, illustration, or illustration. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be construed as preferred or advantageous over other embodiments or designs. Rather, the use of the words "exemplary" or "such as" is intended to present the concepts in a particular manner.
在很多领域中,动态范围由某个变量的最大值与最小值之间的比率表示。通常,图像的动态范围可以由显示图像的最大亮度值与最小亮度值之间的比率表示。 In many fields, the dynamic range is represented by the ratio between the maximum and minimum values of a variable. In general, the dynamic range of an image can be represented by the ratio between the maximum brightness value and the minimum brightness value of the displayed image.
HDR图像是一种亮度范围非常广的图像,与普通图像的存储格式不同。普通联合图像专家小组(Joint Photographic Experts Group,JPEG),图像文件格式(Bitmap,BMP)图像均采用8位整型数据保存单个通道分量,例如:对于红色(Red,R)通道分量、绿色(Green,G)以及蓝色(Blue,B),普通图像的每个通道分量均采用8位整形数据保存,单个像素点共24位。HDR图像的每个通道分量均采用浮点数表示,每个通道分量采用32位数据存储,使得图像的动态范围得以最大程度的保留。An HDR image is an image with a very wide range of brightness, which is different from the storage format of a normal image. Joint Photographic Experts Group (JPEG), image file format (Bitmap, BMP) images use 8-bit integer data to store individual channel components, for example: for red (R, R) channel components, green (Green) , G) and blue (Blue, B), each channel component of the ordinary image is saved with 8-bit shaping data, and a single pixel has a total of 24 bits. Each channel component of the HDR image is represented by a floating point number, and each channel component is stored in 32-bit data, so that the dynamic range of the image is preserved to the utmost extent.
HDR图像的亮度范围为10-3~106cd/m2,因此,HDR图像能够逼真地表示现实世界。HDR图像能够记录在整个可见范围内的亮度,并且能够支持动态范围和与人类的视觉特征的色域等效的色域。The luminance of the HDR image ranges from 10 -3 to 10 6 cd/m 2 , so the HDR image can realistically represent the real world. The HDR image is capable of recording brightness over the entire visible range and is capable of supporting dynamic range and color gamut equivalent to the color gamut of human visual features.
一般的,将显示动态范围不足0.1~400cd/m2的显示设备称为LDR显示设备,将显示动态范围超过0.01~540cd/m2的显示设备称为HDR显示设备。其中,不同HDR显示设备的显示动态范围不同,例如:0.01~540cd/m2的HDR显示设备、0.005~1000cd/m2的HDR显示设备等。Generally, a display device having a display dynamic range of less than 0.1 to 400 cd/m 2 is referred to as an LDR display device, and a display device having a display dynamic range of more than 0.01 to 540 cd/m 2 is referred to as an HDR display device. The display dynamic range of different HDR display devices is different, for example, an HDR display device of 0.01 to 540 cd/m 2 , an HDR display device of 0.005 to 1000 cd/m 2 , and the like.
由于LDR显示设备能够显示的图像的动态范围是有限的,不同HDR显示设备的显示动态范围不同,因此,采用LDR显示设备和HDR显示设备显示HDR图像时,均需适应性调整(压缩或拉伸)HDR图像的动态范围,才能清楚、完善的显示HDR图像。Since the dynamic range of the image that the LDR display device can display is limited, the display dynamic range of different HDR display devices is different. Therefore, when the HDR image is displayed by the LDR display device and the HDR display device, adaptive adjustment (compression or stretching is required). The dynamic range of the HDR image is sufficient to display the HDR image clearly and perfectly.
目前,图像处理装置使用图像帧的目标参数调整图像帧的动态范围。图像帧的目标参数用于表征该图像帧的显示内容性能指标。具体的,图像处理装置获取当前图像帧的目标参数的统计值,并利用上一图像帧的目标参数的参考值和固定的更新系数(一般为0.1),计算当前图像帧的目标参数的更新后的统计值,进而根据计算出的更新后的统计值调整当前图像帧的动态范围。由于实时播放的需要,当前图像帧的目标参数的统计值一般使用当前帧的前一相邻帧的目标参数近似代替。现有的更新系数的数值为固定值,如果固定值选择较小则HDR图像的目标参数的统计值的更新速度较慢,这样,在图像场景切换时,HDR图像帧的目标参数的统计值与HDR图像帧无法同步,导致HDR图像出现较大延迟。如果固定值选择较大,HDR图像的目标参数的统计值更新速度较快,这样,在图像场景切换时,HDR图像帧的目标参数的统计值与HDR图像帧无法同步,导致HDR图像出现闪烁。Currently, image processing devices use the target parameters of an image frame to adjust the dynamic range of an image frame. The target parameter of the image frame is used to characterize the display content performance indicator of the image frame. Specifically, the image processing device acquires a statistical value of the target parameter of the current image frame, and uses the reference value of the target parameter of the previous image frame and a fixed update coefficient (generally 0.1) to calculate the update of the target parameter of the current image frame. The statistical value, and then adjust the dynamic range of the current image frame according to the calculated updated statistical value. Due to the need for real-time playback, the statistical value of the target parameter of the current image frame is generally approximated using the target parameter of the previous adjacent frame of the current frame. The value of the existing update coefficient is a fixed value. If the fixed value is selected to be small, the update value of the target value of the HDR image is slower. Thus, when the image scene is switched, the statistical value of the target parameter of the HDR image frame is HDR image frames cannot be synchronized, resulting in a large delay in the HDR image. If the fixed value is selected to be large, the statistical value of the target parameter of the HDR image is updated faster, so that when the image scene is switched, the statistical value of the target parameter of the HDR image frame cannot be synchronized with the HDR image frame, resulting in flickering of the HDR image.
针对上述问题,本申请实施例提供一种图像处理方法及装置,图像处理装置通过获取待处理图像帧的前一相邻帧的目标参数的参考值以及待处理图像帧的目标参数的统计值,并计算二者之间的差值的绝对值,然后,该图像处理装置以计算出的绝对值为变量,利用双曲正切函数计算出更新系数,进而根据计算出的更新系数、上述参考值和上述统计值,利用时域滤波函数,计算出待处理图像帧的目标参数的更新后的统计值,最后,该图像处理装置根据计算出的更新后的统计值计算出用于调整待处理图像帧的动态范围和色彩的显示适配参数,从而使得该图像处理装置根据显示适配参数调整待处理图像帧。由于双曲正切函数具备单调递增,且曲线的变化特征为两端较为剧烈,中间平缓的特性,因此,在上述绝对值较大的情况下,该图像处理装置也可以获取到适当的更新系数,这样,图像处理装置能够迅速的更新待处理图像帧的目标参数的统计值,快速实现待处理图像帧的目标参数的统计值与调整后的待处理图像帧的 同步,有效的解决了图像延迟的问题;而且不会因为更新系数选择过大造成图像帧的闪烁,有效的避免了图像闪烁的问题。The image processing device provides an image processing method and device, and the image processing device obtains a reference value of a target parameter of a previous adjacent frame of the image frame to be processed and a statistical value of a target parameter of the image frame to be processed, And calculating an absolute value of the difference between the two, and then the image processing device calculates the update coefficient by using the hyperbolic tangent function, and further calculates the update coefficient, the reference value, and The statistical value is used to calculate the updated statistical value of the target parameter of the image frame to be processed by using the time domain filter function. Finally, the image processing apparatus calculates the image frame to be processed according to the calculated updated statistical value. The dynamic range and color display adaptation parameters cause the image processing device to adjust the image frame to be processed according to the display adaptation parameters. Since the hyperbolic tangent function has a monotonous increment, and the change characteristic of the curve is that the two ends are relatively sharp and the middle is gentle, the image processing apparatus can also obtain an appropriate update coefficient when the absolute value is large. In this way, the image processing apparatus can quickly update the statistical value of the target parameter of the image frame to be processed, and quickly realize the statistical value of the target parameter of the image frame to be processed and the adjusted image frame to be processed. Synchronization effectively solves the problem of image delay; and it does not cause the image frame to flicker due to the excessive selection of the update coefficient, effectively avoiding the problem of image flicker.
本申请实施例提供的图像处理方法适用于图像处理系统。图1是本申请实施例提供的图像处理系统的结构示意图。如图1所示,该图像处理系统包括图像处理装置10和显示设备11,图像处理装置10与显示设备11通信。The image processing method provided by the embodiment of the present application is applicable to an image processing system. FIG. 1 is a schematic structural diagram of an image processing system according to an embodiment of the present application. As shown in FIG. 1, the image processing system includes an image processing device 10 and a display device 11, and the image processing device 10 communicates with the display device 11.
在实际应用中,图像处理装置10和显示设备11之间的连接可以为有线连接,也可以为无线连接,为了方便直观地表示图像处理装置10和显示设备11之间的连接关系,图1中采用实线示意。In practical applications, the connection between the image processing apparatus 10 and the display device 11 may be a wired connection or a wireless connection, and the connection relationship between the image processing apparatus 10 and the display apparatus 11 is conveniently and intuitively represented in FIG. It is indicated by a solid line.
具体的,图像处理装置10能够获取到显示设备11所支持的动态范围,该图像处理装置10在获取到对应多个图像帧的码流后,将每个图像帧的动态范围进行调整,使得调整后的每个图像帧的动态范围与显示设备11所支持的动态范围匹配,该图像处理装置10在获取到调整后的每个图像帧后,将调整后的每个图像帧发送给显示设备11,便于显示设备11清晰、完整的显示调整后的每个图像帧。Specifically, the image processing device 10 can acquire the dynamic range supported by the display device 11, and after acquiring the code streams corresponding to the plurality of image frames, the image processing device 10 adjusts the dynamic range of each image frame to adjust The dynamic range of each subsequent image frame is matched with the dynamic range supported by the display device 11, and the image processing device 10 transmits each of the adjusted image frames to the display device 11 after acquiring the adjusted image frames. It is convenient for the display device 11 to display the adjusted image frame clearly and completely.
可选的,图像处理装置10可以从该图像处理装置所接入的网络中获取对应多个图像帧的码流,也可以接收与该图像处理装置建立通信连接的其他电子设备发送的对应多个图像帧的码流,本申请实施例对此不作具体限定。Optionally, the image processing apparatus 10 may acquire a code stream corresponding to multiple image frames from a network accessed by the image processing apparatus, or may receive corresponding multiples sent by other electronic devices that establish a communication connection with the image processing apparatus. The code stream of the image frame is not specifically limited in this embodiment of the present application.
本申请实施例中的图像处理装置10和显示设备11均可以为电子设备。可选的,本申请实施例中的图像处理装置10和显示设备11可以是相互独立的,也可以集成在同一电子设备。图1中以图像处理装置10和显示设备11相互独立设置为例。The image processing device 10 and the display device 11 in the embodiments of the present application may each be an electronic device. Optionally, the image processing device 10 and the display device 11 in the embodiment of the present application may be independent of each other, or may be integrated in the same electronic device. In FIG. 1, the image processing apparatus 10 and the display device 11 are independently provided as an example.
示例性的,若本申请实施例中的图像处理装置10和显示设备11是相互独立的,则本申请实施例中的图像处理装置10可以为机顶盒,显示设备11可以为电视机。For example, if the image processing apparatus 10 and the display device 11 in the embodiment of the present application are independent of each other, the image processing apparatus 10 in the embodiment of the present application may be a set top box, and the display apparatus 11 may be a television set.
若图像处理装置10和显示设备11集成在同一电子设备,则该电子设备具体可以为手机、相机、可穿戴设备、增强现实(Augmented Reality,AR)\虚拟现实(Virtual Reality,VR)设备、平板电脑、笔记本电脑、超级移动个人计算机(Ultra-Mobile Personal Computer,UMPC)、上网本、个人数字助理(Personal Digital Assistant,PDA)等任意具有图像显示功能的设备,本申请实施例对此不作任何限制。If the image processing device 10 and the display device 11 are integrated in the same electronic device, the electronic device may be a mobile phone, a camera, a wearable device, an augmented reality (AR), a virtual reality (VR) device, or a tablet. Any device having an image display function, such as a computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, and a personal digital assistant (PDA), is not limited in this embodiment.
结合上述描述可知,本申请实施例中的图像处理装置10和显示设备11均可以为电子设备。本申请实施例中电子设备的硬件结构可以参考图2所示的电子设备的构成部件。The image processing device 10 and the display device 11 in the embodiments of the present application may each be an electronic device. For the hardware structure of the electronic device in the embodiment of the present application, reference may be made to the constituent components of the electronic device shown in FIG. 2.
应该理解的是,图示电子设备仅仅是图像处理装置10和显示设备11的一个范例,并且电子设备可以具有比图中所示出的更多的或者更少的部件,可以组合两个或更多的部件,或者可以具有不同的部件配置。图2中所示出的各种部件可以在包括一个或多个信号处理和/或专用集成电路在内的硬件、软件、或硬件和软件的组合中实现。It should be understood that the illustrated electronic device is only one example of the image processing device 10 and the display device 11, and the electronic device may have more or fewer components than those shown in the figures, and two or more may be combined. Many components, or can have different component configurations. The various components shown in FIG. 2 may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
如图2所示,电子设备具体可以包括:处理器21、电源22、存储器23、输入单元24、音频电路25等部件。本领域技术人员可以理解,图2中示出的电子设备结构并不构成对电子设备的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。As shown in FIG. 2, the electronic device may specifically include: a processor 21, a power source 22, a memory 23, an input unit 24, an audio circuit 25, and the like. It will be understood by those skilled in the art that the electronic device structure illustrated in FIG. 2 does not constitute a limitation to the electronic device, and may include more or less components than those illustrated, or a combination of certain components, or different component arrangements.
下面结合图2对电子设备的各个构成部件进行具体的介绍:The specific components of the electronic device will be specifically described below with reference to FIG. 2:
处理器21是电子设备的控制中心,利用各种接口和线路连接整个电子设备的各个 部分,通过运行或执行存储在存储器23内的软件程序和/或模块,以及调用存储在存储器23内的数据,执行电子设备的各种功能和处理数据,从而对电子设备进行整体监控。可选的,处理器21可包括一个或多个处理单元。可选的,处理器21可集成应用处理器和调制解调处理器。其中,应用处理器主要处理操作系统、用户界面和应用程序等;调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器与处理器21也可以是相互独立的。The processor 21 is a control center of the electronic device, and connects various parts of the entire electronic device by using various interfaces and lines. In part, the electronic device is integrally monitored by running or executing software programs and/or modules stored in the memory 23, and recalling data stored in the memory 23, performing various functions and processing data of the electronic device. Alternatively, processor 21 may include one or more processing units. Optionally, the processor 21 can integrate an application processor and a modem processor. The application processor mainly processes an operating system, a user interface, an application, and the like; the modem processor mainly processes wireless communication. It can be understood that the above-mentioned modem processor and processor 21 can also be independent of each other.
电子设备包括给各个部件供电的电源22(比如电池),可选的,电源22可以通过电源管理系统与处理器21逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The electronic device includes a power source 22 (such as a battery) for supplying power to each component. Alternatively, the power source 22 can be logically connected to the processor 21 through a power management system to manage functions such as charging, discharging, and power management through the power management system. .
存储器23可用于存储软件程序以及模块,处理器21通过运行存储在存储器23的软件程序以及模块,从而执行电子设备的各种功能应用以及数据处理。存储器23可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如接收数据功能、图像处理功能等)等;存储数据区可存储根据电子设备的使用所创建的数据(比如图像、视频等)等。此外,存储器23可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 23 can be used to store software programs and modules, and the processor 21 executes various functional applications and data processing of the electronic device by running software programs and modules stored in the memory 23. The memory 23 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function (such as receiving data function, image processing function, etc.), and the like; the storage data area may be stored according to Data created by the use of electronic devices (such as images, videos, etc.). Further, the memory 23 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
输入单元24可用于接收输入的数字或字符信息,以及产生与电子设备的用户设置以及功能控制有关的键信号输入。可选的,输入单元24可包括触摸屏241和其他输入设备242。触摸屏241,也称为触摸面板,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触摸屏241上或在触摸屏241附近的操作),并根据预先设定的程式驱动相应的连接装置。可选的,触摸屏241可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器21,并能接收处理器21发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触摸屏241。The input unit 24 can be configured to receive input numeric or character information and to generate key signal inputs related to user settings and function control of the electronic device. Alternatively, the input unit 24 may include a touch screen 241 and other input devices 242. The touch screen 241, also referred to as a touch panel, can collect touch operations on or near the user (such as the operation of the user using any suitable object or accessory on the touch screen 241 or near the touch screen 241 using a finger, a stylus, etc.), and according to The preset program drives the corresponding connection device. Alternatively, the touch screen 241 may include two parts of a touch detection device and a touch controller. Wherein, the touch detection device detects the touch orientation of the user, and detects a signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts the touch information into contact coordinates, and sends the touch information. The processor 21 is provided and can receive commands from the processor 21 and execute them. In addition, the touch screen 241 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves.
音频电路25可包括扬声器251和麦克风252,用于提供用户与电子设备之间的音频接口。音频电路25可将接收到的音频数据转换后的电信号,传输到扬声器251,由扬声器251转换为声音信号输出;另一方面,麦克风252将收集的声音信号转换为电信号,由音频电路25接收后转换为音频数据,再将音频数据输出至存储器23以便进一步处理。The audio circuit 25 can include a speaker 251 and a microphone 252 for providing an audio interface between the user and the electronic device. The audio circuit 25 can transmit the converted electrical data of the received audio data to the speaker 251, and is converted by the speaker 251 into a sound signal output; on the other hand, the microphone 252 converts the collected sound signal into an electrical signal, and the audio circuit 25 After receiving, it is converted into audio data, and the audio data is output to the memory 23 for further processing.
可选的,如图2所示,上述电子设备还包括显示单元25和摄像头26。由于显示单元26和摄像头27是可选的,因此,图2中用虚线表示。Optionally, as shown in FIG. 2, the electronic device further includes a display unit 25 and a camera 26. Since the display unit 26 and the camera 27 are optional, they are indicated by dashed lines in FIG.
显示单元26可用于显示由用户输入的信息或提供给用户的信息以及电子设备的各种菜单。显示单元26可包括显示面板261,可选的,可以采用液晶显示器(Liquid Crystal Display,LCD)、有机发光二极管(Organic Light-emitting Diode,OLED)等形式来配置显示面板261。进一步的,触摸屏241可覆盖显示面板261,当触摸屏241检测到在其上或附近的触摸操作后,传送给处理器21以确定触摸事件的类型,随后处理器21根据触摸事件的类型在显示面板261上提供相应的视觉输出。虽然,在图2 中,触摸屏241与显示面板261是作为两个独立的部件来实现电子设备的输入和输出功能,但是在某些实施例中,可以将触摸屏241与显示面板261集成而实现电子设备的输入和输出功能。The display unit 26 can be used to display information input by the user or information provided to the user as well as various menus of the electronic device. The display unit 26 can include a display panel 261. Alternatively, the display panel 261 can be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like. Further, the touch screen 241 may cover the display panel 261, and when the touch screen 241 detects a touch operation on or near it, transmits to the processor 21 to determine the type of the touch event, and then the processor 21 displays the panel according to the type of the touch event. A corresponding visual output is provided on the 261. Although, in Figure 2 The touch screen 241 and the display panel 261 are implemented as two separate components to implement input and output functions of the electronic device, but in some embodiments, the touch screen 241 can be integrated with the display panel 261 to implement input and output of the electronic device. Features.
摄像头27,也可以作为一种输入设备,具体用于将采集到的模拟视频或图像信号转换成数字信号,进而将其储存在存储器23中。具体的,摄像头27可以包括前置摄像头、后置摄像头、内置摄像头以及外置摄像头等,本申请实施例对此不作任何限制。The camera 27 can also be used as an input device for converting the collected analog video or image signal into a digital signal and storing it in the memory 23. Specifically, the camera 27 may include a front camera, a rear camera, a built-in camera, an external camera, and the like, which are not limited in this embodiment.
以下,将结合具体实施例详细阐述本申请实施例提供的一种图像处理方法。为了便于描述,下文均以图像处理装置和显示设备相互独立为例进行说明。Hereinafter, an image processing method provided by an embodiment of the present application will be described in detail in conjunction with specific embodiments. For convenience of description, the following description will be made by taking an image processing apparatus and a display device independently of each other as an example.
图3为本申请实施例提供的图像处理方法的流程示意图,该图像处理方法可以应用在图2所示的图像处理系统中。FIG. 3 is a schematic flowchart diagram of an image processing method according to an embodiment of the present disclosure, and the image processing method can be applied to the image processing system shown in FIG. 2 .
如图3所示,该图像处理方法包括:As shown in FIG. 3, the image processing method includes:
S300、图像处理装置得到对应多个图像帧的码流。S300. The image processing device obtains a code stream corresponding to the plurality of image frames.
本申请实施例所涉及到的图像帧均指HDR图像帧。The image frames involved in the embodiments of the present application all refer to HDR image frames.
可选的,图像处理装置可从该图像处理装置所接入的网络中获取对应多个图像帧的码流,也可以接收与该图像处理装置建立通信连接的其他电子设备发送的对应多个图像帧的码流,本申请实施例对此不作具体限定。Optionally, the image processing device may acquire a code stream corresponding to the plurality of image frames from a network accessed by the image processing device, or may receive a corresponding plurality of images sent by other electronic devices that establish a communication connection with the image processing device. The code stream of the frame is not specifically limited in this embodiment of the present application.
示例性的,若图像处理装置为数字机顶盒,则该数字机顶盒接收来自有线网的高频信号,通过解调接收到的高频信号,获取对应多个图像帧的码流。Exemplarily, if the image processing device is a digital set top box, the digital set top box receives the high frequency signal from the wired network, and obtains a code stream corresponding to the plurality of image frames by demodulating the received high frequency signal.
从前面描述可知,图像处理装置通过与显示设备通信,能够获取到该显示设备所支持的动态范围。为了便于显示设备能够清晰、完整的显示该图像处理装置获取到的图像帧,该图像处理装置执行调整每个图像帧的动态范围的流程。具体的,图像处理装置重复执行下述S301-S306完成图像帧的动态范围的调整。As can be seen from the foregoing description, the image processing apparatus can acquire the dynamic range supported by the display device by communicating with the display device. In order to facilitate the display device to clearly and completely display the image frames acquired by the image processing device, the image processing device performs a process of adjusting the dynamic range of each image frame. Specifically, the image processing apparatus repeatedly performs the following S301-S306 to complete the adjustment of the dynamic range of the image frame.
对于每个图像帧,图像处理装置的处理过程均相同,本申请实施例仅仅以图像处理装置调整待处理图像帧的动态范围为例进行说明。待处理图像帧为上述多个图像帧中的任意一个。The processing procedure of the image processing apparatus is the same for each image frame. The embodiment of the present application is only described by taking an example in which the image processing apparatus adjusts the dynamic range of the image frame to be processed. The image frame to be processed is any one of the plurality of image frames described above.
S301、图像处理装置获取待处理图像帧的前一相邻帧的目标参数的参考值。S301. The image processing apparatus acquires a reference value of a target parameter of a previous adjacent frame of the image frame to be processed.
目标参数用于表征图像帧的显示内容性能指标。The target parameter is used to characterize the display content performance indicator of the image frame.
容易理解的是,若待处理图像帧为上述多个图像帧中的首个图像帧,则图像处理装置无法获取到参考值。It is easy to understand that if the image frame to be processed is the first image frame among the plurality of image frames, the image processing apparatus cannot acquire the reference value.
图像处理装置在得到对应多个图像帧的码流后,逐个调整码流中的每个图像帧的动态范围和色彩。在图像处理装置执行调整待处理图像帧的动态范围和色彩时,图像处理装置已调整待处理图像帧的前一相邻帧的动态范围和色彩,因此,该图像处理装置可直接获取到待处理图像帧的前一相邻帧的目标参数的参考值。After obtaining the code stream corresponding to the plurality of image frames, the image processing device adjusts the dynamic range and color of each image frame in the code stream one by one. When the image processing apparatus performs the adjustment of the dynamic range and color of the image frame to be processed, the image processing apparatus has adjusted the dynamic range and color of the previous adjacent frame of the image frame to be processed, and therefore, the image processing apparatus can directly acquire the to-be-processed The reference value of the target parameter of the previous adjacent frame of the image frame.
待处理图像帧的前一相邻图像帧的目标参数的参数值实质上为:图像处理装置在调整待处理图像帧的前一图像帧的动态范围和色彩之前,计算出的待处理图像帧的前一相邻图像帧的目标参数的更新后的统计值。为了便于理解,本申请均用参考值表示。The parameter value of the target parameter of the previous adjacent image frame of the image frame to be processed is substantially: the image processing device calculates the image frame to be processed before adjusting the dynamic range and color of the previous image frame of the image frame to be processed. The updated statistical value of the target parameter of the previous adjacent image frame. For ease of understanding, the present application is expressed by reference values.
S302、图像处理装置根据已获取图像帧的像素值,计算待处理图像帧的目标参数的统计值。 S302. The image processing apparatus calculates a statistical value of a target parameter of the image frame to be processed according to the pixel value of the acquired image frame.
这里,已获取图像帧的像素值可以为待处理图像帧的像素值。Here, the pixel value of the acquired image frame may be the pixel value of the image frame to be processed.
可选的,在图像处理装置实时处理其得到的码流的情况下,若待处理图像帧包括的像素点较多,则图像处理装置实时计算该待处理图像帧的目标参数的统计值需花费较长的时间,很容易出现延迟的问题。若待处理图像帧包括的像素点很少,图像处理装置则能够及时计算出该待处理图像帧的统计数据。为了避免出现延迟问题,当待处理图像帧为上述多个图像帧中的第t个图像帧时,图像处理装置根据多个图像帧中的第t-i个图像帧的像素值,计算第t-i个图像帧的目标参数,并将第t-i个图像帧的目标参数作为待处理图像帧的目标参数的统计值,t为非负整数,i为正整数。Optionally, in the case that the image processing device processes the obtained code stream in real time, if the image frame to be processed includes more pixels, the image processing device calculates the statistical value of the target parameter of the image frame to be processed in real time. For a long time, it is easy to have a delay. If the image frame to be processed includes few pixels, the image processing device can calculate the statistical data of the image frame to be processed in time. In order to avoid the delay problem, when the image frame to be processed is the t-th image frame among the plurality of image frames, the image processing apparatus calculates the ti image according to the pixel value of the tith image frame in the plurality of image frames. The target parameter of the frame, and the target parameter of the ti image frame is used as the statistical value of the target parameter of the image frame to be processed, t is a non-negative integer, and i is a positive integer.
本申请实施例中目标参数包括显示内容最大亮度值、显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性色度缩放量化中的至少一个。本申请实施例所涉及到的显示内容非线性亮度分量均用于表示显示内容非线性Y分量,显示内容非线性色度分量用于表示显示内容非线性Cb/Cr分量。The target parameters in the embodiment of the present application include a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, an average value of the nonlinear brightness component of the display content, and a display. At least one of a content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization. The non-linear luminance components of the display content involved in the embodiments of the present application are both used to represent the non-linear Y component of the display content, and the non-linear chrominance components of the display content are used to represent the non-linear Cb/Cr component of the display content.
为了更加清楚的理解本申请,现对上述各参数进行解释。For a clearer understanding of the present application, the above parameters are now explained.
显示内容最大亮度值,用于表示显示内容的最大亮度。本申请实施例用Max_Content_Light_Level表示显示内容最大亮度值,Max_Content_Light_Level为16位无符号整数,其范围为1cd/m2到65535cd/m2Displays the maximum brightness value of the content, which is used to indicate the maximum brightness of the displayed content. In the embodiment of the present application, the maximum brightness value of the display content is represented by Max_Content_Light_Level, and the Max_Content_Light_Level is a 16-bit unsigned integer ranging from 1 cd/m 2 to 65535 cd/m 2 .
具体的,Max_Content_Light_Level的数值为某一显示内容的所有显示图像的最大亮度(Picture_Max_Light_Level)的最大值。Specifically, the value of Max_Content_Light_Level is the maximum value of the maximum brightness (Picture_Max_Light_Level) of all display images of a certain display content.
对于某一显示图像而言,该显示图像的Picture_Max_Light_Level的计算方法为:计算该显示图像的有效显示区域内的每个像素点的红色(Red,R)、绿色(Green,G)、蓝色(Blue,B)分量的最大值maxRGB,该显示图像的Picture_Max_Light_Level的数值等于该显示图像的有效显示区域内的所有像素点的maxRGB中的最大值。这里,有效显示区域是指显示设备的有效显示区域。For a certain display image, the Picture_Max_Light_Level of the display image is calculated by calculating red (Red, R), green (Green, G), blue (for each pixel in the effective display area of the display image) The maximum value maxRGB of the Blue, B) component, the value of Picture_Max_Light_Level of the display image is equal to the maximum value of maxRGB of all the pixels in the effective display area of the display image. Here, the effective display area refers to an effective display area of the display device.
上述计算该显示图像的有效显示区域内的每个像素点的R、G、B分量的最大值maxRGB的方法为:将像素点的非线性(R',G',B')值转换为线性(R,G,B)值,并校准为以1cd/m2为单位的值;根据像素校准后的(R,G,B)值,计算得到像素R、G、B分量的最大值maxRGB。The method for calculating the maximum value maxRGB of the R, G, and B components of each pixel in the effective display area of the display image is: converting the nonlinear (R', G', B') values of the pixel points into linear The (R, G, B) value is calibrated to a value of 1 cd/m 2 ; the maximum value maxRGB of the pixel R, G, and B components is calculated from the (R, G, B) values after pixel calibration.
显示内容最大图像平均亮度,用于表示显示内容的最大图像平均亮度。本申请实施例用Max_Picture_Average_Light_Level表示显示内容最大图像平均亮度,Max_Picture_Average_Light_Level为16位无符号整数,其范围为1cd/m2到65535cd/m2The maximum image average brightness of the displayed content is used to indicate the maximum image average brightness of the displayed content. In the embodiment of the present application, the maximum image average brightness of the display content is represented by Max_Picture_Average_Light_Level, and the Max_Picture_Average_Light_Level is a 16-bit unsigned integer ranging from 1 cd/m 2 to 65535 cd/m 2 .
具体的,Max_Picture_Average_Light_Level的数值为某一显示内容的所有显示图像的图像平均亮度Picture_Average_Light_Level的最大值。Specifically, the value of Max_Picture_Average_Light_Level is the maximum value of the image average brightness Picture_Average_Light_Level of all display images of a certain display content.
对于某一显示图像而言,该显示图像的Picture_Average_Light_Level的计算方法为:计算该显示图像的有效显示区域内的每个像素点的R、G、B分量的最大值maxRGB,该显示图像的Picture_Max_Light_Level的数值等于该显示图像的有效显示区域内的所有像素点的maxRGB的平均值。For a certain display image, the calculation method of the Picture_Average_Light_Level of the display image is: calculating the maximum value maxRGB of the R, G, and B components of each pixel in the effective display area of the display image, and the Picture_Max_Light_Level of the display image The value is equal to the average of the maxRGB of all the pixels in the effective display area of the display image.
显示内容非线性亮度分量最大值,表示显示内容的像素点的非线性(R',G', B')值转换为非线性的(Y',Cb,Cr)值后,非线性Y'分量的最大值。本申请实施例用Content_Nonlinear_Max_Luminance表示显示内容非线性亮度分量最大值,Content_Nonlinear_Max_Luminance为16位无符号整数,以1.0/65535为单位,其取值范围从0到1。Display the maximum value of the nonlinear component of the content, indicating the nonlinearity of the pixel of the displayed content (R', G', The maximum value of the nonlinear Y' component after the B') value is converted to a non-linear (Y', Cb, Cr) value. In the embodiment of the present application, content_Nonlinear_Max_Luminance is used to represent the maximum value of the nonlinear luminance component of the display content, and Content_Nonlinear_Max_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
显示内容非线性亮度分量最小值,表示显示内容的像素点的非线性(R',G',B')值转换为非线性的(Y',Cb,Cr)值后,非线性Y'分量的最小值。本申请实施例用Content_Nonlinear_Min_Luminance表示显示内容非线性亮度分量最小值,Content_Nonlinear_Min_Luminance为16位无符号整数,以1.0/65535为单位,其取值范围从0到1。Display the minimum value of the nonlinear component of the content, indicating that the nonlinear (R', G', B') value of the pixel of the display content is converted to a nonlinear (Y', Cb, Cr) value, and the nonlinear Y' component The minimum value. In the embodiment of the present application, Content_Nonlinear_Min_Luminance is used to indicate the minimum value of the nonlinear luminance component of the display content, and Content_Nonlinear_Min_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
显示内容非线性亮度分量平均值,表示显示内容的像素点的非线性(R',G',B')值转换为非线性的(Y',Cb,Cr)值后,非线性Y'分量的平均值。本申请实施例用Content_Nonlinear_Average_Luminance表示显示内容非线性亮度分量平均值,Content_Nonlinear_Average_Luminance为16位无符号整数,以1.0/65535为单位,其取值范围从0到1。Displaying the average value of the nonlinear component of the content, indicating that the nonlinear (R', G', B') value of the pixel of the display content is converted to a nonlinear (Y', Cb, Cr) value, and the nonlinear Y' component average of. In the embodiment of the present application, Content_Nonlinear_Average_Luminance is used to represent the average value of the nonlinear luminance component of the display content, and Content_Nonlinear_Average_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
显示内容非线性Y分量标准方差,表示显示内容的像素点的非线性(R',G',B')值转换为非线性的(Y',Cb,Cr)值后,非线性Y'分量的标准方差。本申请实施例用Content_Nonlinear_Variance_Luminance表示显示内容非线性亮度分量平均值,Content_Nonlinear_Variance_Luminance为16位无符号整数,以1.0/65535为单位,其取值范围从0到1。Display the nonlinear variance of the component Y component, indicating that the nonlinear (R', G', B') value of the pixel of the display content is converted to a nonlinear (Y', Cb, Cr) value, and the nonlinear Y' component Standard variance. In the embodiment of the present application, content_Nonlinear_Variance_Luminance is used to represent the average value of the nonlinear luminance component of the display content, and Content_Nonlinear_Variance_Luminance is a 16-bit unsigned integer, which is in units of 1.0/65535, and the value ranges from 0 to 1.
显示内容非线性亮度缩放量化,表示显示内容的像素点的非线性Y'分量是否经过亮度缩放量化。本申请实施例用Content_Nonlinear_Scaling_Luminance表示显示内容非线性亮度缩放量化。示例性的,Content_Nonlinear_Scaling_Luminance的数值为1,表示该像素点经过亮度缩放量化,Content_Nonlinear_Scaling_Luminance的数值为0,表示该像素点未经过亮度缩放量化。The display content is non-linear luminance scaling quantization, indicating whether the nonlinear Y' component of the pixel of the display content is quantized by luminance scaling. The embodiment of the present application uses Content_Nonlinear_Scaling_Luminance to represent the non-linear luminance scaling quantization of the display content. Exemplarily, the value of Content_Nonlinear_Scaling_Luminance is 1, indicating that the pixel is subjected to luminance scaling quantization, and the value of Content_Nonlinear_Scaling_Luminance is 0, indicating that the pixel is not subjected to luminance scaling quantization.
显示内容非线性色度缩放量化,表示显示内容的像素点的非线性Y'分量是否经过色度缩放量化。本申请实施例用Content_Nonlinear_Scaling_Chrominance表示显示内容非线性色度缩放量化。示例性的,Content_Nonlinear_Scaling_Chrominance的数值为1,表示该像素点经过色度缩放量化,Content_Nonlinear_Scaling_Chrominance的数值为0,表示该像素点未经过色度缩放量化。The display content is non-linear chrominance scaling quantization, indicating whether the nonlinear Y' component of the pixel of the display content is subjected to chrominance scaling quantization. The embodiment of the present application uses Content_Nonlinear_Scaling_Chrominance to represent the non-linear chrominance scaling quantization of the display content. Exemplarily, the value of Content_Nonlinear_Scaling_Chrominance is 1, indicating that the pixel is subjected to chrominance scaling quantization, and the value of Content_Nonlinear_Scaling_Chrominance is 0, indicating that the pixel is not subjected to chrominance scaling quantization.
显示内容非线性亮度伽马值,表示显示内容的像素点的非线性Y'分量缩放量化的伽马值。本申请实施例用Content_Nonlinear_Scaling_Gamma表示显示内容非线性亮度伽马值,Content_Nonlinear_Scaling_Gamma为8位无符号整数,以1.0/128为单位。A non-linear luminance gamma value is displayed, which represents a non-linear Y' component of the pixel of the displayed content, and a quantized gamma value. The embodiment of the present application uses Content_Nonlinear_Scaling_Gamma to represent the non-linear luminance gamma value of the display content, and Content_Nonlinear_Scaling_Gamma is an 8-bit unsigned integer in units of 1.0/128.
S303、图像处理装置计算上述S301中参考值和上述S302中统计值的差值的绝对值。S303. The image processing apparatus calculates an absolute value of a difference between the reference value in the above S301 and the statistical value in the above S302.
示例性的,若用x表示上述绝对值,用Mt-1表示上述参考值,Ct表示上述统计值,则x=|Mt-1-Ct|。Illustratively, if the above absolute value is represented by x, the above reference value is represented by M t-1 , and C t represents the above statistical value, then x=|M t-1 -C t |.
S304、图像处理装置根据S303中计算出的绝对值,利用双曲正切函数,计算更新系数。S304. The image processing device calculates the update coefficient by using the hyperbolic tangent function based on the absolute value calculated in S303.
可选的,本申请实施例中的双曲正切函数如公式(1)所示: Optionally, the hyperbolic tangent function in the embodiment of the present application is as shown in formula (1):
Figure PCTCN2017099365-appb-000005
Figure PCTCN2017099365-appb-000005
其中,A为更新系数,x为上述绝对值,a为第一预设值,b为第二预设值。图像处理装置根据上述公式能够计算出更新系数。Where A is the update coefficient, x is the above absolute value, a is the first preset value, and b is the second preset value. The image processing apparatus can calculate the update coefficient based on the above formula.
示例性的,当a=3,b=0.5时,本申请实施例中的双曲正切函数如公式(2)所示:Exemplarily, when a=3, b=0.5, the hyperbolic tangent function in the embodiment of the present application is as shown in formula (2):
Figure PCTCN2017099365-appb-000006
Figure PCTCN2017099365-appb-000006
图4示出了上述公式(2)的曲线,从图4可以看出,双曲正切函数具备单调递增,且曲线的变化特性为两端较剧烈,中间平缓。当上述公式(2)的自变量x的数值较小时,应变量A的数值也较小;当自变量x的数值较大时,应变量A的数值也较大。由于该函数的自变量x表示上述绝对值,因此,自变量x的数值可以间接表示待处理图像帧与该待处理图像帧的前一相邻帧之间是否出现场景切换。一般的,若相邻两个图像帧的场景不同,则这两个图像帧的目标参数的统计值的差距较大。利用双曲正切函数计算更新系数,在上述绝对值较大的情况下,该图像处理装置也可以获取到较大的更新系数,这样,图像处理装置能够迅速的更新待处理图像帧的目标参数的统计值。Fig. 4 shows the curve of the above formula (2). As can be seen from Fig. 4, the hyperbolic tangent function has a monotonous increase, and the change characteristic of the curve is that the both ends are more intense and the middle is gentle. When the value of the independent variable x of the above formula (2) is small, the value of the dependent variable A is also small; when the value of the independent variable x is large, the value of the dependent variable A is also large. Since the argument x of the function represents the above absolute value, the value of the argument x can indirectly indicate whether a scene switch occurs between the image frame to be processed and the previous adjacent frame of the image frame to be processed. Generally, if the scenes of two adjacent image frames are different, the difference between the statistical values of the target parameters of the two image frames is large. The hyperbolic tangent function is used to calculate the update coefficient. In the case where the absolute value is large, the image processing apparatus can also acquire a large update coefficient, so that the image processing apparatus can quickly update the target parameter of the image frame to be processed. Statistics.
S305、图像处理装置根据更新系数、上述参考值以及上述统计值,利用时域滤波函数,计算待处理图像帧的目标参数的更新后的统计值。S305. The image processing apparatus calculates an updated statistical value of the target parameter of the image frame to be processed by using the time domain filter function according to the update coefficient, the reference value, and the statistical value.
当待处理图像帧为上述多个图像帧中的第t个图像帧,t=0时,该待处理图像帧为上述多个图像帧中的首个图像帧。When the image frame to be processed is the t-th image frame of the plurality of image frames, t=0, the image frame to be processed is the first image frame of the plurality of image frames.
从前面描述可知,当待处理图像帧为上述多个图像帧中的首个图像帧时,图像处理装置无法获取到上述参考值。具体的,当待处理图像帧为多个图像帧中的首个图像帧时,图像处理装置可确定待处理图像帧的目标参数的更新后的统计值为C0。其中,C0为第四预设值,或者,C0为图像处理装置通过解析码流获得。As can be seen from the foregoing description, when the image frame to be processed is the first image frame of the plurality of image frames, the image processing apparatus cannot acquire the reference value. Specifically, when the image frame to be processed is the first image frame of the plurality of image frames, the image processing apparatus may determine that the updated statistical value of the target parameter of the image frame to be processed is C 0 . Wherein C 0 is a fourth preset value, or C 0 is obtained by the image processing device by parsing the code stream.
示例性的,图像处理装置确定待处理图像帧的目标参数的更新后的统计值C0为:Max_Content_Light_Level=10000cd/m2,Max_Picture_Average_Light_Level=90cd/m2,Content_Nonlinear_Max_Luminance=65535,Content_Nonlinear_Min_Luminance=0,Content_Nonlinear_Average_Luminance=17000,Content_Nonlinear_Variance_Luminance=8500,Content_Nonlinear_Scaling_Luminance=0,Content_Nonlinear_Scaling_Chrominance=0,Content_Nonlinear_Scaling_Gamma=128。Exemplarily, the image processing apparatus determines that the updated statistical value C 0 of the target parameter of the image frame to be processed is: Max_Content_Light_Level=10000 cd/m 2 , Max_Picture_Average_Light_Level=90 cd/m 2 , Content_Nonlinear_Max_Luminance=65535, Content_Nonlinear_Min_Luminance=0, Content_Nonlinear_Average_Luminance=17000 Content_Nonlinear_Variance_Luminance=8500, Content_Nonlinear_Scaling_Luminance=0, Content_Nonlinear_Scaling_Chrominance=0, Content_Nonlinear_Scaling_Gamma=128.
当待处理图像帧为多个图像帧中的第t个图像帧,t>0时,图像处理装置采用下述公式(3)计算待处理图像帧的目标参数的更新后的统计值MtWhen the image frame to be processed is the t-th image frame of the plurality of image frames, when t>0, the image processing apparatus calculates the updated statistical value M t of the target parameter of the image frame to be processed by using the following formula (3):
Mt=A×Ct+B×Mt-1             (3)M t =A×C t +B×M t-1 (3)
其中,A为上述更新系数,Ct为待处理图像帧的目标参数的统计值,B为第三预设值,Mt-1为待处理图像帧的前一相邻帧的目标参数的参考值。Where A is the above update coefficient, C t is the statistical value of the target parameter of the image frame to be processed, B is the third preset value, and M t-1 is the reference of the target parameter of the previous adjacent frame of the image frame to be processed. value.
可选的,上述公式(3)中,B=1-A。这样,图像处理装置可及时根据更新系数进行加权,更加准确的计算出待处理图像帧的目标参数的更新后的统计值MtOptionally, in the above formula (3), B=1-A. In this way, the image processing apparatus can perform weighting according to the update coefficient in time, and more accurately calculate the updated statistical value M t of the target parameter of the image frame to be processed.
S306、图像处理装置根据待处理图像帧的目标参数的更新后的统计值,计算待处理图像帧的显示适配参数。S306. The image processing apparatus calculates a display adaptation parameter of the image frame to be processed according to the updated statistical value of the target parameter of the image frame to be processed.
显示适配参数用于调整待处理图像帧的动态范围和色彩。The display adaptation parameters are used to adjust the dynamic range and color of the image frame to be processed.
S307、图像处理装置根据显示适配参数,调整待处理图像帧。S307. The image processing apparatus adjusts the image frame to be processed according to the display adaptation parameter.
图像处理装置在计算出待处理图像帧的目标参数的更新后的统计值后,根据计算 出的更新后的统计值完成对待处理图像帧的动态范围和色彩的调整。图像处理装置根据待处理图像帧的目标参数的更新后的统计值计算待处理图像帧的显示适配参数的方法可以参考现有的计算显示适配参数的方法,此处不再进行详细赘述。After the image processing device calculates the updated statistical value of the target parameter of the image frame to be processed, according to the calculation The updated statistical value completes the adjustment of the dynamic range and color of the image frame to be processed. The method for the image processing device to calculate the display adaptation parameter of the image frame to be processed according to the updated statistical value of the target parameter of the image frame to be processed may refer to the existing method for calculating the display adaptation parameter, and details are not described herein again.
S308、图像处理装置获取调整后的待处理图像帧,并向显示设备发送调整后的待处理图像帧。S308. The image processing apparatus acquires the adjusted image frame to be processed, and sends the adjusted image frame to be processed to the display device.
S309、显示设备显示调整后的待处理图像帧。S309. The display device displays the adjusted image frame to be processed.
综上所述,本申请实施例中的图像处理装置实时计算参考值和统计值之间的差值的绝对值,并根据该绝对值,利用双曲正切函数计算更新系数。由于双曲正切函数具备单调递增,且曲线的变化特性为两端较剧烈,中间平缓,因此,在该绝对值较大的情况下,该图像处理装置也可以获取到适当的更新系数,这样,图像处理装置能够迅速的更新待处理图像帧的目标参数的统计值,实现待处理图像帧的目标参数的统计值与调整后的待处理图像帧的同步,有效的解决了图像延迟的问题,而且不会因为更新值选取过大造成图像的闪烁,有效的避免了图像闪烁的问题。In summary, the image processing apparatus in the embodiment of the present application calculates the absolute value of the difference between the reference value and the statistical value in real time, and calculates the update coefficient by using the hyperbolic tangent function according to the absolute value. Since the hyperbolic tangent function has a monotonous increment, and the change characteristic of the curve is that the two ends are relatively sharp and the middle is gentle, the image processing apparatus can also obtain an appropriate update coefficient when the absolute value is large, so that The image processing device can quickly update the statistical value of the target parameter of the image frame to be processed, realize the synchronization between the statistical value of the target parameter of the image frame to be processed and the adjusted image frame to be processed, and effectively solve the problem of image delay, and It will not cause the image to flicker because the update value is too large, which effectively avoids the problem of image flicker.
图像处理装置得到对应多个图像帧的码流后,调整了每个图像帧的动态范围和色彩,并未调整码流携带的目标参数。码流携带的目标参数为图像处理装置根据码流中的所有图像帧的像素值计算得到的,与码流中所有图像帧对应,用于表征码流中所有图像帧的显示内容性能指标。码流携带的目标参数为静态数据,该目标参数与未调整之前的所有图像帧对应。在图像处理装置调整每个图像帧的动态范围和色彩,未更新码流携带的目标参数的情况下,图像处理装置存储的码流携带的目标参数与调整后的图像帧不匹配。为了使得图像处理装置存储的码流携带的目标参数与调整后的图像帧匹配,图像处理装置还需适应性更新其存储的码流携带的目标参数,并将更新后的目标参数发送给显示设备,便于显示设备进一步地根据更新后的目标参数调整图像帧的动态范围和色彩,使得图像的显示更加清晰、完善。After the image processing device obtains the code stream corresponding to the plurality of image frames, the dynamic range and color of each image frame are adjusted, and the target parameters carried by the code stream are not adjusted. The target parameter carried by the code stream is calculated by the image processing device according to the pixel values of all image frames in the code stream, and corresponds to all the image frames in the code stream, and is used for characterizing the display content performance index of all image frames in the code stream. The target parameter carried by the code stream is static data, and the target parameter corresponds to all image frames before adjustment. When the image processing apparatus adjusts the dynamic range and color of each image frame and does not update the target parameter carried by the code stream, the target parameter carried by the code stream stored by the image processing apparatus does not match the adjusted image frame. In order to match the target parameter carried by the code stream stored by the image processing device with the adjusted image frame, the image processing device also needs to adaptively update the target parameter carried by the stored code stream, and send the updated target parameter to the display device. The display device is further adapted to adjust the dynamic range and color of the image frame according to the updated target parameter, so that the display of the image is more clear and perfect.
具体的,如图5所示,本申请实施例提供的图像处理方法包括:Specifically, as shown in FIG. 5, the image processing method provided by the embodiment of the present application includes:
S501、图像处理装置获取显示设备的显示参数。S501. The image processing device acquires display parameters of the display device.
图像处理装置通过与显示设备通信,能够获取到显示设备的显示参数。该显示参数包括显示设备的最大显示亮度值Max_Display_Target_Luminance。The image processing device can acquire display parameters of the display device by communicating with the display device. The display parameter includes the maximum display brightness value Max_Display_Target_Luminance of the display device.
S502、图像处理装置得到对应多个图像帧的码流,并从码流中获取目标参数。S502. The image processing device obtains a code stream corresponding to the plurality of image frames, and acquires a target parameter from the code stream.
这里,本实施例中的目标参数用于表征所有图像帧的显示内容性能指标。一般的,从码流中获取到的目标参数也可以称为从码流中获取到的元数据。Here, the target parameters in this embodiment are used to characterize the display content performance indicators of all image frames. In general, the target parameter obtained from the code stream may also be referred to as metadata acquired from the code stream.
本实施例中的目标参数包括显示内容最大亮度值Max_Content_Light_Level,还可以包括显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性色度缩放量化以及显示内容非线性亮度伽马值中的至少一个。The target parameter in this embodiment includes a display content maximum brightness value Max_Content_Light_Level, and may also include a display content maximum image average brightness value, a display content nonlinear brightness component maximum value, a display content nonlinear brightness component minimum value, and a display content nonlinear brightness component. The average value, the display content nonlinear luminance component standard variance value, the display content nonlinear luminance scaling quantization, the display content nonlinear chrominance scaling quantization, and the display content nonlinear luminance gamma value.
本实施例中的显示内容最大亮度值、显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性色度缩放量化以及显示内容非线性亮度伽马值均可参考图4所示实施例中描 述,此处不再进行详细赘述。The maximum brightness value of the display content, the maximum image average brightness value of the display content, the maximum value of the nonlinear brightness component of the display content, the minimum value of the nonlinear brightness component of the display content, the average value of the nonlinear brightness component of the display content, and the nonlinearity of the display content in this embodiment The luminance component standard variance value, the display content nonlinear luminance scaling quantization, the display content nonlinear chrominance scaling quantization, and the display content nonlinear luminance gamma value can be referred to in the embodiment shown in FIG. As described above, detailed descriptions are not repeated here.
与图4所示的实施例不同的是,本实施例中的目标参数是图像处理装置根据码流中的所有图像帧的像素值计算出的统计值,而图4所示的实施例中的目标参数是图像处理装置根据一个图像帧的像素值计算出的。Different from the embodiment shown in FIG. 4, the target parameter in this embodiment is a statistical value calculated by the image processing apparatus according to pixel values of all image frames in the code stream, and in the embodiment shown in FIG. The target parameter is calculated by the image processing device based on the pixel value of one image frame.
S503、图像处理装置根据显示参数和目标参数,计算调整系数。S503. The image processing apparatus calculates an adjustment coefficient according to the display parameter and the target parameter.
其中,调整系数包括线性域调整系数和非线性域调整系数。The adjustment coefficients include a linear domain adjustment coefficient and a nonlinear domain adjustment coefficient.
具体的,图像处理装置采用下述公式计算线性域调整系数:Specifically, the image processing apparatus calculates the linear domain adjustment coefficient using the following formula:
linear_adjust_factorLinear_adjust_factor
=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)
其中,min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)表示取1.0和Max_Display_Target_Luminance/Max_Content_Light_Level的最小值,linear_adjust_factor为线性域调整系数。Where min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) represents the minimum value of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level, and the linear_adjust_factor is a linear domain adjustment coefficient.
图像处理装置采用下述公式计算非线性域调整系数:The image processing apparatus calculates the nonlinear domain adjustment coefficient using the following formula:
Figure PCTCN2017099365-appb-000007
Figure PCTCN2017099365-appb-000007
其中,nonlinear_adjust_factor为上述非线性域调整系数,OETF(·)表示光电转换函数。Wherein, the nonlinear_adjust_factor is the above-mentioned nonlinear domain adjustment coefficient, and the OETF (·) represents the photoelectric conversion function.
S504、图像处理装置根据调整系数,更新其在S502中获取到的目标参数。S504. The image processing apparatus updates the target parameter acquired in S502 according to the adjustment coefficient.
具体的,图像处理装置将该显示内容最大亮度值与上述线性域调整系数相乘,并量化为16位无符号整数,得到更新后的显示内容最大亮度值。Specifically, the image processing device multiplies the maximum brightness value of the display content by the linear domain adjustment coefficient, and quantizes it into a 16-bit unsigned integer to obtain an updated maximum brightness value of the display content.
当图像处理装置获取到的目标参数包括显示内容最大图像平均亮度值时,该图像处理装置将该显示内容最大图像平均亮度值与上述线性域调整系数相乘,并量化为16位无符号整数,得到更新后的显示内容最大图像平均亮度值。When the target parameter acquired by the image processing device includes the maximum image average brightness value of the display content, the image processing device multiplies the maximum image average brightness value of the display content by the linear domain adjustment coefficient, and quantizes to a 16-bit unsigned integer. The updated image maximum brightness value of the displayed content is obtained.
当图像处理装置获取到的目标参数包括显示内容非线性亮度分量最大值时,该图像处理装置将该显示内容非线性亮度分量最大值与上述非线性域调整系数相乘,并量化为16位无符号整数,得到更新后的显示内容非线性亮度分量最大值。When the target parameter acquired by the image processing device includes a maximum value of the display content nonlinear luminance component, the image processing device multiplies the maximum value of the display content nonlinear luminance component by the nonlinear domain adjustment coefficient, and quantizes to 16 bits without The symbolic integer gives the maximum value of the non-linear luminance component of the updated display content.
当图像处理装置获取到的目标参数包括显示内容非线性亮度分量最小值时,该图像处理装置将该显示内容非线性亮度分量最小值与上述非线性域调整系数相乘,并量化为16位无符号整数,得到更新后的显示内容非线性亮度分量最小值。When the target parameter acquired by the image processing device includes a minimum value of the non-linear luminance component of the display content, the image processing device multiplies the minimum value of the nonlinear luminance component of the display content by the nonlinear domain adjustment coefficient, and quantizes to 16 bits without The symbolic integer gives the minimum value of the non-linear luminance component of the updated display content.
当图像处理装置获取到的目标参数包括显示内容非线性亮度分量平均值时,该图像处理装置将该显示内容非线性亮度分量平均值与上述非线性域调整系数相乘,并量化为16位无符号整数,得到更新后的显示内容非线性亮度分量平均值。When the target parameter acquired by the image processing device includes the average value of the non-linear luminance component of the display content, the image processing device multiplies the average value of the nonlinear luminance component of the display content by the nonlinear domain adjustment coefficient, and quantizes to 16 bits without A symbolic integer that yields an average of the non-linear luminance components of the updated display content.
当图像处理装置获取到的目标参数包括显示内容非线性亮度分量标准方差值时,该图像处理装置将该显示内容非线性亮度分量标准方差值与上述非线性域调整系数相乘,并量化为16位无符号整数,得到更新后的显示内容非线性亮度分量标准方差值。When the target parameter acquired by the image processing device includes a standard variance value of the display content nonlinear luminance component, the image processing device multiplies the standard content variance value of the display content nonlinear luminance component by the nonlinear domain adjustment coefficient, and quantizes For a 16-bit unsigned integer, the updated display component nonlinear luminance component standard variance value is obtained.
当图像处理装置获取到的目标参数包括显示内容非线性亮度缩放量化时,该图像处理装置将该显示内容非线性亮度缩放量化的数值设置为第一预设阈值。示例性的,该第一预设阈值为0。When the target parameter acquired by the image processing apparatus includes the display content nonlinear brightness scaling quantization, the image processing apparatus sets the numerical value of the display content nonlinear brightness scaling quantization to a first preset threshold. Exemplarily, the first preset threshold is 0.
当图像处理装置获取到的目标参数包括显示内容非线性色度缩放量化时,该图像 处理装置将该显示内容非线性色度缩放量化的数值设置为第二预设阈值。示例性的,该第二预设阈值为0。When the target parameter acquired by the image processing device includes non-linear chrominance scaling quantization of the display content, the image The processing device sets the numerical value of the display content nonlinear chromaticity scaling quantization to a second preset threshold. Exemplarily, the second preset threshold is zero.
当图像处理装置获取到的目标参数包括显示内容非线性亮度伽马值时,该图像处理装置将该显示内容非线性亮度伽马值的数值设置为第三预设阈值。示例性的,该第三预设阈值为128。When the target parameter acquired by the image processing apparatus includes the display content nonlinear luminance gamma value, the image processing apparatus sets the value of the display content nonlinear luminance gamma value to a third preset threshold. Exemplarily, the third preset threshold is 128.
S505、图像处理装置向显示设备发送更新后的目标参数。S505. The image processing apparatus sends the updated target parameter to the display device.
S506、显示设备根据更新后的目标参数调整图像帧的动态范围和色彩。S506. The display device adjusts a dynamic range and a color of the image frame according to the updated target parameter.
综上,采用本申请实施例提供的图像处理方法,可以保证图像处理装置存储的码流携带的目标参数和调整后的图像帧的匹配。In summary, the image processing method provided by the embodiment of the present application can ensure the matching between the target parameter carried by the code stream stored by the image processing device and the adjusted image frame.
图像处理装置在得到对应多个图像帧的码流后,调整每个图像帧的动态范围和色彩,图像处理装置通过执行上述S500-S504,根据显示设备的显示参数,计算更新系数,并利用更新系数更新码流携带的目标参数,这样,更新后的目标参数与显示设备的显示参数适配。相应的,图像处理装置执行上述S505,即图像处理装置向显示设备发送的码流所携带的目标参数为该图像处理装置更新后的目标参数。显示设备执行上述S506可直接利用更新后的目标参数调整每个图像帧的动态范围和色彩,这样,不仅使得该显示设备更加清晰、完善的显示调整后的每个图像帧,还提高了显示设备的性能。After obtaining the code stream corresponding to the plurality of image frames, the image processing device adjusts the dynamic range and color of each image frame, and the image processing device calculates the update coefficient according to the display parameters of the display device by executing the above S500-S504, and uses the update. The coefficient updates the target parameter carried by the code stream, such that the updated target parameter is adapted to the display parameters of the display device. Correspondingly, the image processing apparatus performs the above S505, that is, the target parameter carried by the code stream sent by the image processing apparatus to the display device is the target parameter updated by the image processing apparatus. The display device performs the above S506 to directly adjust the dynamic range and color of each image frame by using the updated target parameter, so that the display device not only makes the display device display the adjusted image frame more clearly and comprehensively, but also improves the display device. Performance.
本申请实施例提供一种图像处理装置,该图像处理装置用于执行以上图像处理方法中的图像处理装置所执行的步骤。本申请实施例提供的图像处理装置可以包括相应步骤所对应的模块。An embodiment of the present application provides an image processing apparatus for performing the steps performed by the image processing apparatus in the above image processing method. The image processing apparatus provided by the embodiment of the present application may include a module corresponding to the corresponding step.
本申请实施例可以根据上述方法示例对图像处理装置进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。The embodiment of the present application may divide the function module into the image processing device according to the above method example. For example, each function module may be divided according to each function, or two or more functions may be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. The division of modules in the embodiments of the present application is schematic, and is only a logical function division, and may be further divided in actual implementation.
在采用对应各个功能划分各个功能模块的情况下,图6示出了上述实施例中所涉及的图像处理装置的一种可能的结构示意图。如图6所示,图像处理装置600包括获取单元60、计算单元61、调整单元62、更新单元63、发送单元64和确定单元65。获取单元60用于支持该图像处理装置600执行上述实施例中的S300、S301、S325、S501、S502等,和/或用于本文所描述的技术的其它过程;计算单元61用于支持该图像处理装置600执行上述实施例中的S302、S303、S304、S305、S306、S503等,和/或用于本文所描述的技术的其它过程;调整单元62用于支持该图像处理装置600执行上述实施例中的S307等,和/或用于本文所描述的技术的其它过程;更新单元63用于支持该图像处理装置600执行上述实施例中的S504等,和/或用于本文所描述的技术的其它过程;发送单元64用于支持该图像处理装置600执行上述实施例中的S308、S505等,和/或用于本文所描述的技术的其它过程;确定单元65用于支持该图像处理装置600将上述计算单元61计算出的第t-i个图像帧的目标参数作为待处理图像帧的目标参数的统计值等,和/或用于本文所描述的技术的其它过程。其中,上述方法实施 例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。当然,本申请实施例提供的图像处理装置600包括但不限于上述模块,例如图像处理装置600还可以包括存储单元66。存储单元66可以用于存储该图像处理装置的程序代码和数据。In the case where the respective functional modules are divided by the respective functions, FIG. 6 shows a possible structural diagram of the image processing apparatus involved in the above embodiments. As shown in FIG. 6, the image processing apparatus 600 includes an acquisition unit 60, a calculation unit 61, an adjustment unit 62, an update unit 63, a transmission unit 64, and a determination unit 65. The obtaining unit 60 is configured to support the image processing apparatus 600 to execute S300, S301, S325, S501, S502, etc. in the above embodiments, and/or other processes for the techniques described herein; the computing unit 61 is configured to support the image The processing device 600 performs S302, S303, S304, S305, S306, S503, etc. in the above embodiments, and/or other processes for the techniques described herein; the adjustment unit 62 is configured to support the image processing device 600 to perform the above-described implementation S307, etc. in the example, and/or other processes for the techniques described herein; an update unit 63 for supporting the image processing device 600 to perform S504, etc. in the above-described embodiments, and/or for the techniques described herein Other processes; the transmitting unit 64 is configured to support the image processing apparatus 600 to perform S308, S505, etc. in the above embodiments, and/or other processes for the techniques described herein; the determining unit 65 is configured to support the image processing apparatus 600, using the target parameter of the tith image frame calculated by the above calculating unit 61 as a statistical value of the target parameter of the image frame to be processed, and the like, and/or for the technique described herein Process. Wherein, the above method is implemented All the related content of each step involved in the example can be referred to the function description of the corresponding function module, and details are not described herein again. Of course, the image processing apparatus 600 provided by the embodiment of the present application includes but is not limited to the above modules. For example, the image processing apparatus 600 may further include a storage unit 66. The storage unit 66 can be used to store program codes and data of the image processing apparatus.
在采用集成的单元的情况下,本申请实施例中的计算单元61、调整单元62、更新单元63和确定单元65可以是图2中的处理器21,获取单元60和发送单元64可以是图2中的输入单元24,存储单元66可以是图2中的存储器23。The calculation unit 61, the adjustment unit 62, the update unit 63, and the determination unit 65 in the embodiment of the present application may be the processor 21 in FIG. 2, and the acquisition unit 60 and the transmission unit 64 may be diagrams. In the input unit 24 of 2, the storage unit 66 may be the memory 23 in FIG.
当图像处理装置运行时,该图像处理装置执行如图3或图5所示的实施例的图像处理方法。具体的图像处理方法可参见上述如图3或图5所示的实施例中的相关描述,此处不再赘述。When the image processing apparatus operates, the image processing apparatus executes the image processing method of the embodiment as shown in FIG. 3 or 5. For a specific image processing method, refer to the related description in the foregoing embodiment shown in FIG. 3 or FIG. 5, and details are not described herein again.
本申请另一实施例还提供一种计算机存储介质,该计算机存储介质中存储有计算机程序代码,当图像处理装置中的处理器71在执行该程序代码时,该图像处理装置执行如图3或图5所示的图像处理方法。Another embodiment of the present application further provides a computer storage medium, where the computer program code is stored, when the processor 71 in the image processing device executes the program code, the image processing device executes as shown in FIG. 3 or The image processing method shown in FIG.
在本申请的另一实施例中,还提供一种计算机程序产品,该计算机程序产品包括计算机执行指令,该计算机执行指令存储在计算机可读存储介质中;图像处理装置的至少一个处理器可以从计算机可读存储介质读取该计算机执行指令,至少一个处理器执行该计算机执行指令使得图像处理装置实施执行图3或图5所示的图像处理方法中的图像处理装置的步骤。In another embodiment of the present application, there is also provided a computer program product comprising computer executed instructions stored in a computer readable storage medium; at least one processor of the image processing apparatus is The computer readable storage medium reads the computer to execute instructions, and the at least one processor executes the computer to execute the instructions such that the image processing apparatus implements the steps of performing the image processing apparatus in the image processing method illustrated in FIG. 3 or 5.
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Through the description of the above embodiments, those skilled in the art can clearly understand that for the convenience and brevity of the description, only the division of the above functional modules is illustrated. In practical applications, the above functions can be allocated according to needs. It is completed by different functional modules, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. For the specific working process of the system, the device and the unit described above, reference may be made to the corresponding process in the foregoing method embodiments, and details are not described herein again.
在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided by the present application, it should be understood that the disclosed system, apparatus, and method may be implemented in other manners. For example, the device embodiments described above are merely illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be another division manner, for example, multiple units or components may be used. Combinations can be integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, and may be in an electrical, mechanical or other form.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的 形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)或处理器执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:快闪存储器、移动硬盘、只读存储器、随机存取存储器、磁碟或者光盘等各种可以存储程序代码的介质。The integrated unit, if implemented in the form of a software functional unit and sold or used as a standalone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may contribute to the prior art or all or part of the technical solution may be in the form of a software product. Formally embodied, the computer software product is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor to perform the methods described in various embodiments of the present application. All or part of the steps. The foregoing storage medium includes: a flash memory, a mobile hard disk, a read only memory, a random access memory, a magnetic disk, or an optical disk, and the like, which can store program codes.
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何在本申请揭露的技术范围内的变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。 The foregoing is only a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto, and any changes or substitutions within the technical scope of the present application should be covered by the scope of the present application. . Therefore, the scope of protection of the present application should be determined by the scope of the claims.

Claims (21)

  1. 一种图像处理方法,其特征在于,包括:An image processing method, comprising:
    获取待处理图像帧的前一相邻帧的目标参数的参考值,所述目标参数用于表征图像帧的显示内容性能指标;Obtaining a reference value of a target parameter of a previous adjacent frame of the image frame to be processed, where the target parameter is used to represent a display content performance indicator of the image frame;
    根据已获取图像帧的像素值,计算所述待处理图像帧的目标参数的统计值;Calculating a statistical value of the target parameter of the image frame to be processed according to the pixel value of the acquired image frame;
    计算所述参考值和所述统计值的差值的绝对值;Calculating an absolute value of a difference between the reference value and the statistical value;
    根据所述绝对值,利用双曲正切函数,计算更新系数;Calculating an update coefficient using a hyperbolic tangent function according to the absolute value;
    根据所述更新系数、所述参考值以及所述统计值,利用时域滤波函数,计算所述待处理图像帧的目标参数的更新后的统计值;Calculating, according to the update coefficient, the reference value, and the statistical value, an updated statistical value of a target parameter of the image frame to be processed by using a time domain filter function;
    根据所述更新后的统计值,计算所述待处理图像帧的显示适配参数,所述显示适配参数用于调整所述待处理图像帧的动态范围和色彩;And displaying, according to the updated statistical value, a display adaptation parameter of the image frame to be processed, where the display adaptation parameter is used to adjust a dynamic range and a color of the image frame to be processed;
    根据所述显示适配参数,调整所述待处理图像帧。And adjusting the image frame to be processed according to the display adaptation parameter.
  2. 根据权利要求1所述的方法,其特征在于,所述根据所述绝对值,利用双曲正切函数,计算更新系数,具体包括:The method according to claim 1, wherein the calculating the update coefficient by using the hyperbolic tangent function according to the absolute value comprises:
    根据下述公式计算所述更新系数:The update coefficient is calculated according to the following formula:
    Figure PCTCN2017099365-appb-100001
    Figure PCTCN2017099365-appb-100001
    其中,A为所述更新系数,x为所述绝对值,a为第一预设值,b为第二预设值。Where A is the update coefficient, x is the absolute value, a is a first preset value, and b is a second preset value.
  3. 根据权利要求1或2所述的方法,其特征在于,所述方法还包括:得到对应多个图像帧的码流,所述待处理图像帧为所述码流对应的多个图像帧中的第t个图像帧,t为非负整数;The method according to claim 1 or 2, wherein the method further comprises: obtaining a code stream corresponding to the plurality of image frames, wherein the image frame to be processed is in a plurality of image frames corresponding to the code stream The tth image frame, t is a non-negative integer;
    所述根据所述更新系数、所述参考值以及所述统计值,利用时域滤波函数,计算所述待处理图像帧的目标参数的更新后的统计值,具体包括:And calculating, according to the update coefficient, the reference value, and the statistic value, the updated statistic value of the target parameter of the image frame to be processed by using a time domain filter function, specifically:
    采用下述公式计算所述更新后的统计值MtThe updated statistical value M t is calculated using the following formula:
    当t>0时,Mt=A×Ct+B×Mt-1When t>0, M t =A×C t +B×M t-1 ;
    当t=0时,Mt=C0When t=0, M t =C 0 ;
    其中,A为所述更新系数,Ct为所述统计值,B为第三预设值,Mt-1为所述参考值,C0为第四预设值,或者,C0为通过解析所述码流获得。A is the update coefficient, C t is the statistical value, B is a third preset value, M t-1 is the reference value, C 0 is a fourth preset value, or C 0 is passed. Parsing the code stream is obtained.
  4. 根据权利要求3所述的方法,其特征在于,B=1-A。The method of claim 3 wherein B = 1 - A.
  5. 根据权利要求3所述的方法,其特征在于,所述根据已获取图像帧的像素值,计算所述待处理图像帧的目标参数的统计值,具体包括:The method according to claim 3, wherein the calculating the statistical value of the target parameter of the image frame to be processed according to the pixel value of the acquired image frame comprises:
    根据所述多个图像帧中的第t-i个图像帧的像素值,计算所述第t-i个图像帧的目标参数,i为正整数;Calculating a target parameter of the t-ith image frame according to a pixel value of the t-ith image frame in the plurality of image frames, where i is a positive integer;
    将所述第t-i个图像帧的目标参数作为所述待处理图像帧的目标参数的统计值。The target parameter of the t-ith image frame is used as a statistical value of a target parameter of the image frame to be processed.
  6. 根据权利要求1-5中任意一项所述的方法,其特征在于,A method according to any one of claims 1 to 5, characterized in that
    所述目标参数包括显示内容最大亮度值、显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性色度缩放量化中的至少一个。 The target parameter includes a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, an average value of the nonlinear brightness component of the display content, and a nonlinear display content. At least one of a luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization.
  7. 一种图像处理方法,其特征在于,包括:An image processing method, comprising:
    获取显示设备的显示参数;Obtaining display parameters of the display device;
    从码流中获取目标参数,所述目标参数用于表征所述码流中的所有图像帧的显示内容性能指标;Obtaining a target parameter from a code stream, where the target parameter is used to represent a display content performance indicator of all image frames in the code stream;
    根据所述显示参数和所述目标参数,计算调整系数;Calculating an adjustment coefficient according to the display parameter and the target parameter;
    根据所述调整系数,更新所述目标参数;Updating the target parameter according to the adjustment coefficient;
    向所述显示设备发送更新后的目标参数,以使得所述显示设备根据所述更新后的目标参数调整图像帧的动态范围和色彩。And transmitting, to the display device, the updated target parameter, so that the display device adjusts a dynamic range and a color of the image frame according to the updated target parameter.
  8. 根据权利要求7所述的方法,其特征在于,所述显示参数包括所述显示设备的最大显示亮度值,所述目标参数包括显示内容最大亮度值,所述调整系数包括线性域调整系数和非线性域调整系数,The method according to claim 7, wherein the display parameter comprises a maximum display brightness value of the display device, the target parameter comprises a display content maximum brightness value, and the adjustment coefficient comprises a linear domain adjustment coefficient and a non- Linear domain adjustment factor,
    所述根据所述显示参数和所述目标参数,计算调整参数,包括:And calculating, according to the display parameter and the target parameter, an adjustment parameter, including:
    根据所述显示内容最大亮度值和所述显示设备的最大显示亮度值,采用下述公式计算所述线性域调整系数:And calculating the linear domain adjustment coefficient according to the maximum brightness value of the display content and the maximum display brightness value of the display device by using the following formula:
    linear_adjust_factorLinear_adjust_factor
    =min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)
    其中,linear_adjust_factor为所述线性域调整系数,Max_Display_Target_Luminance为所述显示设备的最大显示亮度值,Max_Content_Light_Level为所述显示内容最大亮度值,min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)表示取1.0和Max_Display_Target_Luminance/Max_Content_Light_Level的最小值;The linear_adjust_factor is the linear domain adjustment coefficient, Max_Display_Target_Luminance is the maximum display brightness value of the display device, Max_Content_Light_Level is the maximum brightness value of the display content, and min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) indicates the minimum of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level. value;
    根据所述显示内容最大亮度值和所述显示设备的最大显示亮度值,采用下述公式计算所述非线性域调整系数:And calculating the nonlinear domain adjustment coefficient according to the maximum brightness value of the display content and the maximum display brightness value of the display device by using the following formula:
    Figure PCTCN2017099365-appb-100002
    Figure PCTCN2017099365-appb-100002
    其中,nonlinear_adjust_factor为所述非线性域调整系数,OETF(·)表示光电转换函数。Wherein, the nonlinear_adjust_factor is the nonlinear domain adjustment coefficient, and the OETF (·) represents the photoelectric conversion function.
  9. 根据权利要求8所述的方法,其特征在于,所述目标参数还包括显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性色度缩放量化中的至少一个;The method according to claim 8, wherein the target parameter further comprises a display content maximum image average brightness value, a display content nonlinear brightness component maximum value, a display content nonlinear brightness component minimum value, and a display content nonlinear brightness. At least one of a component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear chrominance scaling quantization;
    所述根据所述调整系数,更新所述目标参数,具体包括:Updating the target parameter according to the adjustment coefficient, specifically:
    将所述线性域调整系数与所述显示内容最大亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大亮度值;And multiplying the linear domain adjustment coefficient by the maximum brightness value of the display content, and quantizing to an unsigned integer, to obtain an updated maximum brightness value of the display content;
    当所述目标参数包括所述显示内容最大图像平均亮度值时,将所述线性域调整系数与所述显示内容最大图像平均亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大图像平均亮度值;And when the target parameter includes the maximum image average brightness value of the display content, multiplying the linear domain adjustment coefficient by the maximum image average brightness value of the display content, and quantizing into an unsigned integer to obtain an updated display content. Maximum image average brightness value;
    当所述目标参数包括所述显示内容非线性亮度分量最大值时,将所述非线性域调整系数与所述显示内容非线性亮度分量最大值相乘,并量化为无符号整数,得到更新 后的显示内容非线性亮度分量最大值;And when the target parameter includes the display content non-linear luminance component maximum value, multiplying the nonlinear domain adjustment coefficient by the display content nonlinear luminance component maximum value, and quantizing to an unsigned integer, and obtaining an update The maximum content of the nonlinear brightness component of the displayed content;
    当所述目标参数包括所述显示内容非线性亮度分量最小值时,将所述非线性域调整系数与所述显示内容非线性亮度分量最小值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量最小值;When the target parameter includes the display content non-linear luminance component minimum value, the nonlinear domain adjustment coefficient is multiplied by the display content nonlinear luminance component minimum value, and quantized into an unsigned integer, and obtained after updating The display content is the minimum value of the nonlinear luminance component;
    当所述目标参数包括所述显示内容非线性亮度分量平均值时,将所述非线性域调整系数与所述显示内容非线性亮度分量平均值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量平均值;When the target parameter includes the display content non-linear luminance component average value, the nonlinear domain adjustment coefficient is multiplied by the display content nonlinear luminance component average value, and quantized into an unsigned integer, and obtained after updating The display content is the average of the nonlinear luminance components;
    当所述目标参数包括所述显示内容非线性亮度分量标准方差值时,将所述非线性域调整系数与所述显示内容非线性亮度分量标准方差值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量标准方差值;When the target parameter includes the display content nonlinear luminance component standard variance value, multiplying the nonlinear domain adjustment coefficient by the display content nonlinear luminance component standard variance value, and quantizing to an unsigned integer Obtaining a standard deviation value of the non-linear luminance component of the updated display content;
    当所述目标参数包括所述显示内容非线性亮度缩放量化时,将所述显示内容非线性亮度缩放量化的数值设置为第一预设阈值;When the target parameter includes the display content nonlinear brightness scaling quantization, setting the numerical value of the display content nonlinear brightness scaling quantization to a first preset threshold;
    当所述目标参数包括所述显示内容非线性色度缩放量化时,将所述显示内容非线性色度缩放量化的数值设置为第二预设阈值;When the target parameter includes the display content nonlinear chrominance scaling quantization, setting the numerical value of the display content nonlinear chrominance scaling quantization to a second preset threshold;
    当所述目标参数包括所述显示内容非线性亮度伽马值时,将所述显示内容非线性亮度伽马值的数值设置为第三预设阈值。When the target parameter includes the display content non-linear luminance gamma value, the value of the display content non-linear luminance gamma value is set to a third preset threshold.
  10. 一种图像处理装置,其特征在于,包括:An image processing apparatus, comprising:
    获取单元,用于获取多个图像帧,以及获取所述多个图像帧中待处理图像帧的前一相邻帧的目标参数的参考值,所述目标参数用于表征图像帧的显示内容性能指标;And an acquiring unit, configured to acquire a plurality of image frames, and obtain reference values of target parameters of a previous adjacent frame of the image frame to be processed in the plurality of image frames, where the target parameter is used to represent performance performance of the image frame index;
    计算单元,用于根据所述获取单元获取到的已获取图像帧的像素值,计算所述待处理图像帧的目标参数的统计值,以及用于计算所述获取单元获取到的所述参考值和所述统计值的差值的绝对值,以及用于根据所述绝对值,利用双曲正切函数,计算更新系数,以及用于根据所述更新系数、所述参考值以及所述统计值,利用时域滤波函数,计算所述待处理图像帧的目标参数的更新后的统计值,以及用于根据所述更新后的统计值,计算所述待处理图像帧的显示适配参数,所述显示适配参数用于调整所述待处理图像帧的动态范围和色彩;a calculating unit, configured to calculate a statistic value of the target parameter of the image frame to be processed according to the pixel value of the acquired image frame acquired by the acquiring unit, and calculate the reference value acquired by the acquiring unit An absolute value of a difference from the statistical value, and for calculating an update coefficient using the hyperbolic tangent function according to the absolute value, and for using the update coefficient, the reference value, and the statistical value, Calculating, by using a time domain filter function, an updated statistical value of the target parameter of the image frame to be processed, and calculating a display adaptation parameter of the image frame to be processed according to the updated statistical value, Displaying adaptation parameters for adjusting a dynamic range and color of the image frame to be processed;
    调整单元,用于根据所述计算单元计算出的所述显示适配参数,调整所述待处理图像帧。And an adjusting unit, configured to adjust the image frame to be processed according to the display adaptation parameter calculated by the calculating unit.
  11. 根据权利要求10所述的图像处理装置,其特征在于,所述计算单元具体用于:The image processing device according to claim 10, wherein the calculating unit is specifically configured to:
    根据下述公式计算所述更新系数:The update coefficient is calculated according to the following formula:
    Figure PCTCN2017099365-appb-100003
    Figure PCTCN2017099365-appb-100003
    其中,A为所述更新系数,x为所述绝对值,a为第一预设值,b为第二预设值。Where A is the update coefficient, x is the absolute value, a is a first preset value, and b is a second preset value.
  12. 根据权利要求10或11所述的图像处理装置,其特征在于,The image processing device according to claim 10 or 11, wherein
    所述获取单元,还用于得到对应多个图像帧的码流,所述待处理图像帧为所述码流对应的多个图像帧中的第t个图像帧,t为非负整数;The acquiring unit is further configured to obtain a code stream corresponding to the plurality of image frames, where the to-be-processed image frame is the t-th image frame of the plurality of image frames corresponding to the code stream, and t is a non-negative integer;
    所述计算单元具体用于:采用下述公式计算所述更新后的统计值MtThe calculating unit is specifically configured to: calculate the updated statistical value M t by using the following formula:
    当t>0时,Mt=A×Ct+B×Mt-1When t>0, M t =A×C t +B×M t-1 ;
    当t=0时,Mt=C0When t=0, M t =C 0 ;
    其中,A为所述更新系数,Ct为所述统计值,B为第三预设值,Mt-1为所述参考值,C0为第四预设值,或者,C0为通过解析所述码流获得。A is the update coefficient, C t is the statistical value, B is a third preset value, M t-1 is the reference value, C 0 is a fourth preset value, or C 0 is passed. Parsing the code stream is obtained.
  13. 根据权利要求12所述的图像处理装置,其特征在于,B=1-A。The image processing device according to claim 12, wherein B = 1 - A.
  14. 根据权利要求12所述的图像处理装置,其特征在于,The image processing device according to claim 12, wherein
    所述计算单元,还用于根据所述多个图像帧中的第t-i个图像帧的像素值,计算所述第t-i个图像帧的目标参数,i为正整数;The calculating unit is further configured to calculate, according to a pixel value of the t-ith image frame in the plurality of image frames, a target parameter of the t-ith image frame, where i is a positive integer;
    所述图像处理装置还包括确定单元,The image processing apparatus further includes a determining unit,
    所述确定单元,用于将所述计算单元计算出的所述第t-i个图像帧的目标参数作为所述待处理图像帧的目标参数的统计值。The determining unit is configured to use a target parameter of the t-ith image frame calculated by the calculating unit as a statistical value of a target parameter of the image frame to be processed.
  15. 根据权利要求10-14中任意一项所述的图像处理装置,其特征在于,An image processing apparatus according to any one of claims 10 to 14, wherein
    所述目标参数包括显示内容最大亮度值、显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性亮度缩放量化中的至少一个。The target parameter includes a maximum brightness value of the display content, a maximum image average brightness value of the display content, a maximum value of the nonlinear brightness component of the display content, a minimum value of the nonlinear brightness component of the display content, an average value of the nonlinear brightness component of the display content, and a nonlinear display content. At least one of a luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear luminance scaling quantization.
  16. 一种图像处理装置,其特征在于,包括:An image processing apparatus, comprising:
    获取单元,用于获取显示设备的显示参数,以及用于从码流中获取目标参数,所述目标参数用于表征所述码流中的所有图像帧的显示内容性能指标;An obtaining unit, configured to acquire display parameters of the display device, and configured to acquire target parameters from the code stream, where the target parameters are used to represent display content performance indicators of all image frames in the code stream;
    计算单元,用于根据所述获取单元获取到的所述显示参数和所述目标参数,计算调整系数;a calculating unit, configured to calculate an adjustment coefficient according to the display parameter and the target parameter acquired by the acquiring unit;
    更新单元,用于根据所述计算单元计算出的所述调整系数,更新所述获取单元获取到的所述目标参数;And an updating unit, configured to update the target parameter acquired by the acquiring unit according to the adjustment coefficient calculated by the calculating unit;
    发送单元,用于向所述显示设备发送所述更新单元得到的更新后的目标参数,以使得所述显示设备根据所述更新后的目标参数调整图像帧的动态范围和色彩。And a sending unit, configured to send, to the display device, the updated target parameter obtained by the updating unit, so that the display device adjusts a dynamic range and a color of the image frame according to the updated target parameter.
  17. 根据权利要求16所述的图像处理装置,其特征在于,所述显示参数包括所述显示设备的最大显示亮度值,所述目标参数包括显示内容最大亮度值,所述调整系数包括线性域调整系数和非线性域调整系数,The image processing device according to claim 16, wherein the display parameter comprises a maximum display brightness value of the display device, the target parameter comprises a display content maximum brightness value, and the adjustment coefficient comprises a linear domain adjustment coefficient. And nonlinear domain adjustment coefficients,
    所述计算单元具体用于:The calculating unit is specifically configured to:
    根据所述显示内容最大亮度值和所述显示设备的最大显示亮度值,采用下述公式计算所述线性域调整系数:And calculating the linear domain adjustment coefficient according to the maximum brightness value of the display content and the maximum display brightness value of the display device by using the following formula:
    linear_adjust_factorLinear_adjust_factor
    =min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)=min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)
    其中,linear_adjust_factor为所述线性域调整系数,Max_Display_Target_Luminance为所述显示设备的最大显示亮度值,Max_Content_Light_Level为所述显示内容最大亮度值,min(1.0,Max_Display_Target_Luminance/Max_Content_Light_Level)表示取1.0和Max_Display_Target_Luminance/Max_Content_Light_Level的最小值;The linear_adjust_factor is the linear domain adjustment coefficient, Max_Display_Target_Luminance is the maximum display brightness value of the display device, Max_Content_Light_Level is the maximum brightness value of the display content, and min(1.0, Max_Display_Target_Luminance/Max_Content_Light_Level) indicates the minimum of 1.0 and Max_Display_Target_Luminance/Max_Content_Light_Level. value;
    根据所述显示内容最大亮度值和所述显示设备的最大显示亮度值,采用下述公式计算所述非线性域调整系数:And calculating the nonlinear domain adjustment coefficient according to the maximum brightness value of the display content and the maximum display brightness value of the display device by using the following formula:
    Figure PCTCN2017099365-appb-100004
    Figure PCTCN2017099365-appb-100004
    其中,nonlinear_adjust_factor为所述非线性域调整系数,OETF(·)表示光电转换函数。Wherein, the nonlinear_adjust_factor is the nonlinear domain adjustment coefficient, and the OETF (·) represents the photoelectric conversion function.
  18. 根据权利要求17所述的图像处理装置,其特征在于,所述目标参数还包括、显示内容最大图像平均亮度值、显示内容非线性亮度分量最大值、显示内容非线性亮度分量最小值、显示内容非线性亮度分量平均值、显示内容非线性亮度分量标准方差值、显示内容非线性亮度缩放量化、显示内容非线性亮度伽马值以及显示内容非线性亮度缩放量化中的至少一个;The image processing device according to claim 17, wherein the target parameter further comprises: a display content maximum image average brightness value, a display content nonlinear brightness component maximum value, a display content nonlinear brightness component minimum value, and display content At least one of a nonlinear luminance component average value, a display content nonlinear luminance component standard variance value, a display content nonlinear luminance scaling quantization, a display content nonlinear luminance gamma value, and a display content nonlinear luminance scaling quantization;
    所述更新单元具体用于:The update unit is specifically configured to:
    将所述线性域调整系数与所述显示内容最大亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大亮度值;And multiplying the linear domain adjustment coefficient by the maximum brightness value of the display content, and quantizing to an unsigned integer, to obtain an updated maximum brightness value of the display content;
    当所述目标参数包括所述显示内容最大图像平均亮度值时,将所述线性域调整系数与所述显示内容最大图像平均亮度值相乘,并量化为无符号整数,得到更新后的显示内容最大图像平均亮度值;And when the target parameter includes the maximum image average brightness value of the display content, multiplying the linear domain adjustment coefficient by the maximum image average brightness value of the display content, and quantizing into an unsigned integer to obtain an updated display content. Maximum image average brightness value;
    当所述目标参数包括所述显示内容非线性亮度分量最大值时,将所述非线性域调整系数与所述显示内容非线性亮度分量最大值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量最大值;When the target parameter includes the display content non-linear luminance component maximum value, the nonlinear domain adjustment coefficient is multiplied by the display content nonlinear luminance component maximum value, and quantized into an unsigned integer, and obtained after updating The display content has a maximum nonlinear luminance component;
    当所述目标参数包括所述显示内容非线性亮度分量最小值时,将所述非线性域调整系数与所述显示内容非线性亮度分量最小值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量最小值;When the target parameter includes the display content non-linear luminance component minimum value, the nonlinear domain adjustment coefficient is multiplied by the display content nonlinear luminance component minimum value, and quantized into an unsigned integer, and obtained after updating The display content is the minimum value of the nonlinear luminance component;
    当所述目标参数包括所述显示内容非线性亮度分量平均值时,将所述非线性域调整系数与所述显示内容非线性亮度分量平均值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量平均值;When the target parameter includes the display content non-linear luminance component average value, the nonlinear domain adjustment coefficient is multiplied by the display content nonlinear luminance component average value, and quantized into an unsigned integer, and obtained after updating The display content is the average of the nonlinear luminance components;
    当所述目标参数包括所述显示内容非线性亮度分量标准方差值时,将所述非线性域调整系数与所述显示内容非线性亮度分量标准方差值相乘,并量化为无符号整数,得到更新后的显示内容非线性亮度分量标准方差值;When the target parameter includes the display content nonlinear luminance component standard variance value, multiplying the nonlinear domain adjustment coefficient by the display content nonlinear luminance component standard variance value, and quantizing to an unsigned integer Obtaining a standard deviation value of the non-linear luminance component of the updated display content;
    当所述目标参数包括所述显示内容非线性亮度缩放量化时,将所述显示内容非线性亮度缩放量化的数值设置为第一预设阈值;When the target parameter includes the display content nonlinear brightness scaling quantization, setting the numerical value of the display content nonlinear brightness scaling quantization to a first preset threshold;
    当所述目标参数包括所述显示内容非线性色度缩放量化时,将所述显示内容非线性色度缩放量化的数值设置为第二预设阈值;When the target parameter includes the display content nonlinear chrominance scaling quantization, setting the numerical value of the display content nonlinear chrominance scaling quantization to a second preset threshold;
    当所述目标参数包括所述显示内容非线性亮度伽马值时,将所述显示内容非线性亮度伽马值的数值设置为第三预设阈值。When the target parameter includes the display content non-linear luminance gamma value, the value of the display content non-linear luminance gamma value is set to a third preset threshold.
  19. 一种图像处理装置,其特征在于,所述图像处理装置包括:一个或多个处理器、存储器、通信接口;An image processing apparatus, comprising: one or more processors, a memory, and a communication interface;
    所述存储器、所述通信接口与所述一个或多个处理器耦合;所述图像处理装置通过所述通信接口与其他设备通信;所述存储器用于存储计算机程序代码,所述计算机程序代码包括指令;当所述一个或多个处理器执行所述指令时,所述图像处理装置执行如权利要求1-6中任意一项所述的图像处理方法或者执行如权利要求7-9中任意一项所述的图像处理方法。The memory, the communication interface is coupled to the one or more processors; the image processing device is in communication with other devices via the communication interface; the memory is for storing computer program code, the computer program code comprising The image processing apparatus performs the image processing method according to any one of claims 1 to 6 or performs any one of claims 7-9 when the one or more processors execute the instructions. The image processing method described in the item.
  20. 一种计算机存储介质,所述计算机存储介质中存储有指令,其特征在于,当 所述指令在图像处理装置上运行时,使得所述图像处理装置执行如权利要求1-6中任意一项所述的图像处理方法或者执行如权利要求7-9中任意一项所述的图像处理方法。A computer storage medium storing instructions in the computer storage medium, characterized in that The image processing device, when executed on an image processing device, causes the image processing device to perform the image processing method according to any one of claims 1 to 6 or to perform the image according to any one of claims 7-9 Approach.
  21. 一种包含指令的计算机程序产品,其特征在于,当所述计算机程序产品在图像处理装置上运行时,使得所述图像处理装置执行如权利要求1-6中任意一项所述的图像处理方法或者执行如权利要求7-9中任意一项所述的图像处理方法。 A computer program product comprising instructions, wherein when the computer program product is run on an image processing device, the image processing device is caused to perform the image processing method according to any one of claims 1-6 Or the image processing method according to any one of claims 7-9.
PCT/CN2017/099365 2017-08-28 2017-08-28 Image processing method and apparatus WO2019041112A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2017/099365 WO2019041112A1 (en) 2017-08-28 2017-08-28 Image processing method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2017/099365 WO2019041112A1 (en) 2017-08-28 2017-08-28 Image processing method and apparatus

Publications (1)

Publication Number Publication Date
WO2019041112A1 true WO2019041112A1 (en) 2019-03-07

Family

ID=65524743

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/099365 WO2019041112A1 (en) 2017-08-28 2017-08-28 Image processing method and apparatus

Country Status (1)

Country Link
WO (1) WO2019041112A1 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103180891A (en) * 2010-07-22 2013-06-26 杜比实验室特许公司 Display management server
US20150254823A1 (en) * 2011-04-08 2015-09-10 Dolby Laboratories Licensing Corporation Image Range Expansion Control Methods And Apparatus
CN106504278A (en) * 2015-09-04 2017-03-15 迪士尼企业公司 HDR tone maps

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103180891A (en) * 2010-07-22 2013-06-26 杜比实验室特许公司 Display management server
US20150254823A1 (en) * 2011-04-08 2015-09-10 Dolby Laboratories Licensing Corporation Image Range Expansion Control Methods And Apparatus
CN106504278A (en) * 2015-09-04 2017-03-15 迪士尼企业公司 HDR tone maps

Similar Documents

Publication Publication Date Title
TWI696146B (en) Method and apparatus of image processing, computer reading storage medium and mobile terminal
CN107038715B (en) Image processing method and device
CN113132696B (en) Image tone mapping method, image tone mapping device, electronic equipment and storage medium
WO2023016320A1 (en) Image processing method and apparatus, and device and medium
CN108804184B (en) Display control method and terminal equipment
WO2022087973A1 (en) Image processing method and apparatus, computer-readable medium, and electronic device
CN108040240B (en) White balance adjustment method and device and mobile terminal
WO2023098251A1 (en) Image processing method, device, and readable storage medium
WO2020134789A1 (en) Mobile terminal and method for controlling on and off of screen, and computer storage medium
KR20230003066A (en) Dynamic range mapping method and apparatus
TW200842694A (en) Method for dynamically adjusting brightness of image
WO2019091196A1 (en) Image processing method and apparatus
WO2022111717A1 (en) Image processing method and apparatus, and electronic device
WO2024067461A1 (en) Image processing method and apparatus, and computer device and storage medium
TWI415480B (en) Image processing method and image processing system
US20100053381A1 (en) Image processing apparatus and method thereof
Edstrom et al. Luminance-adaptive smart video storage system
WO2019041112A1 (en) Image processing method and apparatus
US20170124963A1 (en) Display adjustment method and electronic device thereof
CN109544441B (en) Image processing method and device, and skin color processing method and device in live broadcast
CN107734386B (en) MIPI (Mobile industry processor interface) protocol-based video image reduction method and system
CN108053453B (en) Color optimization method, terminal and computer-readable storage medium
WO2022179600A1 (en) Video coding method and apparatus, video decoding method and apparatus, and electronic device
WO2023077981A1 (en) Display parameter adjusting method and apparatus, storage medium, and display device
US11388348B2 (en) Systems and methods for dynamic range compression in multi-frame 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: 17923138

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17923138

Country of ref document: EP

Kind code of ref document: A1