Image display method, device and terminal equipment
By performing RAW domain processing and tone mapping on the images captured by the camera at the recording end, local and global tone mapping curves are generated, which solves the problem of insufficient brightness and contrast effect at the recording end in the existing technology, and realizes end-to-end adaptation and effect improvement of recording and display.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HUAWEI TECH CO LTD
- Filing Date
- 2022-07-05
- Publication Date
- 2026-07-07
AI Technical Summary
The existing HDR video standard mainly adapts to the display end, but does not design a solution for the recording end, which makes it impossible to guarantee the brightness, contrast and local lighting effects of the video source at the recording end.
By performing RAW domain processing on the raw images captured by the camera at the recording end to generate YUV images, and then performing split processing to obtain the Y component image, face bounding boxes and scene information are detected, local tone mapping curves and contrast enhancement information are generated, and tone mapping processing is performed by combining global and local tone mapping curves to improve brightness and contrast effects, and end-to-end adaptation is performed with the display end.
It improves the brightness and contrast of the video source at the recording end, achieving end-to-end adaptation with the display end and ensuring optimal recording and display effects.
Smart Images

Figure CN117593236B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of smart terminal technology, and in particular to an image display method, apparatus, and terminal device. Background Technology
[0002] With the development of media technology, users have increasingly higher demands for video quality, including higher resolution, higher frame rate, higher bit width, wider color gamut, and / or higher dynamic range. Current research directions for video applications generally include video frame interpolation, video super-resolution, and / or high dynamic range video. Figure 1 This is a comparative illustration of the high dynamic range effect in existing related technologies, such as... Figure 1 As shown, the advantages of high dynamic range (HDR) lie in its higher bit width, higher dynamic range, and / or wider color gamut. There are already many HDR video standards, such as hybrid log-gamma (HLG), high dynamic range 10 (HDR10), HDR10+, and Dolby Vision's proprietary HDR. The China Ultra HD Video Industry Alliance has also launched the HDRvivid video standard, aiming to present rich colors and layers, improve contrast sensitivity, enhance depth and detail, and make the image closer to real-world HDR quality.
[0003] However, existing HDR video standards only define adaptations for the display end, without designing solutions for the recording end. Summary of the Invention
[0004] This application provides an image display method, apparatus, and terminal device. This application also provides a computer-readable storage medium to improve the brightness and contrast of the video source at the recording end and to achieve end-to-end adaptation with the display end, thereby achieving the optimal end-to-end recording and display effect.
[0005] In a first aspect, embodiments of this application provide an image display method, comprising: acquiring an original image of a current shooting scene captured by a camera; performing RAW domain processing on the original image to obtain a YUV image; performing split processing on the YUV image to obtain an image stream and a detection stream; acquiring an image of the Y component from the YUV image of the detection stream; detecting the image of the Y component to obtain face bounding box information and scene information; generating a local tone mapping curve and corresponding contrast enhancement intensity information based on the image of the Y component, the face bounding box information, and the scene information; performing noise reduction and color processing on the YUV image in the image stream, and performing tone mapping processing on the noise-reduced and color-processed YUV image based on the local tone mapping curve and the contrast enhancement intensity information to obtain an image to be processed; acquiring global tone mapping curve information and local tone mapping curve information of metadata; and displaying or encoding the image to be processed based on the global tone mapping curve information and the local tone mapping curve information of metadata.
[0006] In the above image display method, the original image of the current shooting scene captured by the camera is acquired, and the original image is processed in the RAW domain to obtain a YUV image. Then, the YUV image is split into an image stream and a detection stream. The Y component image is obtained from the YUV image of the detection stream, and the Y component image is detected to obtain face bounding box information and scene information. Then, a local tone mapping curve and corresponding contrast enhancement intensity information are generated based on the Y component image, the face bounding box information, and the scene information, effectively improving the brightness and contrast effect of the video source at the recording end. Then, the YUV image in the image stream is downgraded. The process involves noise and color processing, and based on the aforementioned local tone mapping curve and contrast enhancement intensity information, tone mapping processing is performed on the YUV image after noise reduction and color processing to obtain the image to be processed. Finally, the global tone mapping curve information and local tone mapping curve information of the metadata are obtained. Based on the aforementioned global tone mapping curve information and local tone mapping curve information of the metadata, the image to be processed is displayed or encoded. This allows for the use of the global tone mapping curve information and local tone mapping curve information of the metadata to achieve linkage with the display end, resulting in a better end-to-end recording and display effect.
[0007] In one possible implementation, before performing RAW domain processing on the original image to obtain a YUV image, the method further includes: performing 3A statistics on the original image captured by the camera to obtain 3A statistical information of the original image; determining the dynamic range and ambient brightness of the current shooting scene based on the 3A statistical information; after determining that the current shooting scene is a high dynamic range scene based on the dynamic range and ambient brightness, instructing the camera to output the original image in an overlapping image output manner; acquiring at least two frames of original images output by the camera in the overlapping image output manner; fusing the at least two frames of original images to obtain a high dynamic range single-frame original image; performing histogram statistics on the high dynamic range single-frame original image to obtain histogram statistical information; and performing bit-width compression on the high dynamic range single-frame original image based on the histogram statistical information to obtain a compressed original image; the step of performing RAW domain processing on the original image to obtain a YUV image includes: performing RAW domain processing on the compressed original image to obtain a YUV image.
[0008] In one possible implementation, obtaining the global tone mapping curve information of metadata includes: performing global histogram statistics on the image to be processed to obtain global histogram information; performing statistics on pixel distribution information based on the global histogram information to obtain statistical information of metadata; calculating the global tone mapping base curve based on the statistical information of metadata; controlling the filtering parameters of the global tone mapping base curve based on scene switching information; wherein the scene switching information includes scene information obtained by detecting the image of the Y component, and scene information obtained by calculating the image of the Y component; and generating the global tone mapping curve information of metadata using the filtered global tone mapping base curve.
[0009] In one possible implementation, obtaining the local tone mapping curve information of the metadata includes: dividing the image of the Y component into grids; obtaining the local statistical histogram of the image within each grid; updating the local statistical histogram using the filtered global tone mapping base curve; generating the local tone mapping curve of the image within each grid based on the updated local statistical histogram; and filtering the local tone mapping curve in the temporal and spatial domains based on the scene switching information and the spatial adjacency information of the grid to generate the local tone mapping curve information of the metadata.
[0010] In one possible implementation, after determining the dynamic range and ambient brightness of the current shooting scene based on the 3A statistical information, the method further includes: after determining that the current shooting scene is a non-high dynamic range scene based on the dynamic range and ambient brightness, instructing the camera to output the original image in a single-frame output manner to obtain a single-frame original image; performing histogram statistics on the single-frame original image to obtain the histogram information of the single-frame original image, generating a global tone mapping curve based on the histogram information of the single-frame original image; performing RAW domain processing on the single-frame original image to obtain a single-frame YUV image; and performing tone mapping processing on the single-frame YUV image based on the global tone mapping curve to obtain the image to be processed.
[0011] Secondly, embodiments of this application provide an image display device, which is included in a terminal device. This device has the function of implementing the terminal device behaviors described in the first aspect and its possible implementations. The function can be implemented by hardware or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above functions. For example, an acquisition module, a RAW domain processing module, a splitting module, a detection module, a generation module, a noise reduction processing module, a tone mapping module, and a display encoding module, etc.
[0012] Thirdly, embodiments of this application provide a terminal device, including: one or more processors; a memory; multiple applications; and one or more computer programs, wherein the one or more computer programs are stored in the memory, and the one or more computer programs include instructions that, when executed by the terminal device, cause the terminal device to perform the following steps: acquiring a raw image of the current shooting scene captured by a camera; performing RAW domain processing on the raw image to obtain a YUV image; performing split processing on the YUV image to obtain an image stream and a detection stream; acquiring an image of the Y component from the YUV image of the detection stream; and performing detection processing on the image of the Y component. The process involves: measuring and acquiring face bounding box information and scene information; generating a local tone mapping curve and corresponding contrast enhancement intensity information based on the Y component image, the face bounding box information, and the scene information; performing noise reduction and color processing on the YUV image in the image stream; and performing tone mapping processing on the noise-reduced and color-processed YUV image based on the local tone mapping curve and the contrast enhancement intensity information to obtain the image to be processed; acquiring global tone mapping curve information and local tone mapping curve information of metadata; and displaying or encoding the image to be processed based on the global tone mapping curve information and the local tone mapping curve information of metadata.
[0013] In one possible implementation, when the instruction is executed by the terminal device, before the terminal device performs the step of RAW domain processing on the original image to obtain a YUV image, the following steps are also performed: performing 3A statistics on the original image captured by the camera to obtain the 3A statistical information of the original image; determining the dynamic range and ambient brightness of the current shooting scene based on the 3A statistical information; after determining that the current shooting scene is a high dynamic range scene based on the dynamic range and ambient brightness, instructing the camera to output the original image in an overlapping image output manner; obtaining the camera's... The process involves: outputting at least two original images in an overlapping manner; fusing the at least two original images to obtain a high dynamic range single-frame original image; performing histogram statistics on the high dynamic range single-frame original image to obtain histogram statistical information; performing bit-width compression on the high dynamic range single-frame original image based on the histogram statistical information to obtain a compressed original image; and when the instruction is executed by the terminal device, causing the terminal device to perform RAW domain processing on the original image to obtain a YUV image, the process includes: performing RAW domain processing on the compressed original image to obtain a YUV image.
[0014] In one possible implementation, when the instruction is executed by the terminal device, the step of obtaining global tone mapping curve information of metadata by the terminal device includes: performing global histogram statistics on the image to be processed to obtain global histogram information; performing statistics on pixel distribution information based on the global histogram information to obtain statistical information of metadata; calculating a global tone mapping base curve based on the statistical information of metadata; controlling the filtering parameters of the global tone mapping base curve based on scene switching information; wherein the scene switching information includes scene information obtained by detecting the image of the Y component and scene information obtained by calculating the image of the Y component; and generating global tone mapping curve information of metadata using the filtered global tone mapping base curve.
[0015] In one possible implementation, when the instruction is executed by the terminal device, the step of obtaining the local tone mapping curve information of the metadata by the terminal device includes: dividing the image of the Y component into grids; obtaining the local statistical histogram of the image in each grid; updating the local statistical histogram using the filtered global tone mapping base curve; generating the local tone mapping curve of the image in each grid based on the updated local statistical histogram; and filtering the local tone mapping curve in the temporal and spatial domains based on the scene switching information and the spatial adjacency information of the grid to generate the local tone mapping curve information of the metadata.
[0016] In one possible implementation, when the instruction is executed by the terminal device, after the terminal device performs the step of determining the dynamic range and ambient brightness of the current shooting scene based on the 3A statistical information, it further performs the following steps: after determining that the current shooting scene is a non-high dynamic range scene based on the dynamic range and ambient brightness, it instructs the camera to output the original image in a single-frame output manner to obtain a single-frame original image; it performs histogram statistics on the single-frame original image to obtain the histogram information of the single-frame original image, and generates a global tone mapping curve based on the histogram information of the single-frame original image; it performs RAW domain processing on the single-frame original image to obtain a single-frame YUV image; and it performs tone mapping processing on the single-frame YUV image based on the global tone mapping curve to obtain the image to be processed.
[0017] It should be understood that the third aspect of the embodiments of this application is consistent with the technical solution of the first aspect of the embodiments of this application, and the beneficial effects achieved by each aspect and the corresponding feasible implementation are similar, and will not be described again.
[0018] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when run on a computer, causes the computer to perform the method provided in the first aspect.
[0019] Fifthly, embodiments of this application provide a computer program that, when executed by a computer, performs the method provided in the first aspect.
[0020] In one possible design, the program in the fifth aspect can be stored wholly or partially on a storage medium packaged with the processor, or it can be stored wholly or partially on a memory not packaged with the processor. Attached Figure Description
[0021] Figure 1 This is a comparative diagram of the high dynamic range effect in existing related technologies;
[0022] Figure 2 This is a schematic diagram of various DOL frame output methods provided in existing related technologies;
[0023] Figure 3 An HDR encoding / decoding workflow is provided for existing related technologies;
[0024] Figure 4 This is a schematic diagram of the structure of a terminal device provided in one embodiment of this application;
[0025] Figure 5 A schematic diagram of the framework of an image display method provided in one embodiment of this application;
[0026] Figure 6 A flowchart illustrating an image display method according to an embodiment of this application;
[0027] Figure 7(a) is a schematic diagram of the recording terminal IPE and metadata generation module provided in an embodiment of this application;
[0028] Figure 7(b) is a flowchart of an algorithm for obtaining an image to be processed according to an embodiment of this application;
[0029] Figure 8 A flowchart illustrating an image display method provided in another embodiment of this application;
[0030] Figure 9 This application provides an embodiment of the IFE processing flow for HDR vivid in high dynamic range scenes;
[0031] Figure 10 A flowchart illustrating an image display method provided in yet another embodiment of this application;
[0032] Figure 11 A flowchart illustrating an image display method provided in yet another embodiment of this application;
[0033] Figure 12 A flowchart illustrating the processing of the RAW domain in a non-high dynamic range scenario provided in one embodiment of this application;
[0034] Figure 13 This is a schematic diagram of the structure of a terminal device provided in another embodiment of this application;
[0035] Figure 14 This is a schematic diagram of the structure of a terminal device provided in another embodiment of this application. Detailed Implementation
[0036] The terminology used in the implementation section of this application is for the purpose of explaining specific embodiments of this application only, and is not intended to limit this application.
[0037] One existing HDR solution uses a stagger high dynamic range (sHDR) multi-frame fusion scheme to enhance dynamic range as a recording capability, and then combines this with the HDR playback capability provided by dolbyvision to achieve an end-to-end HDR effect.
[0038] This solution utilizes HDR multi-frame fusion for video recording and employs Doppler Array (DOL) frame output in mobile devices, forming an overall sHDR video HDR recording solution. The specific DOL frame output method is as follows... Figure 2 As shown, Figure 2This diagram illustrates various DOL (Distance-Oriented Frame Output) methods provided in existing related technologies. Currently, devices generally support these three DOL methods, specifically the overlapping exposure method of long and short frames. Specifically, Non-overlapping DOL (NDOL) allows no overlap in the read data times of adjacent frames within the same time sequence (long, medium, and short frames); Traditional DOL (traditional DOL) allows no overlap in read data times between frames from different time sequences; and Full Overlap DOL (full overlap DOL) allows no overlap in the read data times of the first video frame output in adjacent time sequences. In other words, sHDR allows overlapping output for the same time sequence, but the degree of overlap varies under different configurations. Video frame data with different exposures obtained from the overlapping output are fed into an algorithm for long-short frame fusion. The fusion algorithm strategy mainly includes registration and ghost detection between long and short frames to determine the fusion weights and obtain the fused result. The above method is used to achieve HDR effects on the recording end.
[0039] Its encoding / decoding and display utilize Dolby's HDR standard to achieve end-to-end HDR recording and display effects. By setting the overall front-end path to 10-bit and 2020 color gamut, and using a hybrid log gamma (HLG) gamma curve, it sends the signal to a Dolby-supported display for HDR effects, achieving end-to-end HDR capability. One method Dolby uses to implement HDR display is as follows... Figure 3 As shown, Figure 3 This provides an HDR encoding / decoding workflow for existing related technologies.
[0040] However, the above HDR scheme does not consider the recording scheme of contrast and lighting effects in the image signal processor (ISP) system; the above scheme complies with Dolby's standard, and although it uses dynamic metadata in the metadata, the metadata used only includes global metadata and does not include local metadata, so it cannot guarantee local lighting effects and contrast.
[0041] Another HDR solution offered by existing technologies is the HDR10 standard. HDR10 is an open standard proposed in 2015 by the Consumer Technology Association (CTA). It primarily designs an end-to-end HDR standard, defining the transform curve as an ST 2084 curve, maintaining the BT.2020 color gamut, and having a 10-bit bit width. The corresponding end-to-end solution is relatively simple, and the corresponding metadata only supports static metadata.
[0042] This solution only uses static metadata, which cannot guarantee that the effect of each frame of video will achieve the goal of optimal adaptation to the display device.
[0043] Another HDR solution offered by existing technologies is the HLG standard. The HLG standard was designed for live television services, directly using the HLG curve, with an end-to-end 10-bit width and no metadata information. Its main feature is compatibility with standard dynamic range (SDR) display devices.
[0044] However, this approach lacks metadata information, cannot adapt the effects to the display capabilities, and does not consider improvements to the recording capabilities.
[0045] Based on the above problems, this application provides an image display method. This method provides a recording end algorithm scheme for the HDRvivid video standard, which effectively improves the brightness and contrast effect of the video source at the recording end, and performs end-to-end adaptation with the display end, thereby achieving a better end-to-end recording and display effect.
[0046] The image display method provided in this application embodiment can be applied to terminal devices, wherein the terminal devices can be smartphones, tablets, wearable devices, in-vehicle devices, augmented reality (AR) / virtual reality (VR) devices, laptops, ultra-mobile personal computers (UMPCs), netbooks, or personal digital assistants (PDAs), etc.; this application embodiment does not impose any restrictions on the specific type of terminal device.
[0047] For example, Figure 4 This is a schematic diagram of the structure of a terminal device provided in one embodiment of this application, as shown below. Figure 4As shown, the terminal device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, buttons 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.
[0048] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the terminal device 100. In other embodiments of this application, the terminal device 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0049] Processor 110 may include one or more processing units, such as application processors (APs), modem processors, graphics processing units (GPUs), image signal processors (ISPs), controllers, video codecs, digital signal processors (DSPs), baseband processors, and / or neural network processing units (NPUs). These different processing units may be independent devices or integrated into one or more processors.
[0050] The controller can generate operation control signals based on the instruction opcode and timing signals to complete the control of instruction fetching and execution.
[0051] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
[0052] In some embodiments, the processor 110 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0053] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (DCL). In some embodiments, the processor 110 may include multiple I2C buses. The processor 110 can couple to the touch sensor 180K, charger, flash, camera 193, etc., through different I2C bus interfaces. For example, the processor 110 can couple to the touch sensor 180K through the I2C interface, enabling the processor 110 and the touch sensor 180K to communicate through the I2C bus interface, thereby realizing the touch function of the terminal device 100.
[0054] The I2S interface can be used for audio communication. In some embodiments, the processor 110 may include multiple I2S buses. The processor 110 can be coupled to the audio module 170 via the I2S bus to enable communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 via the I2S interface to enable the function of answering phone calls through a Bluetooth headset.
[0055] The PCM interface can also be used for audio communication, sampling, quantizing, and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 can be coupled via the PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 via the PCM interface, enabling the function of answering phone calls through a Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.
[0056] The UART interface is a universal serial data bus used for asynchronous communication. This bus can be a bidirectional communication bus. It converts the data to be transmitted between serial and parallel communication. In some embodiments, the UART interface is typically used to connect the processor 110 and the wireless communication module 160. For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 via the UART interface to implement Bluetooth functionality. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 via the UART interface to enable music playback through Bluetooth headphones.
[0057] The MIPI interface can be used to connect the processor 110 to peripheral devices such as the display screen 194 and the camera 193. The MIPI interface includes a camera serial interface (CSI) and a display serial interface (DSI). In some embodiments, the processor 110 and the camera 193 communicate via the CSI interface to enable the shooting function of the terminal device 100. The processor 110 and the display screen 194 communicate via the DSI interface to enable the display function of the terminal device 100.
[0058] The GPIO interface can be configured via software. It can be configured as a control signal or a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 to a camera 193, a display screen 194, a wireless communication module 160, an audio module 170, a sensor module 180, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.
[0059] USB port 130 is a USB standard compliant interface, specifically a Mini USB port, Micro USB port, or USB Type-C port. USB port 130 can be used to connect a charger to charge terminal device 100, and can also be used for data transfer between terminal device 100 and peripheral devices. It can also be used to connect headphones for audio playback. This interface can also be used to connect other electronic devices, such as AR devices.
[0060] It is understood that the interface connection relationships between the modules illustrated in the embodiments of this application are merely illustrative and do not constitute a structural limitation on the terminal device 100. In other embodiments of this application, the terminal device 100 may also adopt different interface connection methods or a combination of multiple interface connection methods as described in the above embodiments.
[0061] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of the terminal device 100. While charging the battery 142, the charging management module 140 can also supply power to the terminal device 100 via the power management module 141.
[0062] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, display screen 194, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.
[0063] The wireless communication function of the terminal device 100 can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor, etc.
[0064] Antennas 1 and 2 are used to transmit and receive electromagnetic wave signals. Each antenna in terminal device 100 can be used to cover one or more communication frequency bands. Different antennas can also be multiplexed to improve antenna utilization. For example, antenna 1 can be multiplexed as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with a tuning switch.
[0065] The mobile communication module 150 can provide solutions for wireless communication, including 2G / 3G / 4G / 5G, applied to the terminal device 100. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves via antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to a modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via antenna 1. In some embodiments, at least some functional modules of the mobile communication module 150 may be housed in the processor 110. In some embodiments, at least some functional modules of the mobile communication module 150 and at least some modules of the processor 110 may be housed in the same device.
[0066] The modem processor may include a modulator and a demodulator. The modulator modulates the low-frequency baseband signal to be transmitted into a mid-to-high frequency signal. The demodulator demodulates the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After processing by the baseband processor, the low-frequency baseband signal is transmitted to the application processor. The application processor outputs sound signals through an audio device (not limited to speaker 170A, receiver 170B, etc.) or displays images or videos through the display screen 194. In some embodiments, the modem processor may be a separate device. In other embodiments, the modem processor may be independent of the processor 110 and may be housed in the same device as the mobile communication module 150 or other functional modules.
[0067] The wireless communication module 160 can provide solutions for wireless communication applications on the terminal device 100, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via antenna 2, performs frequency modulation and filtering of the electromagnetic wave signals, and sends the processed signal to processor 110. The wireless communication module 160 can also receive signals to be transmitted from processor 110, perform frequency modulation and amplification, and convert them into electromagnetic waves for radiation via antenna 2.
[0068] In some embodiments, antenna 1 of terminal device 100 is coupled to mobile communication module 150, and antenna 2 is coupled to wireless communication module 160, enabling terminal device 100 to communicate with networks and other devices via wireless communication technology. The wireless communication technology may include Global System for Mobile Communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technologies, etc. The GNSS may include the Global Positioning System (GPS), the Global Navigation Satellite System (GLONASS), the BeiDou Navigation Satellite System (BDS), the Quasi-Zenith Satellite System (QZSS), and / or satellite-based augmentation systems (SBAS).
[0069] Terminal device 100 implements display functions through a GPU, display screen 194, and application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. Processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.
[0070] Display screen 194 is used to display images, videos, etc. Display screen 194 includes a display panel. The display panel may be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a miniature LED, a microLED, a quantum dot light-emitting diode (QLED), etc. In some embodiments, terminal device 100 may include one or N displays 194, where N is a positive integer greater than 1.
[0071] Terminal device 100 can perform shooting functions through ISP, camera 193, video codec, GPU, display 194 and application processor.
[0072] The ISP (Image Signal Processor) is used to process data fed back from the camera 193. For example, when taking a picture, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, and the camera's photosensitive element transmits the electrical signal to the ISP for processing, transforming it into an image visible to the naked eye. The ISP can also perform algorithmic optimization of image noise, brightness, and skin tone. The ISP can also optimize parameters such as exposure and color temperature of the shooting scene. In some embodiments, the ISP can be set in the camera 193.
[0073] Camera 193 is used to capture still images or videos. An object is projected onto a photosensitive element by generating an optical image through the lens. The photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then passed to an ISP for conversion into a digital image signal. The ISP outputs the digital image signal to a DSP for processing. The DSP converts the digital image signal into image signals in standard RGB, YUV, or other formats. In some embodiments, the terminal device 100 may include one or N cameras 193, where N is a positive integer greater than 1.
[0074] A digital signal processor (DSP) is used to process digital signals. Besides digital image signals, it can also process other digital signals. For example, when terminal device 100 selects a frequency, the DSP can perform Fourier transforms on the frequency energy.
[0075] Video codecs are used to compress or decompress digital video. Terminal device 100 may support one or more video codecs. Thus, terminal device 100 can play or record videos in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG 2, MPEG 3, MPEG 4, etc.
[0076] NPU stands for Neural Network (NN) Computing Processor. By borrowing the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, it can rapidly process input information and continuously learn on its own. NPUs enable intelligent cognitive applications in terminal devices, such as image recognition, facial recognition, speech recognition, and text understanding.
[0077] The external storage interface 120 can be used to connect an external storage card, such as a Micro SD card, to expand the storage capacity of the terminal device 100. The external storage card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external storage card.
[0078] Internal memory 121 can be used to store computer executable program code, which includes instructions. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of terminal device 100 (such as audio data, phonebook, etc.). Furthermore, internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc. Processor 110 executes various functional applications and data processing of terminal device 100 by running instructions stored in internal memory 121 and / or instructions stored in memory located in the processor.
[0079] Terminal device 100 can implement audio functions, such as music playback and recording, through audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor.
[0080] The audio module 170 is used to convert digital audio information into analog audio signals for output, and also to convert analog audio input into digital audio signals. The audio module 170 can also be used for encoding and decoding audio signals. In some embodiments, the audio module 170 may be located in the processor 110, or some functional modules of the audio module 170 may be located in the processor 110.
[0081] The speaker 170A, also known as a "loudspeaker," is used to convert audio electrical signals into sound signals. The terminal device 100 can listen to music or make hands-free calls through the speaker 170A.
[0082] The receiver 170B, also known as the "earpiece," is used to convert audio electrical signals into sound signals. When the terminal device 100 answers a phone call or voice message, the receiver 170B can be brought close to the listener's ear to hear the voice.
[0083] Microphone 170C, also known as a "microphone" or "voice transducer," is used to convert sound signals into electrical signals. When making a phone call or sending a voice message, the user can speak by bringing their mouth close to microphone 170C, inputting the sound signal into microphone 170C. Terminal device 100 may be equipped with at least one microphone 170C. In some embodiments, terminal device 100 may be equipped with two microphones 170C, which, in addition to collecting sound signals, can also perform noise reduction. In other embodiments, terminal device 100 may be equipped with three, four, or more microphones 170C, which can collect sound signals, reduce noise, identify the sound source, and perform directional recording, etc.
[0084] The 170D headphone jack is used to connect wired headphones. The 170D headphone jack can be a USB 130 interface or a 3.5mm Open Mobile Terminal Platform (OMTP) standard interface, a CTIA (Cellular Telecommunications Industry Association of the USA) standard interface.
[0085] Pressure sensor 180A is used to sense pressure signals and convert them into electrical signals. In some embodiments, pressure sensor 180A can be disposed on display screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, and capacitive pressure sensors. A capacitive pressure sensor may include at least two parallel plates with conductive material. When force is applied to pressure sensor 180A, the capacitance between the electrodes changes. Terminal device 100 determines the pressure intensity based on the change in capacitance. When a touch operation is applied to display screen 194, terminal device 100 detects the intensity of the touch operation based on pressure sensor 180A. Terminal device 100 can also calculate the touch position based on the detection signal from pressure sensor 180A. In some embodiments, touch operations applied to the same touch position but with different touch operation intensities can correspond to different operation commands. For example: when a touch operation with an intensity less than a first pressure threshold is applied to the SMS application icon, a command to view an SMS is executed. When a touch operation with an intensity greater than or equal to the first pressure threshold is applied to the SMS application icon, a command to create a new SMS is executed.
[0086] The gyroscope sensor 180B can be used to determine the motion attitude of the terminal device 100. In some embodiments, the gyroscope sensor 180B can determine the angular velocity of the terminal device 100 around three axes (i.e., the x, y, and z axes). The gyroscope sensor 180B can be used for image stabilization. For example, when the shutter is pressed, the gyroscope sensor 180B detects the angle of the terminal device 100's shake, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to counteract the shake of the terminal device 100 through reverse movement, thus achieving image stabilization. The gyroscope sensor 180B can also be used in navigation and motion-sensing game scenarios.
[0087] The barometric pressure sensor 180C is used to measure air pressure. In some embodiments, the terminal device 100 calculates altitude using the air pressure value measured by the barometric pressure sensor 180C to assist in positioning and navigation.
[0088] The magnetic sensor 180D includes a Hall sensor. The terminal device 100 can use the magnetic sensor 180D to detect the opening and closing of the flip cover. In some embodiments, when the terminal device 100 is a flip phone, the terminal device 100 can detect the opening and closing of the flip cover using the magnetic sensor 180D. Then, based on the detected opening and closing state of the cover or the flip cover, features such as automatic flip unlocking can be set.
[0089] The 180E accelerometer can detect the magnitude of acceleration in various directions (typically three axes) of the terminal device 100. When the terminal device 100 is stationary, it can detect the magnitude and direction of gravity. It can also be used to identify the posture of electronic devices and applied to applications such as screen orientation switching and pedometers.
[0090] A distance sensor 180F is used to measure distance. The terminal device 100 can measure distance via infrared or laser. In some embodiments, during a shooting scene, the terminal device 100 can utilize the distance sensor 180F to measure distance for rapid focusing.
[0091] The proximity sensor 180G may include, for example, a light-emitting diode (LED) and a light detector, such as a photodiode. The LED may be an infrared LED. The terminal device 100 emits infrared light outward through the LED. The terminal device 100 uses the photodiode to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the terminal device 100. When insufficient reflected light is detected, the terminal device 100 can determine that there is no object near the terminal device 100. The terminal device 100 may use the proximity sensor 180G to detect when a user holds the terminal device 100 close to their ear for a call, so as to automatically turn off the screen to save power. The proximity sensor 180G can also be used in holster mode and pocket mode for automatic unlocking and screen locking.
[0092] The ambient light sensor 180L is used to sense the ambient light intensity. The terminal device 100 can adaptively adjust the brightness of the display screen 194 based on the sensed ambient light intensity. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also work with the proximity sensor 180G to detect whether the terminal device 100 is in a pocket to prevent accidental touches.
[0093] The fingerprint sensor 180H is used to collect fingerprints. The terminal device 100 can use the collected fingerprint characteristics to achieve fingerprint unlocking, accessing application locks, taking photos with fingerprints, answering calls with fingerprints, etc.
[0094] Temperature sensor 180J is used to detect temperature. In some embodiments, terminal device 100 uses the temperature detected by temperature sensor 180J to execute a temperature handling strategy. For example, when the temperature reported by temperature sensor 180J exceeds a threshold, terminal device 100 reduces the performance of the processor located near temperature sensor 180J to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is below another threshold, terminal device 100 heats battery 142 to prevent abnormal shutdown of terminal device 100 due to low temperature. In still other embodiments, when the temperature is below yet another threshold, terminal device 100 boosts the output voltage of battery 142 to prevent abnormal shutdown due to low temperature.
[0095] Touch sensor 180K, also known as a "touch device," can be located on display screen 194. The touch sensor 180K and display screen 194 together form a touchscreen, also known as a "touchscreen." Touch sensor 180K detects touch operations applied to or near it. The touch sensor can transmit the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through display screen 194. In other embodiments, touch sensor 180K may also be located on the surface of terminal device 100, in a different position than display screen 194.
[0096] The bone conduction sensor 180M can acquire vibration signals. In some embodiments, the bone conduction sensor 180M can acquire vibration signals from the vibrating bone segments of the human vocal cords. The bone conduction sensor 180M can also contact the human pulse to receive blood pressure signals. In some embodiments, the bone conduction sensor 180M can also be incorporated into headphones to form bone conduction headphones. The audio module 170 can parse the voice signals based on the vibration signals from the vibrating bone segments of the vocal cords acquired by the bone conduction sensor 180M to realize voice functionality. The application processor can parse heart rate information based on the blood pressure signals acquired by the bone conduction sensor 180M to realize heart rate detection functionality.
[0097] Buttons 190 include a power button, volume buttons, etc. Buttons 190 can be mechanical buttons or touch-sensitive buttons. Terminal device 100 can receive button input and generate key signal inputs related to user settings and function control of terminal device 100.
[0098] Motor 191 can generate vibration alerts. Motor 191 can be used for incoming call vibration alerts or for touch vibration feedback. For example, different vibration feedback effects can be corresponding to touch operations applied to different applications (such as taking photos, playing audio, etc.). Motor 191 can also correspond to different vibration feedback effects for touch operations applied to different areas of the display screen 194. Different application scenarios (such as time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also be customized.
[0099] Indicator 192 can be an indicator light, used to indicate charging status, power changes, or to indicate messages, missed calls, notifications, etc.
[0100] The SIM card interface 195 is used to connect a SIM card. The SIM card can be inserted into or removed from the SIM card interface 195 to make contact with and separate from the terminal device 100. The terminal device 100 can support one or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, etc. Multiple cards can be inserted into the same SIM card interface 195 simultaneously. The multiple cards can be of the same or different types. The SIM card interface 195 is also compatible with different types of SIM cards. The SIM card interface 195 is also compatible with external memory cards. The terminal device 100 interacts with the network through the SIM card to realize functions such as calls and data communication. In some embodiments, the terminal device 100 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the terminal device 100 and cannot be separated from the terminal device 100.
[0101] For ease of understanding, the following embodiments of this application will be described using the following methods: Figure 4 Taking the terminal device with the structure shown as an example, and in conjunction with the accompanying drawings and application scenarios, the image display method provided in this application embodiment will be specifically described.
[0102] Figure 5 This is a schematic diagram illustrating the framework of an image display method provided in one embodiment of this application. Figure 5 The diagram illustrates the optical device image output module. After image output, different preprocessing modules are used to differentiate between high dynamic range (HMR) and non-HMR images. The ISP internal front-end processing module (IFE), the ISP internal processing module (IPE), and the metadata generation module send the generated metadata to the preview stream and the recording stream, respectively. The preview stream interacts directly with the display through the graphics layer, while the recording stream interacts directly with the display through the codec. After receiving the metadata, the display uses the global tone mapping (GTM) and local tone mapping information in the metadata, along with the actual brightness of the display screen, to perform brightness fitting and obtain the tone mapping curve for the corresponding screen brightness, thereby achieving an end-to-end matching display effect.
[0103] Figure 6 A flowchart illustrating an image display method provided in one embodiment of this application is shown below. Figure 6 As shown, the method for displaying the above image may include:
[0104] Step 601: Obtain the original image of the current shooting scene captured by the camera.
[0105] Specifically, the original image of the current shooting scene captured by the camera can be Figure 5 The image output by the sensor output module 51.
[0106] Step 602: Perform RAW domain processing on the original image to obtain a YUV image.
[0107] Step 603: Perform split processing on the above YUV image to obtain an image stream and a detection stream.
[0108] Specifically, it is possible to Figure 5 The IFE module 52 shown performs split processing on the YUV image to obtain an image stream and a detection stream; the image stream may include a preview stream and a recording stream, and the detection stream is used for various pattern recognition detection algorithms.
[0109] Step 604: Obtain the image of the Y component from the YUV image of the above detection stream.
[0110] Specifically, referring to Figure 7(a), Figure 7(a) is a schematic diagram of the recording end IPE and metadata generation module provided in one embodiment of this application. Figure 7(a) is illustrated using a recording stream as an example. As shown in Figure 7(a), the YUV image is split into three streams after being processed by the IPE: the detection stream, the preview stream, and the recording stream. The Y component image obtained from the YUV image in the detection stream is input into the local tone mapping (LTM) algorithm module 71.
[0111] The resolution of the Y component image here can be controlled by parameters according to the actual application.
[0112] Step 605: Detect the image of the Y component to obtain face bounding box information and scene information.
[0113] Referring again to Figure 7(a), the image of the Y component obtained from the YUV image of the detection stream is input into the perception engine 72. The detection algorithm in the perception engine 72 is used to obtain information such as face bounding box information and scene information. Then, the above face bounding box information and scene information are input into the LTM new algorithm module 71.
[0114] Step 606: Generate a local tone mapping curve and corresponding contrast enhancement intensity information based on the image of the Y component, the face bounding box information, and the scene information.
[0115] Specifically, the LTM new algorithm module 71 generates a local tone mapping curve and corresponding contrast enhancement intensity information based on the image of the Y component, the face bounding box information, and the scene information, using a combination of AI algorithms and traditional algorithms. Then, the generated local tone mapping curve and corresponding contrast enhancement intensity information are sent to the LTM hardware module 73 within the IPE, and the local tone mapping is directly implemented using the LTM hardware module 73.
[0116] Step 607: Denoise and color processing are performed on the YUV image in the above image stream, and tone mapping processing is performed on the YUV image after noise reduction and color processing according to the above local tone mapping curve and the above contrast enhancement intensity information to obtain the image to be processed.
[0117] Specifically, referring to Figure 7(a), in the IPE, the YUV images in the image stream are subjected to noise reduction and color processing. Based on the local tone mapping curve and the intensity information of the contrast enhancement, tone mapping processing is performed on the YUV images in the image stream to obtain the image to be processed. Then, the image to be processed is sent to the metadata generation module 74.
[0118] The algorithm flow for obtaining the image to be processed is described in detail below. Figure 7(b) is a flowchart of the algorithm for obtaining the image to be processed according to an embodiment of this application. Referring to Figure 7(b), after obtaining the image of the Y component from the YUV image of the above detection stream in step 604, the image of the Y component can be downsampled (e.g., 1 / 8 downsampling). Then, the downsampled image of the Y component is input into the LTM new algorithm module 71. In this embodiment, the LTM new algorithm module 71 can be implemented using an AI network. As mentioned above, the input of the LTM new algorithm module 71 is the downsampled image of the Y component, the label of the output image is the target effect image of high dynamic range and high contrast adjusted by the colorist, and the output is the contrast enhancement intensity information required by the LTM hardware module 73 for tone mapping processing. The following parameters can be configured: forward scaling (lceScalePos), reverse scaling (lceScaleNeg), local tone mapping scaling ratio (ltmscale), local tone mapping curve (ltmcurve), and local contrast enhancement threshold (lceThd). The loss function of the LTM new algorithm module 71 can be configured as follows: the goal is to make the actual output image as close as possible to the label after configuring the above contrast enhancement intensity information into the LTM hardware module 73.
[0119] In this embodiment, the LTM hardware module 73 can adopt the following scheme: After filtering with vgrid, a low-frequency image mask is obtained. The difference between the original Y component image and the mask is used as the high-frequency part, which is then amplified to achieve the goal of local contrast enhancement. The calculation formula is: yy2={mask+(yy1-mask)*lceScalePos / lceScaleNeg}*ltmscale*ltmcurve, where yy1 represents the input Y component image, yy2 represents the output Y component image (i.e., the image to be processed obtained in this step), mask represents the low-frequency image, and lceScalePos is used to multiply the difference by lceScalePos when yy1-mask>0, otherwise it is multiplied by lceScaleNeg. Then, the dynamic range of this difference is further increased by multiplying by ltmscale and ltmcurve. The difference between yy1-mask is clipped to the lceThd value range.
[0120] Step 608: Obtain the global tone mapping curve information and the local tone mapping curve information of the metadata.
[0121] Step 609: Display or encode the image to be processed based on the global tone mapping curve information and the local tone mapping curve information of the aforementioned metadata.
[0122] Specifically, the metadata generation module 74 can display or encode the image to be processed based on the global tone mapping curve information and the local tone mapping curve information of the metadata.
[0123] In the above image display method, the original image of the current shooting scene captured by the camera is acquired, and the original image is processed in the RAW domain to obtain a YUV image. Then, the YUV image is split into an image stream and a detection stream. The Y component image is obtained from the YUV image of the detection stream, and the Y component image is detected to obtain face bounding box information and scene information. Then, a local tone mapping curve and corresponding contrast enhancement intensity information are generated based on the Y component image, the face bounding box information, and the scene information, effectively improving the brightness and contrast effect of the video source at the recording end. Then, the YUV image in the image stream is downgraded. The process involves noise and color processing, and based on the aforementioned local tone mapping curve and contrast enhancement intensity information, tone mapping processing is performed on the YUV image after noise reduction and color processing to obtain the image to be processed. Finally, the global tone mapping curve information and local tone mapping curve information of the metadata are obtained. Based on the aforementioned global tone mapping curve information and local tone mapping curve information of the metadata, the image to be processed is displayed or encoded. This allows for the use of the global tone mapping curve information and local tone mapping curve information of the metadata to achieve linkage with the display end, resulting in a better end-to-end recording and display effect.
[0124] Figure 8 A flowchart of an image display method provided in another embodiment of this application is shown below. Figure 8 As shown, this application Figure 6 In the illustrated embodiment, before step 602, the following may also be included:
[0125] Step 801: Perform 3A statistics on the original images captured by the camera to obtain the 3A statistical information of the original images.
[0126] Specifically, 3A refers to auto focus (AF), automatic exposure (AE), and automatic white balance (AWB). Automatic exposure control automatically adjusts the brightness of the image, automatic focus control automatically adjusts the focal length, and automatic white balance compensates for color differences under different lighting conditions, thus presenting high-quality image information. Therefore, performing 3A statistics on the raw images captured by the aforementioned camera can include performing automatic exposure, automatic focus, and automatic white balance on the raw images captured by the aforementioned camera.
[0127] Figure 9 This application provides an embodiment of the IFE processing flow for HDR vividness in high dynamic range scenes. Figure 9In the process, the raw images captured by the camera are processed by shallow feature extraction (SFE) and then 3A statistics can be performed in the BG / Bhist module.
[0128] Step 802: Determine the dynamic range and ambient brightness of the current shooting scene based on the above 3A statistical information.
[0129] Step 803: After determining that the current shooting scene is a high dynamic range scene based on the above dynamic range and the above ambient brightness, instruct the above camera to output the original image in an overlapping image output manner.
[0130] In this embodiment, the above-mentioned overlapping image output method can be two long and short frames overlapping image output. Of course, the above-mentioned overlapping image output method is not limited to this. Other overlapping image output methods can also be used, such as three frames (long, medium and short) overlapping image output. However, this embodiment uses two long and short frames overlapping image output as an example for explanation.
[0131] Step 804: Obtain at least two original images output by the aforementioned camera in an overlapping image output manner.
[0132] Step 805: Fuse the above at least two original images to obtain a high dynamic range single-frame original image.
[0133] Specifically, see Figure 9 The aforementioned at least two original images are fed into the HDR merge module, where they are fused to obtain a high dynamic range single-frame original image. This high dynamic range single-frame original image is then fed into... Figure 9 The Hist stats module in [the context of the application].
[0134] Step 806: Perform histogram statistics on the above high dynamic range single-frame original image to obtain histogram statistical information.
[0135] Specifically, the Hist stats module performs histogram statistics on the aforementioned high dynamic range single-frame original image to obtain histogram statistical information.
[0136] Step 807: Based on the above histogram statistics, perform bit-width compression on the above high dynamic range single-frame original image to obtain the compressed original image.
[0137] Specifically, Figure 9To ensure that the dynamic range of both long and short frames is fused into the output high dynamic range single-frame original image, the HDR merge module retains a relatively high bit width. For example, if the input long and short frames are each 10 bits, the bit width of the output high dynamic range single-frame original image is 18 bits. Therefore, the fused high dynamic range single-frame original image can simultaneously retain the dark area details of the long frame and the highlight details of the short frame. Continuing to refer to Figure 7(a), after the high dynamic range single-frame original image output by SFE enters the RAW domain processing module 75 in Figure 7(a), the RAW domain processing module 75 can compress the bit width of the high dynamic range single-frame original image according to the aforementioned histogram statistics, for example, compressing 18 bits into 10 bits, and then continuing the subsequent ISP process with this 10-bit original image.
[0138] Thus, in this embodiment, step 602 can be:
[0139] Step 808: Perform RAW domain processing on the compressed original image to obtain a YUV image.
[0140] Additionally, it should be noted that in this embodiment, after step 804, at least two original images output in an overlapping manner can be input. Figure 9 The BG / Bhist module in the image performs histogram statistics to obtain histogram statistics of at least two original images. The histogram statistics of at least two original images can further drive the image output method and brightness configuration of the camera in the next frame.
[0141] This embodiment designs a corresponding bit width compression method for the high bit width image after HDR fusion in HDR scenes, so as to simultaneously maintain the details of the highlight and shadow areas, and realize the adjustment of brightness and contrast, so as to achieve the optimal local brightness and contrast effect.
[0142] Figure 10 A flowchart of an image display method provided in another embodiment of this application is shown below. Figure 10 As shown, this application Figure 6 In step 608 of the illustrated embodiment, obtaining the global tone mapping curve information of the metadata may include:
[0143] Step 1001: Perform global histogram statistics on the above image to be processed to obtain global histogram information.
[0144] Step 1002: Statistically analyze the pixel distribution information based on the global histogram information to obtain the statistical information of the metadata.
[0145] Step 1003: Calculate the global tone mapping base curve based on the statistical information of the above metadata.
[0146] Step 1004: Based on the scene switching information, control the filtering parameters of the aforementioned global tone mapping base curve. The scene switching information includes scene information obtained by detecting the image of the Y component, and scene information calculated from the image of the Y component. Specifically, as shown in Figure 7(a), the scene information obtained by the perception engine 72 detecting the image of the Y component, and the scene information calculated by the LTM new algorithm module 71, are both sent to the metadata generation module 74. The metadata generation module 74 uses the aforementioned scene information to determine scene smoothness, ensuring that the corresponding metadata can switch quickly during scene switching, while the internally calculated metadata can transition smoothly when the scene is not switching, resulting in a smooth effect.
[0147] Step 1005: Using the filtered global tone mapping base curve, generate the global tone mapping curve information of the metadata.
[0148] In summary, the method for obtaining global tone mapping curve information for metadata can be to calculate a cubic spline curve (this method directly uses the approach defined in the HDR Vivid standard), while simultaneously controlling the infinite impulse response (IIR) filtering parameters of the global tone mapping base curve based on scene switching information. Finally, the global tone mapping curve information for metadata is generated using the filtered global tone mapping base curve.
[0149] like Figure 10 As shown, in step 608, obtaining the local tone mapping curve information of the metadata may include:
[0150] Step 1006: Divide the image of the Y component into grids.
[0151] Step 1007: Obtain the local statistical histogram of the image within each grid.
[0152] Step 1008: Update the above local statistical histogram using the filtered global tone mapping base curve.
[0153] Step 1009: Generate the local tone mapping curve of the image within each grid based on the updated local statistical histogram.
[0154] Specifically, the local histogram can be updated within each small grid using the filtered global tone mapping base curve. Then, each small grid is treated as a global graph, and the corresponding tone mapping curve, i.e., the local tone mapping curve, is generated for each small grid using the method for generating the global tone mapping base curve.
[0155] Step 1010: Based on the scene switching information and the spatial adjacency information of the grid, perform temporal and spatial filtering on the local tone mapping curve to generate local tone mapping curve information of metadata.
[0156] In this embodiment, the correspondence between the local tone mapping curve in each small grid and the local tone mapping curve information of the metadata conforms to the GTM standard definition of HDR vivid.
[0157] Figure 11 A flowchart of an image display method provided in another embodiment of this application is shown below. Figure 11 As shown, this application Figure 8 In the illustrated embodiment, after step 802, the following may also be included:
[0158] Step 1101: After determining that the current shooting scene is a non-high dynamic range scene based on the above dynamic range and ambient brightness, instruct the camera to output the original image in a single-frame output manner to obtain a single-frame original image.
[0159] Step 1102: Perform histogram statistics on the above single-frame original image to obtain the histogram information of the above single-frame original image, and generate a global tone mapping curve based on the histogram information of the above single-frame original image.
[0160] Step 1103: Perform RAW domain processing on the above single-frame original image to obtain a single-frame YUV image.
[0161] Step 1104: Based on the aforementioned global tone mapping curve, perform tone mapping processing on the aforementioned single-frame YUV image to obtain the image to be processed. Then, execute step 608.
[0162] Specifically, see Figure 12 , Figure 12 This is a flowchart illustrating RAW domain processing in a non-high dynamic range scene according to one embodiment of this application. After determining that the current shooting scene is a non-high dynamic range scene based on the dynamic range and ambient brightness, it is not necessary to use a long-short frame fusion mechanism to achieve a better dynamic range; a single frame can be output directly. Therefore, the camera can be instructed to output the original image in a single-frame manner to obtain a single-frame original image. Figure 9 In comparison, the main difference in the workflow lies in the processing of the RAW field, the specific workflow of which is as follows: Figure 12 As shown.
[0163] In this embodiment, the camera outputs images in single-frame mode. Therefore, it does not need to enter the HDR merge module. Instead, the single-frame raw image is directly sent to the IFE module. Thus, the bit width of the single-frame raw image is directly 10 bits, requiring no bit width compression. Consequently, the bayer_GTM and bayer_LTM modules within the IFE module do not need to perform operations on the single-frame raw image. The single-frame raw image directly enters the GTM hardware module, which performs RAW domain processing on the single-frame raw image to obtain a single-frame YUV image. Additionally, in this embodiment, see... Figure 12 The BG / Bhist module can perform histogram statistics on the above single-frame original image to obtain the histogram information of the above single-frame original image, and then provide the histogram information of the above single-frame original image to the GTM new algorithm module, which calculates the global tone mapping curve.
[0164] The new GTM algorithm module sends the global tone mapping curve to the GTM hardware module. The GTM hardware module performs tone mapping processing on the single-frame YUV image based on the global tone mapping curve to obtain the image to be processed. Then, steps 608 and 609 are executed.
[0165] The image display method provided in this application embodiment can guarantee the brightness and contrast effects in high dynamic and non-high dynamic scenes, and uses global and local tone mapping to guarantee the point height and contrast effects of global and local areas within the video frame; it also provides an end-to-end linkage HDR vivid system solution that coordinates the recording end and the display end to ensure optimal display effects on various HDR brightness displays.
[0166] It is understood that some or all of the steps or operations in the above embodiments are merely examples, and other operations or variations thereof can be performed in the embodiments of this application. Furthermore, the steps may be performed in different orders as presented in the above embodiments, and it is not necessary to perform all the operations in the above embodiments.
[0167] It is understood that, in order to achieve the above-mentioned functions, the terminal device includes hardware and / or software modules corresponding to the execution of each function. Based on the algorithm steps of the various examples described in conjunction with the embodiments disclosed in this application, this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed by hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application in conjunction with the embodiments, but such implementation should not be considered beyond the scope of this application.
[0168] This embodiment can divide the terminal device into functional modules according to the above method embodiment. For example, each function can be divided into its own functional module, or two or more functions can be integrated into one module. The integrated module can be implemented in hardware. It should be noted that the module division in this embodiment is illustrative and only represents one logical functional division. In actual implementation, there may be other division methods.
[0169] Figure 13 This is a schematic diagram of the structure of a terminal device provided in another embodiment of this application. In the case where functional modules are divided according to their respective functions, Figure 13 This diagram illustrates a possible configuration of the terminal device 1300 involved in the above embodiments, as shown below. Figure 13 As shown, the terminal device 1300 may include: an acquisition module 1301, a RAW domain processing module 1302, a splitting module 1303, a detection module 1304, a generation module 1305, a noise reduction processing module 1306, a tone mapping module 1307, and a display encoding module 1308.
[0170] The acquisition module 1301 is used to acquire the original image of the current shooting scene captured by the camera;
[0171] RAW domain processing module 1302 is used to perform RAW domain processing on the above-mentioned original image to obtain a YUV image;
[0172] The splitting module 1303 is used to split the YUV image to obtain an image stream and a detection stream;
[0173] The acquisition module 1301 is also used to acquire an image of the Y component from the YUV image of the above-mentioned detection stream;
[0174] Detection module 1304 is used to detect the image of the Y component mentioned above and obtain face bounding box information and scene information;
[0175] The generation module 1305 is used to generate a local tone mapping curve and corresponding contrast enhancement intensity information based on the image of the Y component, the face bounding box information and the scene information.
[0176] The noise reduction processing module 1306 is used to perform noise reduction and color processing on the YUV images in the above image stream;
[0177] The tone mapping module 1307 is used to perform tone mapping processing on the YUV image after noise reduction and color processing according to the above-mentioned local tone mapping curve and the intensity information of contrast enhancement, so as to obtain the image to be processed.
[0178] The acquisition module 1301 is also used to acquire global tone mapping curve information and local tone mapping curve information of metadata;
[0179] The display encoding module 1308 is used to display or encode the image to be processed based on the global tone mapping curve information and the local tone mapping curve information of the aforementioned metadata.
[0180] It should be noted that this application Figure 6 All relevant content of each step involved in the method embodiment shown can be referenced from the functional description of the corresponding functional module, and will not be repeated here.
[0181] The terminal device 1300 provided in this embodiment is used to execute this application. Figure 6 The image display method provided in the illustrated embodiment can achieve the same effect as the method described above.
[0182] Figure 14 This is a schematic diagram of the structure of a terminal device provided in another embodiment of this application, and... Figure 13 The difference between the terminal devices shown and those shown is that... Figure 14 The terminal device 1300 shown may further include: a statistics module 1309, a determination module 1310, an indication module 1311, a fusion module 1312, and a compression module 1313;
[0183] The statistics module 1309 is used to perform 3A statistics on the original image captured by the camera before the RAW domain processing module 1302 performs RAW domain processing on the original image to obtain the YUV image, and obtain the 3A statistical information of the original image.
[0184] The determination module 1310 is used to determine the dynamic range and ambient brightness of the current shooting scene based on the above 3A statistical information;
[0185] Instruction module 1311 is used to instruct the camera to output the original image in an overlapping manner after determining that the current shooting scene is a high dynamic range scene based on the dynamic range and ambient brightness.
[0186] The acquisition module 1301 is also used to acquire at least two original images output by the camera in an overlapping image output manner;
[0187] The fusion module 1312 is used to fuse the above-mentioned at least two original images to obtain a high dynamic range single-frame original image;
[0188] The statistics module 1309 is also used to perform histogram statistics on the above-mentioned high dynamic range single-frame original image to obtain histogram statistical information;
[0189] Compression module 1313 is used to perform bit-width compression on the above high dynamic range single frame original image according to the above histogram statistical information to obtain the compressed original image.
[0190] Thus, the RAW domain processing module 1302 is specifically used to perform RAW domain processing on the compressed original image to obtain a YUV image.
[0191] In this embodiment, the acquisition module 1301 is specifically used to perform global histogram statistics on the image to be processed to obtain global histogram information; to perform statistics on the distribution information of pixels based on the global histogram information to obtain statistical information of metadata; to calculate the global tone mapping basic curve based on the statistical information of the metadata; to control the filtering parameters of the global tone mapping basic curve based on scene switching information; and to generate global tone mapping curve information of metadata using the filtered global tone mapping basic curve; wherein, the scene switching information includes scene information obtained by detecting the image of the Y component, and scene information obtained by calculating the image of the Y component.
[0192] Additionally, the acquisition module 1301 is specifically used to divide the image of the Y component into grids, acquire the local statistical histogram of the image within each grid; update the local statistical histogram using the filtered global tone mapping base curve; generate the local tone mapping curve of the image within each grid based on the updated local statistical histogram; and perform temporal and spatial filtering on the local tone mapping curve based on the scene switching information and the spatial adjacency information of the grid to generate local tone mapping curve information of metadata.
[0193] Furthermore, the instruction module 1311 is also used to instruct the camera to output the original image in a single-frame output manner after the determination module 1310 determines the dynamic range and ambient brightness of the current shooting scene, and after determining that the current shooting scene is a non-high dynamic scene based on the dynamic range and ambient brightness, thereby obtaining a single-frame original image.
[0194] The statistics module 1309 is also used to perform histogram statistics on the above-mentioned single-frame original image, obtain the histogram information of the above-mentioned single-frame original image, and generate a global tone mapping curve based on the histogram information of the above-mentioned single-frame original image.
[0195] RAW domain processing module 1302 is also used to perform RAW domain processing on the above-mentioned single-frame original image to obtain a single-frame YUV image.
[0196] The tone mapping module 1307 is also used to perform tone mapping processing on the single-frame YUV image according to the global tone mapping curve to obtain the image to be processed.
[0197] It should be noted that this application Figures 6-12 All relevant content of each step involved in the method embodiment shown can be referenced from the functional description of the corresponding functional module, and will not be repeated here.
[0198] The terminal device 1300 provided in this embodiment is used to execute this application. Figures 6-12 The image display method provided in the illustrated embodiment can achieve the same effect as the method described above.
[0199] It should be understood that terminal device 1300 can correspond to Figure 4 The terminal device 100 shown. The functions of each module in the terminal device 1300 can be determined by... Figure 4 The processor 110 in the terminal device 100 shown is implemented.
[0200] When using integrated units, the terminal device 1300 may include a processing module, a storage module, and a communication module.
[0201] The processing module can be used to control and manage the actions of the terminal device 1300, for example, it can be used to support the terminal device 1300 in performing... Figure 13 and Figure 14 The steps executed by each module are described below. The storage module can be used to support the storage of program code and data by the terminal device 1300. The communication module can be used to support communication between the terminal device 1300 and other devices.
[0202] The processing module can be a processor or controller, which can implement or execute the various exemplary logic blocks, modules, and circuits described in conjunction with the disclosure of this application. The processor can also be a combination of functions that implement computing capabilities, such as a combination of one or more microprocessors, a combination of digital signal processing (DSP) and a microprocessor, etc. The storage module can be a memory. The communication module can specifically be a device that interacts with other electronic devices, such as radio frequency circuitry, a Bluetooth chip, and / or a Wi-Fi chip.
[0203] In one embodiment, when the processing module is a processor and the storage module is a memory, the terminal device 1300 involved in this embodiment can be a device having... Figure 4 The device with the structure shown.
[0204] This application also provides a computer-readable storage medium storing a computer program that, when run on a computer, causes the computer to execute this application. Figures 6-12 The method provided in the illustrated embodiment.
[0205] This application also provides a computer program product, which includes a computer program that, when run on a computer, causes the computer to execute this application. Figures 6-12 The method provided in the illustrated embodiment.
[0206] In this application embodiment, "at least one" refers to one or more, and "more than one" refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent the existence of A alone, A and B simultaneously, or B alone. A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one of the following" and similar expressions refer to any combination of these items, including any combination of singular or plural items. For example, at least one of a, b, and c can represent: a, b, c, a and b, a and c, b and c, or a and b and c, where a, b, and c can be single or multiple.
[0207] Those skilled in the art will recognize that the units and algorithm steps described in the embodiments disclosed herein can be implemented using electronic hardware, computer software, or a combination of electronic hardware and software. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0208] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0209] In the several embodiments provided in this application, any function, if implemented as a software functional unit and sold or used as an independent product, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, essentially, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0210] The above description is merely a specific embodiment of this application. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the protection scope of this application. The protection scope of this application should be determined by the protection scope of the claims.
Claims
1. A method for displaying an image, characterized in that, include: Acquire the raw image of the current shooting scene captured by the camera; The original image is processed in the RAW domain to obtain a YUV image; The YUV image is split into an image stream and a detection stream. Obtain an image of the Y component from the YUV image of the detection stream; The image of the Y component is detected to obtain face bounding box information and scene information; Based on the image of the Y component, the face bounding box information, and the scene information, a local tone mapping curve and corresponding contrast enhancement intensity information are generated; The YUV images in the image stream are subjected to noise reduction and color processing, and the YUV images after noise reduction and color processing are subjected to tone mapping processing based on the local tone mapping curve and the intensity information of the contrast enhancement to obtain the image to be processed. Obtain the global tone mapping curve information and the local tone mapping curve information of the metadata; The image to be processed is displayed or encoded based on the global tone mapping curve information and the local tone mapping curve information of the metadata.
2. The method according to claim 1, characterized in that, Before performing RAW domain processing on the original image to obtain a YUV image, the process further includes: Perform 3A statistics on the raw images captured by the camera to obtain the 3A statistical information of the raw images; The dynamic range and ambient brightness of the current shooting scene are determined based on the 3A statistical information. After determining that the current shooting scene is a high dynamic range scene based on the dynamic range and the ambient brightness, the camera is instructed to output the original image in an overlapping image output manner; Acquire at least two original images output by the camera in an overlapping image output manner; The at least two original images are fused to obtain a high dynamic range single-frame original image; Histogram statistics are performed on the original high dynamic range single-frame image to obtain histogram statistical information; Based on the histogram statistics, the high dynamic range single-frame original image is compressed to obtain the compressed original image. The step of performing RAW domain processing on the original image to obtain a YUV image includes: The compressed original image is processed in the RAW domain to obtain a YUV image.
3. The method according to claim 1, characterized in that, The global tone mapping curve information for obtaining metadata includes: Global histogram statistics are performed on the image to be processed to obtain global histogram information; The distribution information of pixels is statistically analyzed based on the global histogram information to obtain statistical information of metadata; Calculate the global tone mapping base curve based on the statistical information of the metadata; Based on scene switching information, the filtering parameters of the global tone mapping base curve are controlled; wherein, the scene switching information includes scene information obtained by detecting the image of the Y component, and scene information obtained by calculating the image of the Y component; Using the filtered global tone mapping base curve, global tone mapping curve information for metadata is generated.
4. The method according to claim 3, characterized in that, The local tone mapping curve information for obtaining metadata includes: The image of the Y component is divided into grids; Obtain the local statistical histogram of the image within each grid cell; The local statistical histogram is updated using the filtered global tone mapping base curve; Generate local tone mapping curves for the image within each grid based on the updated local statistical histogram; Based on the scene switching information and the spatial adjacency information of the grid, the local tone mapping curve is filtered in both the temporal and spatial domains to generate local tone mapping curve information of metadata.
5. The method according to claim 2, characterized in that, After determining the dynamic range and ambient brightness of the current shooting scene based on the 3A statistical information, the method further includes: After determining that the current shooting scene is a non-high dynamic range scene based on the dynamic range and the ambient brightness, the camera is instructed to output the original image in a single-frame output manner to obtain a single-frame original image. Histogram statistics are performed on the single-frame original image to obtain the histogram information of the single-frame original image. Based on the histogram information of the single-frame original image, a global tone mapping curve is generated. The single-frame original image is processed in the RAW domain to obtain a single-frame YUV image; Based on the global tone mapping curve, the single-frame YUV image is subjected to tone mapping processing to obtain the image to be processed.
6. An image display device, characterized in that, include: The acquisition module is used to acquire the original image of the current shooting scene captured by the camera; The RAW domain processing module is used to perform RAW domain processing on the original image to obtain a YUV image; The splitting module is used to split the YUV image to obtain an image stream and a detection stream; The acquisition module is further configured to acquire an image of the Y component from the YUV image of the detection stream; The detection module is used to detect the image of the Y component and obtain face bounding box information and scene information; The generation module is used to generate a local tone mapping curve and corresponding contrast enhancement intensity information based on the image of the Y component, the face bounding box information, and the scene information; A noise reduction processing module is used to perform noise reduction and color processing on the YUV images in the image stream; The tone mapping module is used to perform tone mapping processing on the YUV image after noise reduction and color processing according to the local tone mapping curve and the intensity information of contrast enhancement, so as to obtain the image to be processed. The acquisition module is also used to acquire global tone mapping curve information and local tone mapping curve information of metadata; The display encoding module is used to display or encode the image to be processed based on the global tone mapping curve information and the local tone mapping curve information of the metadata.
7. A terminal device, characterized in that, include: One or more processors; Memory; Multiple applications; and one or more computer programs, wherein the one or more computer programs are stored in the memory, and the one or more computer programs include instructions that, when executed by the terminal device, cause the terminal device to perform the following steps: Acquire the raw image of the current shooting scene captured by the camera; The original image is processed in the RAW domain to obtain a YUV image; The YUV image is split into an image stream and a detection stream. Obtain an image of the Y component from the YUV image of the detection stream; The image of the Y component is detected to obtain face bounding box information and scene information; Based on the image of the Y component, the face bounding box information, and the scene information, a local tone mapping curve and corresponding contrast enhancement intensity information are generated; The YUV images in the image stream are subjected to noise reduction and color processing, and the YUV images after noise reduction and color processing are subjected to tone mapping processing based on the local tone mapping curve and the intensity information of the contrast enhancement to obtain the image to be processed. Obtain the global tone mapping curve information and the local tone mapping curve information of the metadata; The image to be processed is displayed or encoded based on the global tone mapping curve information and the local tone mapping curve information of the metadata.
8. The terminal device according to claim 7, characterized in that, When the instruction is executed by the terminal device, before the terminal device performs the step of RAW domain processing on the original image to obtain a YUV image, the following steps are also performed: Perform 3A statistics on the raw images captured by the camera to obtain the 3A statistical information of the raw images; The dynamic range and ambient brightness of the current shooting scene are determined based on the 3A statistical information. After determining that the current shooting scene is a high dynamic range scene based on the dynamic range and the ambient brightness, the camera is instructed to output the original image in an overlapping image output manner; Acquire at least two original images output by the camera in an overlapping image output manner; The at least two original images are fused to obtain a high dynamic range single-frame original image; Histogram statistics are performed on the original high dynamic range single-frame image to obtain histogram statistical information; Based on the histogram statistics, the high dynamic range single-frame original image is compressed to obtain the compressed original image. When the instruction is executed by the terminal device, causing the terminal device to perform RAW domain processing on the original image to obtain a YUV image, the steps include: The compressed original image is processed in the RAW domain to obtain a YUV image.
9. The terminal device according to claim 7, characterized in that, When the instruction is executed by the terminal device, causing the terminal device to perform the step of obtaining global tone mapping curve information of metadata includes: Global histogram statistics are performed on the image to be processed to obtain global histogram information; The distribution information of pixels is statistically analyzed based on the global histogram information to obtain statistical information of metadata; Calculate the global tone mapping base curve based on the statistical information of the metadata; Based on scene switching information, the filtering parameters of the global tone mapping base curve are controlled; wherein, the scene switching information includes scene information obtained by detecting the image of the Y component, and scene information obtained by calculating the image of the Y component; Using the filtered global tone mapping base curve, global tone mapping curve information for metadata is generated.
10. The terminal device according to claim 9, characterized in that, When the instruction is executed by the terminal device, causing the terminal device to perform the step of obtaining the local tone mapping curve information of metadata includes: The image of the Y component is divided into grids; Obtain the local statistical histogram of the image within each grid cell; The local statistical histogram is updated using the filtered global tone mapping base curve; Generate local tone mapping curves for the image within each grid based on the updated local statistical histogram; Based on the scene switching information and the spatial adjacency information of the grid, the local tone mapping curve is filtered in both the temporal and spatial domains to generate local tone mapping curve information of metadata.
11. The terminal device according to claim 8, characterized in that, When the instruction is executed by the terminal device, after the terminal device performs the step of determining the dynamic range and ambient brightness of the current shooting scene based on the 3A statistical information, it also performs the following steps: After determining that the current shooting scene is a non-high dynamic range scene based on the dynamic range and the ambient brightness, the camera is instructed to output the original image in a single-frame output manner to obtain a single-frame original image. Histogram statistics are performed on the single-frame original image to obtain the histogram information of the single-frame original image. Based on the histogram information of the single-frame original image, a global tone mapping curve is generated. The single-frame original image is processed in the RAW domain to obtain a single-frame YUV image; Based on the global tone mapping curve, the single-frame YUV image is subjected to tone mapping processing to obtain the image to be processed.
12. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when run on a computer, causes the computer to perform the method as described in any one of claims 1-5.