Display method and electronic equipment

By combining camera components, memory and processors, adjusting the brightness of the pictures or videos displayed by electronic devices to make them consistent with the shooting environment, and performing tone mapping when displaying HDR pictures, the problem of brightness mismatch is solved and the sense of reality is improved. Contrast.

CN119311237AActive Publication Date: 2025-01-14HUAWEI TECH CO LTD

Patent Information

Application Number
CN202411311377.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-19
Publication Date
2025-01-14
Estimated Expiration
2044-09-19

AI Technical Summary

Technical Problem

When an electronic device displays pictures or videos, the brightness does not match the shooting scene, resulting in insufficient realism, affecting the user experience.

Method used

Through the combination of camera components, memory and processor, we can obtain the shooting ambient illuminance and brightness, adjust the display brightness according to the current ambient illuminance, so that the displayed pictures or videos are consistent with the brightness in the shooting environment, and when displaying HDR pictures, according to the display Screen brightness capability performs tone mapping to restore high dynamic range areas.

Benefits of technology

Improves the realistic feel of pictures and videos, enhances the user experience, and increases the contrast and details of high dynamic range areas when displaying HDR pictures, reducing brightness saturation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119311237A_ABST
    Figure CN119311237A_ABST
Patent Text Reader

Abstract

The invention provides a display method and electronic equipment, and in the application, when the electronic equipment displays a picture, the shooting environment illumination of the picture, the brightness of a first gray scale of the picture in the shooting environment, and the brightness of a current watching environment can be obtained. The electronic equipment can determine the brightness of a first gray scale of a picture displayed in a display screen in a watching environment based on the shooting environment illumination, the display screen brightness in the shooting environment and the current watching environment brightness. And when the electronic equipment displays the picture, setting the brightness corresponding to each gray-scale value in the picture according to the brightness of the first gray scale of the picture in the determined watching environment. Besides, the electronic equipment can also obtain the brightness compression curve of the high dynamic range area in the picture, and perform tone mapping based on the brightness compression curve to restore the contrast ratio of the brightness of the pixel points in the high dynamic range area in the picture. Therefore, the contrast ratio of the highlight area in the picture displayed by the electronic equipment is higher, and the sense of reality is stronger.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of electronic technology, and in particular to a display method and an electronic device. Background Art

[0002] Currently, electronic devices all have display screens, and electronic devices can display pictures, animations, videos and other contents on the display screens. The contents displayed on the display screen are composed of each pixel having a color value and a grayscale value on the display screen. The brightness of the display screen of the electronic device will affect the display effect of the contents such as pictures, animations or videos displayed on the display screen. Taking pictures as an example, the higher the brightness of the display screen, the brighter the picture displayed on the display screen looks; the lower the brightness of the display screen, the darker the picture displayed on the display screen looks.

[0003] If a picture or video taken in a bright scene is displayed on a display with lower brightness, it will appear darker than the actual scene when it was taken. If a picture or video taken in a dark scene is displayed on a display with higher brightness, it will appear brighter than the actual scene when it was taken. In this way, the brightness of the display affects the realism of the picture or video.

[0004] Therefore, how to improve the realism of the pictures displayed on the display screen is a problem that needs to be solved urgently. Summary of the invention

[0005] The present application provides a display method and an electronic device. The display method provided by the present application can improve the realism of pictures displayed on the display screen of the electronic device.

[0006] In a first aspect, the present application provides an electronic device, which may include a camera component, a display screen, a memory, and a processor, wherein the camera, the display screen, and the memory are respectively coupled to the processor, wherein:

[0007] The camera assembly can be used to: take a first picture;

[0008] The memory may be used to: store a first picture, a shooting environment illumination, and a first brightness, wherein the shooting environment illumination is the environment illumination when the first picture is shot, and the first brightness is the brightness value of a pixel point of a first grayscale of the first picture under the shooting environment illumination;

[0009] The processor may be used to: when the electronic device displays the first picture in the first scene, obtain the first environmental illumination of the first scene, determine the second brightness based on the shooting environment illumination, the first brightness and the first environmental illumination, the second brightness being the brightness value of the pixel point of the first gray scale in the first picture under the first environmental illumination; and map the brightness value of the pixel point of the first gray scale in the first picture to the second brightness;

[0010] The display screen can be used to: display a first picture in a first scene, and the brightness value of a pixel point of a first gray scale in the first picture is a second brightness.

[0011] In this way, the first picture displayed by the electronic device in the first scene is consistent with the look and feel of the first picture in the shooting environment. That is, the electronic device can display the first picture more realistically.

[0012] In a possible implementation manner, the processor may also be configured to: determine, based on the second brightness, a brightness value of a pixel point of the second grayscale of the first image as a third brightness.

[0013] In this way, when the display screen of the electronic device displays the first picture, the brightness values ​​of the pixels of other grayscale values ​​can be determined according to the brightness values ​​of the pixels of the first grayscale of the first picture.

[0014] In a possible implementation, the processor may be used to: determine the illumination of the shooting environment based on the exposure value of the camera component; or determine the illumination of the shooting environment based on one or more of the weather, time, and location when the first picture was taken.

[0015] In this way, the processor can determine the illumination of the shooting environment.

[0016] In a possible implementation, the processor may be configured to determine the first ambient illumination based on one or more of weather, time, and location when the first picture is displayed.

[0017] In this way, the processor can determine the first ambient illumination.

[0018] In a possible implementation, the electronic device further includes an ambient light sensor, which is coupled to the processor. The ambient light sensor may be used to:

[0019] Collecting the illumination of the shooting environment when taking the first picture;

[0020] When the electronic device displays the first picture, the first ambient illumination is collected.

[0021] In this way, the electronic device can determine the shooting environment illumination and the first environment illumination through the ambient light sensor.

[0022] In a possible implementation, the processor may be configured to:

[0023] When the electronic device displays the first picture in the second scene, obtaining a second ambient illumination of the second scene;

[0024] Determine a fourth brightness based on the shooting environment illumination, the first brightness, and the second environment illumination, where the fourth brightness is a brightness value of a pixel point of a first grayscale of the first picture under the second environment illumination;

[0025] Mapping the brightness value of a pixel point of a first grayscale in the first image to a fourth brightness;

[0026] The display screen can be used to: display a first picture in a second scene, and the brightness value of a pixel point of a first gray scale in the first picture is a fourth brightness.

[0027] In this way, the brightness values ​​of the pixels of the first grayscale of the first picture displayed by the electronic device under different ambient illuminations are different. The brightness perception of the first picture displayed by the electronic device in any scene is consistent with the brightness perception of the first picture in the shooting environment. Thus, the realism of the first picture displayed by the electronic device can be improved, thereby improving the user experience.

[0028] In a possible implementation, if the second environment illumination is less than the first environment illumination, the fourth brightness is less than the second brightness;

[0029] If the second environment illumination is greater than the first environment illumination, the fourth brightness is greater than the second brightness;

[0030] If the second environment illumination is equal to the first environment illumination, the fourth brightness is equal to the second brightness.

[0031] In this way, when the first picture is displayed, the lower the ambient illumination is, that is, the darker the viewing environment is, the lower the brightness value of the first grayscale pixel of the first picture displayed by the electronic device is. Conversely, when the first picture is displayed, the higher the ambient illumination is, that is, the brighter the viewing environment is, the higher the brightness value of the first grayscale pixel of the first picture displayed by the electronic device is.

[0032] In a second aspect, an electronic device is provided. The electronic device may include a camera component, a display screen, a memory, and a processor. The camera component, the display screen, and the memory are respectively coupled to the processor, wherein:

[0033] The camera component can be used to: take a high dynamic range picture, and compress a high dynamic range area in the high dynamic range picture to obtain a compressed picture and compression information, wherein the compression information includes a corresponding relationship between a dynamic range and a compression ratio in the compressed picture;

[0034] The memory can be used to: store compressed images and compressed information;

[0035] The processor may be used to: obtain the compressed image and compression information when the electronic device displays the compressed image;

[0036] Based on the compression information, the corresponding relationship between the display brightness and the dynamic range of the high dynamic range image is obtained;

[0037] Based on the correspondence between the brightness of the display screen and the dynamic range of the high dynamic range image, tone mapping is performed on the compressed image to obtain a tone mapped image, and the brightness at the maximum value of the high dynamic range in the tone mapped image is the maximum brightness supported by the display screen;

[0038] The display can be used to: Display tone mapped images.

[0039] In this way, when displaying a compressed image, the electronic device can perform tone mapping on the image based on the correspondence between the dynamic range of the image and the display brightness capability of the display screen, and restore the high dynamic range area in the image. In this way, the contrast and details of the high dynamic range area of ​​the displayed image can be increased, and the brightness saturation can be reduced.

[0040] In a possible implementation, the processor may be configured to:

[0041] Determine the dynamic range in the high dynamic range image based on the compression information;

[0042] The corresponding relationship between the dynamic range in the high dynamic range picture and the brightness of the display screen is determined, wherein the brightness of the maximum value of the high dynamic range in the high dynamic range picture is set as the maximum brightness of the display screen.

[0043] In this way, the processor can restore the dynamic range of the high dynamic range picture, and can map the dynamic range of the high dynamic range picture with the brightness of the display screen, thereby making full use of the display capability of the display screen and restoring the contrast of the high dynamic range area in the high dynamic range picture.

[0044] In a possible implementation, a multiple of a maximum value of a dynamic range in a compressed image to a maximum value of a standard dynamic range is a first multiple; a multiple of a maximum value of a high dynamic range in a high dynamic range image to a maximum value of a standard dynamic range is a second multiple; a multiple of a maximum value of a dynamic range in a tone-mapped image to a maximum value of a standard dynamic range is a third multiple;

[0045] The first multiple is smaller than the second multiple, and the third multiple is larger than the first multiple and smaller than or equal to the second multiple.

[0046] In this way, the tone-mapped picture displayed by the electronic device can restore the original picture as much as possible, that is, the maximum value of the high dynamic range in the high dynamic range picture and the multiple of the maximum value of the standard dynamic range.

[0047] In a third aspect, an electronic device is provided. The electronic device may include a camera component, a display screen, a memory, and a processor. The camera component, the display screen, and the memory are respectively coupled to the processor, wherein:

[0048] The camera assembly may be used to: shoot a first video, wherein the first video includes a first image frame;

[0049] The memory may be used to: store a first image frame, a first shooting environment illumination, and a first brightness, wherein the first shooting environment illumination is the environment illumination when the first image frame is shot, and the first brightness is the brightness value of a pixel point of a first grayscale of the first image frame under the first shooting environment illumination;

[0050] The processor may be used to: when the electronic device displays the first image frame in the first scene, obtain the first environmental illumination of the first scene, determine the second brightness based on the first shooting environment illumination, the first brightness and the first environmental illumination, the second brightness being the brightness value of the pixel point of the first gray scale in the first image frame under the first environmental illumination; map the brightness value of the pixel point of the first gray scale in the first image frame to the second brightness;

[0051] The display screen can be used to: display a first image frame of a first video in a first scene, and the brightness value of a pixel point of a first grayscale of the first image frame is a second brightness.

[0052] In this way, the first video displayed by the electronic device in the first scene is consistent with the look and feel of the first video in the shooting environment. That is, the electronic device can display the first video more realistically.

[0053] In a possible implementation manner, the processor may be further configured to: determine, based on the second brightness, a brightness value of a pixel point of the second grayscale of the first image frame as a third brightness.

[0054] In this way, when the display screen of the electronic device displays the first image frame of the first video, the brightness values ​​of the pixels of other grayscale values ​​can be determined according to the brightness values ​​of the pixels of the first grayscale of the first image frame.

[0055] In a possible implementation, the processor may be configured to:

[0056] When the electronic device displays the first image frame in the second scene, acquiring a second ambient illumination of the second scene;

[0057] Determine a fourth brightness based on the shooting environment illumination, the first brightness, and the second environment illumination, where the fourth brightness is a brightness value of a pixel point of a first grayscale of the first image frame under the second environment illumination;

[0058] Mapping the brightness value of a pixel point of a first grayscale of the first image frame to a fourth brightness;

[0059] The display screen can be used to: display a first image frame in a second scene, and the brightness value of a pixel point of a first gray scale in the first image frame is a fourth brightness.

[0060] In this way, the brightness values ​​of the pixels of the first grayscale of the first image frame displayed by the electronic device under different ambient illuminations are different. The brightness perception of the first image frame displayed by the electronic device in any scene is consistent with the brightness perception of the first image frame in the shooting environment. Thus, the realism of the first image frame displayed by the electronic device can be improved, thereby improving the user experience.

[0061] In a possible implementation manner, the first video further includes a second image frame;

[0062] The memory may be used to: store the second image frame, the second shooting environment illumination and the fifth brightness, wherein the second shooting environment illumination is the environment illumination when the second image frame is shot, and the fifth brightness is the brightness value of the pixel point of the first gray scale of the second image frame under the second shooting environment illumination;

[0063] The processor may be configured to: when the electronic device displays the second image frame in the first scene, obtain the first ambient illumination of the first scene, determine the sixth brightness based on the shooting ambient illumination, the fifth brightness, and the first ambient illumination, the sixth brightness being the brightness value of the pixel point of the first gray scale in the second image frame under the first ambient illumination; and map the brightness value of the pixel point of the first gray scale in the second image frame to the sixth brightness;

[0064] The display screen can be used to: display a second image frame of the first video in a first scene, and the brightness value of a pixel point of the first grayscale of the second image frame is a sixth brightness.

[0065] The illumination of the shooting environment of the first image frame may be the same as or different from the illumination of the shooting environment of the second image frame. That is, the illumination of the first shooting environment may be equal to or different from the illumination of the second shooting environment. When the illumination of the first shooting environment is equal to the illumination of the second shooting environment, the sixth brightness may be equal to the second brightness.

[0066] In this way, when two image frames of the first video shot in different shooting environments are displayed in the same scene of the electronic device, the brightness values ​​of the pixels of the first grayscale of the two image frames can be different. The brightness of the image frame displayed by the electronic device can be consistent with the appearance of the image frame in the shooting scene.

[0067] In a fourth aspect, a display method is provided, which can be applied to an electronic device, and the method may include: shooting a first picture, and saving the first picture, a shooting environment illumination and a first brightness, wherein the shooting environment illumination is the environment illumination when the first picture is shot, and the first brightness is the brightness value of the first grayscale pixel points of the first picture under the shooting environment illumination; when the first picture is displayed in a first scene, the first environment illumination of the first scene is obtained; based on the shooting environment illumination, the first brightness and the first environment illumination, a second brightness is determined, and the second brightness is the brightness value of the first grayscale pixel points of the first picture under the first environment illumination; mapping the brightness value of the first grayscale pixel points of the first picture to the second brightness; and displaying the first picture in the first scene, and the brightness value of the first grayscale pixel points of the first picture is the second brightness.

[0068] Through the method provided in the fourth aspect, the electronic device can display the first picture in the first scene in a manner consistent with the look and feel of the first picture in the shooting environment. That is, the electronic device can display the first picture more realistically.

[0069] In a possible implementation, when the first picture is displayed in the first scene, the method may further include: determining, based on the second brightness, that the brightness value of a pixel point of the second grayscale of the first picture is a third brightness.

[0070] In this way, when the display screen of the electronic device displays the first picture, the brightness values ​​of the pixels of other grayscale values ​​can be determined according to the brightness values ​​of the pixels of the first grayscale of the first picture.

[0071] In a possible implementation, the method may also include: when the electronic device displays the first picture in the second scene, obtaining the second ambient illumination of the second scene; determining a fourth brightness based on the shooting environment illumination, the first brightness and the second ambient illumination, the fourth brightness being the brightness value of the first grayscale pixel points of the first picture under the second ambient illumination; mapping the brightness value of the first grayscale pixel points of the first picture to the fourth brightness; displaying the first picture in the second scene, the brightness value of the first grayscale pixel points of the first picture being the fourth brightness.

[0072] In this way, the brightness values ​​of the pixels of the first grayscale of the first picture displayed by the electronic device under different ambient illuminations are different. The brightness perception of the first picture displayed by the electronic device in any scene is consistent with the brightness perception of the first picture in the shooting environment. Thus, the realism of the first picture displayed by the electronic device can be improved, thereby improving the user experience.

[0073] In a possible implementation, if the second environment illumination is less than the first environment illumination, the fourth brightness is less than the second brightness;

[0074] If the second environment illumination is greater than the first environment illumination, the fourth brightness is greater than the second brightness;

[0075] If the second environment illumination is equal to the first environment illumination, the fourth brightness is equal to the second brightness.

[0076] In this way, when the first picture is displayed, the lower the ambient illumination is, that is, the darker the viewing environment is, the lower the brightness value of the first grayscale pixel of the first picture displayed by the electronic device is. Conversely, when the first picture is displayed, the higher the ambient illumination is, that is, the brighter the viewing environment is, the higher the brightness value of the first grayscale pixel of the first picture displayed by the electronic device is.

[0077] In a fifth aspect, a display method is provided, which can be applied to an electronic device, and the method may include: shooting a high dynamic range picture, and compressing a high dynamic range area in the high dynamic range picture to obtain a compressed picture and compression information, the compression information including a correspondence between a dynamic range and a compression ratio in the compressed picture; storing the compressed picture and the compression information; when the electronic device displays the compressed picture, obtaining the compressed picture and the compression information; based on the compression information, obtaining a correspondence between the brightness of the display screen and the dynamic range of the high dynamic range picture; based on the correspondence between the brightness of the display screen and the dynamic range of the high dynamic range picture, tone mapping the compressed picture to obtain a tone mapped picture, the brightness at a maximum value of the high dynamic range in the tone mapped picture being the maximum brightness supported by the display screen; and displaying the tone mapped picture.

[0078] In this way, when displaying a compressed image, the electronic device can perform tone mapping on the image based on the correspondence between the dynamic range of the image and the display brightness capability of the display screen, and restore the high dynamic range area in the image. In this way, the contrast and details of the high dynamic range area of ​​the displayed image can be increased, and the brightness saturation can be reduced.

[0079] In a possible implementation, obtaining a correspondence between display screen brightness and a dynamic range of a high dynamic range image based on compression information may include: determining a dynamic range in the high dynamic range image based on compression information; determining a correspondence between the dynamic range in the high dynamic range image and display screen brightness, wherein the brightness of a maximum value of the high dynamic range in the high dynamic range image is set as a maximum display screen brightness.

[0080] In this way, the processor can restore the dynamic range of the high dynamic range picture, and can map the dynamic range of the high dynamic range picture with the brightness of the display screen, thereby making full use of the display capability of the display screen and restoring the contrast of the high dynamic range area in the high dynamic range picture.

[0081] In a possible implementation, a multiple of a maximum value of a dynamic range in a compressed image to a maximum value of a standard dynamic range is a first multiple; a multiple of a maximum value of a high dynamic range in a high dynamic range image to a maximum value of a standard dynamic range is a second multiple; a multiple of a maximum value of a dynamic range in a tone-mapped image to a maximum value of a standard dynamic range is a third multiple;

[0082] The first multiple is smaller than the second multiple, and the third multiple is larger than the first multiple and smaller than or equal to the second multiple.

[0083] In this way, the tone-mapped picture displayed by the electronic device can restore the original picture as much as possible, that is, the maximum value of the high dynamic range in the high dynamic range picture and the multiple of the maximum value of the standard dynamic range.

[0084] In a sixth aspect, a shooting and display system is provided, the shooting and display system comprising a shooting device and a display device, wherein:

[0085] The photographing device is used to: take a first picture;

[0086] Store a first picture, a shooting environment illumination and a first brightness, where the shooting environment illumination is the environment illumination when the first picture is shot, and the first brightness is the brightness value of a pixel point of a first grayscale of the first picture;

[0087] Sending the first picture, the shooting environment illumination, and the first brightness to a display device;

[0088] The display device is used to: receive a first picture, a shooting environment illumination and a first brightness, obtain the first environment illumination when displaying the first picture in a first scene, the first environment illumination being the environment illumination of the first scene, determine a second brightness based on the shooting environment illumination, the first brightness and the first environment illumination, the second brightness being the brightness value of a pixel point of a first grayscale of the first picture under the first environment illumination, map the brightness value of a pixel point of a first grayscale of the first picture to a second brightness, display the first picture in the first scene, and the brightness value of a pixel point of a first grayscale of the first picture is the second brightness.

[0089] In this way, for a first picture taken by the photographing device in any environment, the display device can make the brightness of the displayed first picture consistent with the brightness of the first picture in the photographing environment.

[0090] In a possible implementation, the display device may also be used for:

[0091] When the first picture is displayed in the second scene, the second ambient illumination of the second scene is obtained; based on the shooting environment illumination, the first brightness and the second ambient illumination, a fourth brightness is determined, the fourth brightness being the brightness value of the first grayscale pixel points of the first picture under the second ambient illumination; the brightness value of the first grayscale pixel points of the first picture is mapped to the fourth brightness; the first picture is displayed in the second scene, and the brightness value of the first grayscale pixel points of the first picture is the fourth brightness.

[0092] In this way, the brightness values ​​of the pixels of the first grayscale of the first image displayed by the display device under different ambient illuminations are different. The brightness perception of the first image displayed by the display device in any scene is consistent with the brightness perception of the first image in the shooting environment. Thus, the realism of the first image displayed by the display device can be improved, thereby improving the user experience.

[0093] In a possible implementation, the shooting device may be used to: shoot a high dynamic range picture, and compress a high dynamic range area in the high dynamic range picture to obtain a compressed picture and compression information, wherein the compression information includes a correspondence between a dynamic range and a compression ratio in the compressed picture, store the compressed picture and the compression information, and send the compressed picture and the compression information to a display device;

[0094] The display device can be used to: receive compressed images and compression information, and when displaying the compressed images, obtain the correspondence between the brightness of the display screen and the dynamic range of the high dynamic range image based on the compression information, and based on the correspondence between the brightness of the display screen and the dynamic range of the high dynamic range image, perform tone mapping on the compressed image to obtain a tone-mapped image, the brightness at the maximum value of the high dynamic range in the tone-mapped image is the maximum brightness supported by the display screen, and the tone-mapped image is displayed.

[0095] In this way, when the display device displays the compressed image, it can perform tone mapping on the image based on the correspondence between the dynamic range of the image and the display brightness capability of the display screen, and restore the high dynamic range area in the image. In this way, the contrast and details of the high dynamic range area of ​​the displayed image can be increased, and the brightness saturation can be reduced.

[0096] In a possible implementation, a multiple of a maximum value of a dynamic range in a compressed image to a maximum value of a standard dynamic range is a first multiple; a multiple of a maximum value of a high dynamic range in a high dynamic range image to a maximum value of a standard dynamic range is a second multiple; a multiple of a maximum value of a dynamic range in a tone-mapped image to a maximum value of a standard dynamic range is a third multiple;

[0097] The first multiple is smaller than the second multiple, and the third multiple is larger than the first multiple and smaller than or equal to the second multiple.

[0098] In this way, the tone-mapped image displayed by the display device can restore the original image as much as possible, that is, the multiple of the maximum value of the high dynamic range in the high dynamic range image and the maximum value of the standard dynamic range.

[0099] In a possible implementation, the photographing device may be the electronic device provided in the first to third aspects.

[0100] In a possible implementation manner, the display device may be the electronic device provided in the first to third aspects.

[0101] In the seventh aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a computer, the computer implements the method described in any possible implementation method of the first aspect above.

[0102] In an eighth aspect, an embodiment of the present application provides a computer program product. When the computer program product runs on an electronic device, the electronic device executes the method described in any possible implementation manner of the first aspect above. BRIEF DESCRIPTION OF THE DRAWINGS

[0103] Figure 1A It is a schematic diagram of a group of pictures in different shooting environments displayed by an electronic device in the prior art;

[0104] Figure 1B It is a schematic diagram of the display effect of a group of pictures in the prior art;

[0105] Figure 2A It is a schematic diagram of HLG curve in the prior art;

[0106] Figure 2B It is a schematic diagram of the display effect of a picture in the prior art;

[0107] Figure 3A is a schematic diagram of the hardware structure of the electronic device 100 provided in an embodiment of the present application;

[0108] Figure 3B It is a schematic diagram of the software and hardware architecture of the electronic device provided in the embodiment of the present application;

[0109] Figure 3C is a schematic diagram of metadata information of a picture provided in an embodiment of the present application;

[0110] Figure 4 It is a flow chart of a display method provided in an embodiment of the present application;

[0111] Figure 5A is a schematic diagram of a set of inputs and outputs of a visual consistency model provided by an embodiment of the present application;

[0112] Figure 5B is a schematic diagram of an electronic device provided in an embodiment of the present application displaying a picture under an ambient illumination of 1000 lux;

[0113] Figure 5C is a schematic diagram of another set of inputs and outputs of the visual consistency model provided in an embodiment of the present application;

[0114] Figure 5D is a schematic diagram of an electronic device provided in an embodiment of the present application displaying a picture under an ambient illumination of 100 lux;

[0115] Figure 6 This is a schematic diagram of the display effect of the picture of the present application provided in the embodiment of the present application;

[0116] Figure 7 It is a flow chart of a display method provided in an embodiment of the present application;

[0117] Fig. 8A It is a set of curve schematic diagrams provided in the embodiments of the present application;

[0118] Figure 8B It is a schematic diagram of a compression curve and a reduction curve provided in an embodiment of the present application;

[0119] Fig. 9 This is a schematic diagram of the display effect of the picture of the present application provided in the embodiment of the present application;

[0120] Fig.10 It is a schematic diagram of the capture and display system provided in an embodiment of the present application. DETAILED DESCRIPTION

[0121] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0122] The terms used in the following embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to be used as limitations to the present application. As used in the specification and the appended claims of the present application, the singular expressions "one", "a kind of", "said", "above", "the" and "this" are intended to also include plural expressions, unless there is a clear contrary indication in the context. The terms "first" and "second" are only used for descriptive purposes, and cannot be understood as implying or implying relative importance or implicitly indicating the number of indicated technical features. Thus, the features defined as "first" and "second" can explicitly or implicitly include one or more of the features. "First" and "second" etc. are used to distinguish different objects, rather than for describing a specific order of objects. For example, the first object and the second object are used to distinguish different objects, rather than for describing a specific order of objects.

[0123] In the description of the embodiments of the present application, unless otherwise specified, "multiple" means two or more than two. For example, multiple processing units refer to two or more processing units; multiple systems refer to two or more systems.

[0124] In the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or related scheme described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.

[0125] The term "and / or" in this application is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone.

[0126] In order to better understand the technical solution provided by the present application, before describing the technical solution of the present application, firstly, in conjunction with the accompanying drawings, an electronic device 100 with shooting and display functions to which the present application is applicable is described. In the embodiment of the present application, the electronic device 100 may include but is not limited to: a mobile phone, a tablet computer, a smart watch and other devices with shooting and display functions. The embodiment of the present application does not limit the specific form and type of the electronic device 100.

[0127] The term "user interface (UI)" in the following embodiments of the present application refers to a medium interface for interaction and information exchange between an application or operating system and a user, which realizes the conversion between the internal form of information and the form acceptable to the user. The user interface is a source code written in a specific computer language such as Java and extensible markup language (XML). The interface source code is parsed and rendered on an electronic device, and finally presented as content that can be recognized by the user. The commonly used form of user interface is a graphical user interface (GUI), which refers to a user interface related to computer operation displayed in a graphical manner. It can be a visual interface element such as text, icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, widgets, etc. displayed on the display screen of an electronic device.

[0128] Currently, in some examples, in order to obtain a better viewing experience, the electronic device 100 can adjust the brightness of the display screen according to the brightness of the current environment. For example, in a relatively bright environment, the electronic device 100 can adjust the brightness of the display screen to be brighter. In a relatively dark environment, the electronic device 100 can adjust the brightness of the display screen to be darker.

[0129] When the electronic device 100 is shooting, the brightness of the shooting scene in which the electronic device 100 is located will affect the brightness of the shot picture or video. When the shooting scene is bright, the picture or video shot by the electronic device 100 will also look brighter. When the shooting scene is dark, the picture or video shot by the electronic device 100 will also look darker.

[0130] In some scenarios, the brightness of the scene captured by the electronic device 100 or the video may be different from the brightness of the scene in which the user views the captured picture or video. Figure 1A As shown, the electronic device 100 may display a user interface 10A, and the user interface 10A may include a picture 102. The picture 102 is taken in a scene with bright light during the day.

[0131] Optionally, the user interface 10A may further include text information 103a, and the text information 103a may be used to indicate the shooting time (eg, 10:00) and shooting location (eg, xx district, xx city) of the picture 102.

[0132] like Figure 1AAs shown, the electronic device 100 may display a user interface 10B, and the user interface 10B may include a picture 105. The shooting scene of the picture 105 is a scene with dim light at night. Optionally, the user interface 10B may also include text information 103b, and the text information 103b may be used to indicate the shooting time (e.g., 19:00) and shooting location (e.g., xx District, xx City) of the picture 105.

[0133] Optionally, the user interface 10A and the user interface 10B may include a menu 104. The menu 104 may include a sharing control, a collection control, an editing control, a deletion control, and more controls. The sharing control may be used to trigger the sharing of a picture displayed in the current user interface (e.g., the picture 102 displayed in the user interface 10A, or the picture 105 displayed in the user interface 10B). The collection control may be used to trigger the collection of a picture displayed in the current user interface (e.g., the picture 102 displayed in the user interface 10A, or the picture 105 displayed in the user interface 10B) to a collection folder. The editing control may be used to trigger editing functions such as rotation, trimming, adding filters, blurring, etc. of a picture displayed in the current user interface (e.g., the picture 102 displayed in the user interface 10A, or the picture 105 displayed in the user interface 10B). The deletion control may be used to trigger the deletion of a picture displayed in the current user interface (e.g., the picture 102 displayed in the user interface 10A, or the picture 105 displayed in the user interface 10B). The more control may be used to trigger opening of more functions related to the picture currently displayed in the user interface (eg, the picture 102 displayed in the user interface 10A, or the picture 105 displayed in the user interface 10B).

[0134] When the electronic device 100 displays the pictures 102 and 105, the ambient illumination is 700 lux (lux, a unit of illumination), and the peak brightness of the display screen is 130 nit (nit, a unit of brightness). When the electronic device 100 displays the pictures 102 and 105 of different shooting scenes with the same display screen brightness, the picture 102 will be darker than the actual shooting scene, and the picture 105 will be brighter than the actual shooting scene. For example, the grayscale value of pixel 1 in picture 102 is 160, and the grayscale value of pixel 2 in picture 105 is 160. The brightness of pixel 1 will be darker than the brightness of the actual shooting scene, and the brightness of pixel 2 will be brighter than the brightness of the actual shooting scene.

[0135] Another example Figure 1B As shown, the picture 106 is a picture taken during the day, but the brightness of the picture 106 displayed by the electronic device 100 is darker than the shooting scene. The picture 107 is a picture taken at night, but the brightness of the picture 107 displayed by the electronic device 100 is brighter than the brightness of the shooting scene.

[0136] In this way, the image displayed by the electronic device 100 lacks realism, which affects the user experience.

[0137] With the continuous development of electronic device cameras, the electronic device 100 can take high dynamic range (HDR) pictures. Then, the electronic device 100 compresses and saves the taken HDR pictures. When the electronic device 100 displays the HDR picture, the electronic device 100 needs to restore the compressed HDR picture and display the restored HDR picture.

[0138] Currently, the electronic device 100 can use the hybrid log gamma (HLG) standard to compress and restore HDR images. For example, Figure 2A The schematic diagram of HLG curve in the prior art is shown as an example. Figure 2A As shown in the figure, the horizontal axis is the dynamic range of the camera when actually shooting, and the unit is percentage. The maximum brightness corresponding to the standard dynamic range (SDR) is defined as 100%. The brightness range greater than 100% is the brightness range corresponding to HDR. The maximum brightness corresponding to HDR is 5000%, which is 50 times the maximum brightness corresponding to SDR.

[0139] like Figure 2A As shown, the vertical axis represents the standard codeword for picture encoding in the HLG standard, and the unit is nit. In the HLG standard, the maximum brightness corresponding to SDR is encoded as 203nit, and the maximum brightness corresponding to HDR is encoded as 1000nit. In the HLG standard, the maximum brightness corresponding to the encoded HDR is about 5 (1000 / 203≈5) times the maximum brightness corresponding to the encoded SDR.

[0140] like Figure 2A As shown in the dynamic range compression curve 201, when shooting, the maximum brightness corresponding to HDR is 500%, which is 5 times the maximum brightness corresponding to SDR of 100%. When encoding the picture, the maximum brightness corresponding to SDR is encoded as 203nit, and the maximum brightness corresponding to HDR is encoded as 1000nit. The maximum brightness corresponding to the encoded HDR is about 5 times the maximum brightness corresponding to the encoded SDR.

[0141] like Figure 2AAs shown in the dynamic range compression curve 202, when shooting, the maximum brightness corresponding to HDR is 2000%, which is 20 times the maximum brightness corresponding to SDR of 100%. When encoding the picture, the maximum brightness corresponding to SDR is encoded as 203nit, and the maximum brightness corresponding to HDR is encoded as 1000nit. The maximum brightness corresponding to the encoded HDR is about 5 times the maximum brightness corresponding to the encoded SDR.

[0142] like Figure 2A As shown in the dynamic range compression curve 203, when shooting, the maximum brightness corresponding to HDR is 5000%, which is 50 times the maximum brightness corresponding to SDR of 100%. When encoding the picture, the maximum brightness corresponding to SDR is encoded as 203nit, and the maximum brightness corresponding to HDR is encoded as 1000nit. The maximum brightness corresponding to the encoded HDR is about 5 times the maximum brightness corresponding to the encoded SDR.

[0143] like Figure 2A As shown, the dynamic range compression curve 201, the dynamic range compression curve 202, and the part of the dynamic range compression curve 202 where the horizontal axis is greater than 100%, that is, the HDR part, can be called the highlight information part. For the dynamic range compression curve 202 and the dynamic range compression curve 203, when actually taking pictures, the dynamic range of the picture is greater than 5 times, but when encoding the picture, it must be compressed to 5 times the HLG standard. In this way, the slopes of the dynamic range compression curve 202 and the dynamic range compression curve 203 are less than 1. The slope of the dynamic range compression curve corresponding to the picture is less than 1, which means that after the picture is HLG encoded, the dynamic range of the picture is less than the dynamic range actually captured by the camera.

[0144] That is, when shooting an HDR image, the electronic device 100 can store dynamic range information that is much larger than 5 times the reference white. Then, the electronic device 100 can compress the HDR image according to the HLG standard. Finally, when displayed, it will only present a 5-fold brightness dynamic range. In this way, the true brightness dynamic range of the captured HDR image cannot be restored, which will deteriorate the contrast of the originally bright part of the image, thereby affecting the realism of the image. For example, Figure 2B As shown, when storing the picture 210, the electronic device 100 may store the picture 210 according to Figure 2A The HLG curve shown is compressed. When displaying, the electronic device 100 cannot restore the actual brightness dynamic range when the picture 210 is taken. As a result, the contrast between the light part and the wall part in the highlight area 2101 in the picture 210 displayed by the electronic device 100 is not high, and the light color is oversaturated.

[0145] In order to improve the authenticity of the pictures and videos displayed by the electronic device 100, an embodiment of the present application provides a display method, in which, when displaying pictures or videos, the electronic device 100 can determine the brightness of the display screen based on the illumination of the shooting environment of the shooting scene of the picture or video and the brightness of the current viewing environment. The electronic device 100 adjusts the brightness of the display screen to the determined brightness to display the picture or video. When the picture to be displayed is an HDR picture, the electronic device 100 can also restore the highlight information part in the HDR picture according to the brightness capability of the current display screen, presenting the details and contrast of the highlight information part of the HDR picture. Thereby, the authenticity of the pictures or videos displayed by the electronic device 100 is higher.

[0146] Before describing a display method provided in an embodiment of the present application, an exemplary electronic device 100 provided in an embodiment of the present application is first introduced.

[0147] Figure 3A It is a schematic diagram of the hardware structure of the electronic device 100 provided in an embodiment of the present application.

[0148] like Figure 3A As shown, the electronic device 100 may include: a processor 301, an internal memory 302, a camera component 303, a display screen 304, an ambient light sensor 305, etc.

[0149] It is to be understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or separate some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0150] The processor 301 may include one or more processing units, for example, the processor 301 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0151] The controller may be the nerve center and command center of the electronic device 100. The controller may generate an operation control signal according to the instruction operation code and the timing signal to complete the control of fetching and executing instructions.

[0152] The processor 301 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 301 is a cache memory. The memory may store instructions or data that the processor 301 has just used or cyclically used. If the processor 301 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 301, and thus improves the efficiency of the system.

[0153] In some embodiments, the processor 301 may include one or more interfaces. The interface 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.

[0154] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 301 may include multiple groups of I2C buses. The processor 301 may be coupled to the touch sensor, charger, flash, camera assembly 303, etc. through different I2C bus interfaces. For example: the processor 301 may be coupled to the touch sensor through the I2C interface, so that the processor 301 communicates with the touch sensor through the I2C bus interface to realize the touch function of the electronic device 100.

[0155] The I2S interface can be used for audio communication. In some embodiments, the processor 301 can include multiple I2S buses. The processor 301 can be coupled to the audio module via the I2S bus to achieve communication between the processor 301 and the audio module.

[0156] The PCM interface can also be used for audio communication to sample, quantize and encode analog signals.

[0157] The UART interface is a universal serial data bus for asynchronous communication. The bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, the UART interface is generally used to connect the processor 301 with the wireless communication module. For example, the processor 301 communicates with the Bluetooth module in the wireless communication module through the UART interface to implement the Bluetooth function.

[0158] The MIPI interface can be used to connect the processor 301 with peripheral devices such as the display screen 304 and the camera component 303. The MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. In some embodiments, the processor 301 and the camera component 303 communicate via the CSI interface to realize the shooting function of the electronic device 100. The processor 301 and the display screen 304 communicate via the DSI interface to realize the display function of the electronic device 100.

[0159] The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface can be used to connect the processor 301 with the camera assembly 303, the display screen 304, the ambient light sensor 305, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.

[0160] It is understandable that the interface connection relationship between the modules illustrated in the embodiment of the present invention is only a schematic illustration and does not constitute a structural limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

[0161] The electronic device 100 implements the display function through a GPU, a display screen 304, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 304 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 301 may include one or more GPUs, which execute program instructions to generate or change display information.

[0162] The display screen 304 is used to display images, videos, etc. The display screen 304 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light emitting diode or an active-matrix organic light emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device 100 may include 1 or N display screens 304, where N is a positive integer greater than 1.

[0163] The electronic device 100 can realize the shooting function through ISP, camera component 303, video codec, GPU, display screen 304 and application processor.

[0164] The ISP is used to process the data fed back by the camera assembly 303. For example, when taking a photo, the shutter is opened, and the light is transmitted to the camera sensor through the lens. The light signal is converted into an electrical signal, and the camera sensor transmits the electrical signal to the ISP for processing and converts it into an image visible to the naked eye. The ISP can also perform algorithm optimization on the noise, brightness, and color of the image. The ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, the ISP can be set in the camera assembly 303.

[0165] The camera component 303 is used to capture still images or videos. The object generates an optical image through the lens and projects it onto the photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then passes the electrical signal to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV or other format. In some embodiments, the electronic device 100 may include 1 or N camera components 303, where N is a positive integer greater than 1.

[0166] The digital signal processor is used to process digital signals, and can process not only digital image signals but also other digital signals. For example, when the electronic device 100 is selecting a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

[0167] Video codecs are used to compress or decompress digital videos. The electronic device 100 may support one or more video codecs. Thus, the electronic device 100 may play or record videos in a variety of coding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0168] NPU is a neural network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between neurons in the human brain, it can quickly process input information and can also continuously self-learn. Through NPU, applications such as intelligent cognition of electronic device 100 can be realized, such as image recognition, face recognition, voice recognition, text understanding, etc.

[0169] The internal memory 302 can be used to store computer executable program codes, which include instructions. The processor 301 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 302. The internal memory 302 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, applications required for at least one function (such as face recognition function, fingerprint recognition function, mobile payment function, etc.), etc. The data storage area may store data created during the use of the electronic device 100 (such as face information template data, fingerprint information template, etc.), etc. In addition, the internal memory 302 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc.

[0170] The ambient light sensor 305 is used to sense the brightness of the ambient light. The electronic device 100 can adaptively adjust the brightness of the display screen 304 according to the sensed brightness of the ambient light. The ambient light sensor 305 can also be used to automatically adjust the white balance when taking pictures.

[0171] The electronic device 100 may have Figure 3A More or fewer components may be shown, two or more components may be combined, or there may be a different configuration of components. Figure 3A The various components shown in the EMBODIMENTS 2000 may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application specific integrated circuits.

[0172] For a better understanding Figure 3A The software structure of the electronic device 100 is shown, and the software structure of the electronic device 100 is described below. Before describing the software structure of the electronic device 100, the architecture that can be adopted by the software system of the electronic device 100 is first described.

[0173] Specifically, in actual applications, the software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a micro-kernel architecture, a micro-service architecture, or a cloud architecture.

[0174] In addition, it is understandable that the software systems currently used by mainstream electronic devices include but are not limited to Windows systems, Android systems, and iOS systems. For ease of explanation, the present application embodiment takes the layered Android system as an example to exemplify the software structure of the electronic device 100.

[0175] In addition, the subsequent camera request processing method provided in the embodiment of the present application is also applicable to other systems in specific implementation.

[0176] Figure 3B A schematic diagram of the software and hardware architecture of an electronic device 100 provided in an embodiment of the present application is shown.

[0177] like Figure 3B As shown, the software and hardware architecture of the electronic device 100 includes a software system and a hardware layer that implements related shooting (for example, previewing, taking pictures, recording videos, etc.) and display together with the software structure. Among them, the layered architecture divides the software system of the electronic device 100 into several layers, and each layer has a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the system is divided into four layers, from top to bottom, namely, the application layer (application layer), the framework layer (framework layer, FWK), the hardware abstraction layer (hardware abstraction layer, HAL), and the drive layer (drive layer).

[0178] The application layer can include a series of application packages. Figure 3B As shown, the application package may include a camera application and a gallery application.

[0179] Optionally, the application package may also include calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message and other application programs (also referred to as applications). This embodiment of the present application does not limit this.

[0180] The framework layer provides an application programming interface (API) and a programming framework for the application packages of the application layer. The framework layer includes some predefined functions.

[0181] like Figure 3B As shown, the framework layer may include a camera service module, a picture / video metadata management module, and a display engine. Among them, the camera service module can receive a camera request issued by a camera application, and send the camera request issued by the camera application to the hardware abstraction layer. In an embodiment of the present application, the camera request issued by the camera application includes but is not limited to a preview request, a photo request, a video recording request, and the like. The preview request is used to request a preview of the picture captured by the camera component of the electronic device 100 in the camera application. The photo request can be used to request the camera component of the electronic device 100 to take a picture and save the picture taken by the camera component. The video recording request is used to request the camera component of the electronic device 100 to take a video and save the video taken by the camera component.

[0182] In some examples, a picture may also be referred to as an image frame, which is not limited in the embodiments of the present application.

[0183] In some possible implementations, the camera service module may also obtain the hardware abstraction layer to upload pictures or videos. Then, the camera service module may transmit the obtained pictures or videos to the picture / video metadata management module.

[0184] In some other possible implementations, the camera service module can obtain the storage address of the picture or video taken according to the camera request uploaded by the hardware abstraction layer. Then, the camera service module can send the storage address of the picture or video to the picture / video metadata management module.

[0185] The picture / video metadata management module can be used to receive pictures or videos sent by the camera service module. Then, the picture / video metadata management module can save the metadata of the picture or video together with the picture in a database of the electronic device 100 for storing pictures and videos.

[0186] Take pictures as an example, Figure 3CAs shown, the metadata information of the picture may include metadata basic information and metadata extended information. Among them, the metadata basic information of the picture may include but is not limited to the shooting time of the picture and the uniform resource locator (URL). The metadata extended information of the picture may include but is not limited to: one or more of the illumination of the shooting environment, compression information, maximum dynamic range, face information / blue sky information, AI recognition information, category information, color temperature information, highlight color information and noise information. Among them, the illumination of the shooting environment is the brightness of the environment photographed by the camera component when taking pictures. The compression information is used to record the correspondence between the initial brightness value of the high dynamic range area in the HDR picture and the compressed brightness value. The highest dynamic range refers to the maximum value of the brightness in the picture. Face information / blue sky information can be used to indicate whether there is a face / blue sky in the picture. AI recognition information can be used to indicate information identified from the content of the picture, for example, the scene in the picture (such as day, night, scenery, indoor, outdoor, etc.), the subject (such as plants, animals, people, objects, food, etc.), the position of the subject in the picture, etc. Category information can be used to indicate the classification of the picture, for example, landscape photos, portrait photos, food photos, etc. Color temperature information can be used to describe the color temperature value of the image. Highlight color information can be used to describe the color value of the high dynamic range area in the image. Noise information is used to indicate the pixels in the image that have noise.

[0187] Exemplarily, the first field in the metadata information can be used to describe the shooting time of the picture. The second field in the metadata information can describe the URL of the picture. The third field in the metadata information can be used to describe the illumination of the shooting environment of the picture. The fourth field in the metadata information can be used to describe the compression information of the picture. The fifth field in the metadata information can be used to describe the highest dynamic range of the picture. The sixth field in the metadata information can be used to describe the face information or blue sky information contained in the picture. For example, when the sixth field takes a value of 0, it means that the picture contains a face; when the sixth field takes a value of 1, it means that the picture contains a blue sky. The seventh field in the metadata information can be used to describe the AI ​​recognition information of the picture. The eighth field in the metadata information can be used to describe the type information of the picture. The ninth field in the metadata information can be used to describe the color temperature information of the picture. The tenth field in the metadata information can be used to describe the highlight color information of the picture. The eleventh field in the metadata information can be used to describe the noise information of the picture.

[0188] like Figure 3BAs shown, the display engine may include a tone mapping module and a backlight control module. The tone mapping module may be used to perform tone mapping on the compressed HDR image to be displayed during display, and map the compressed brightness value of the high dynamic range area in the HDR image to the brightness value before compression (i.e., the initial brightness value). The backlight control module may be used to control the brightness of the display screen.

[0189] In some embodiments, the framework layer may also be referred to as an application framework layer.

[0190] The hardware abstraction layer HAL is an interface layer located between the application framework layer and the driver layer, providing a virtual hardware platform for the operating system.

[0191] The hardware abstraction layer HAL may include a camera hardware abstraction layer, which may be used to receive a camera request from the framework layer and send the camera parameters in the camera request to the camera component through the driver layer.

[0192] Optionally, the camera hardware abstraction layer may store the image or video acquired by the camera component into a buffer address corresponding to the camera request, and send the buffer address to the camera service module in the framework layer.

[0193] In the embodiment of the present application, taking a picture as an example, the camera request corresponding to the picture refers to a camera request that includes the camera parameters for obtaining the picture. That is, the camera can obtain the picture according to the camera parameters in the camera request. Exemplarily, the camera obtains picture 1 according to the camera parameters in camera request 1, then camera request 1 can be called the camera request corresponding to picture 1.

[0194] The driver layer is a layer between hardware and software. The driver layer includes drivers for various hardware. The driver layer may include camera drivers and display drivers, etc. Among them, the camera driver is used to drive the image sensors (e.g., image sensor 1, image sensor 2, etc.) of one or more cameras in the camera assembly to capture images and drive the image signal processor to pre-process the image. The display driver is used to drive the display.

[0195] The hardware layer may include a camera component, an image signal processor (ISP), an ambient light sensor, a display, and the like. The camera component may include one or more image sensors of a camera (e.g., image sensor 1, image sensor 2, and the like). Optionally, the camera component may also include a time of flight (TOF) sensor, a multispectral sensor, and the like. The image signal processor may be used to process the images captured by the camera component. The display may be used to display the images sent by the camera application. The ambient light sensor may be used to sense the ambient light brightness and send the sensed ambient light brightness to the backlight control module. Optionally, the ambient light sensor may also send the sensed ambient light brightness to the image / video metadata management module.

[0196] In the embodiment of the present application, the application that can be used to take pictures in the electronic device 100 may not be limited to the camera application. Taking the camera application as an example, the photo-taking process of the electronic device 100 may include: when the camera application responds to the user's photo-taking operation, the camera hardware abstraction layer may send a camera request through the camera service module. The camera hardware abstraction layer may send the camera parameters in the camera request to the camera component through the camera driver. The camera component may obtain the picture according to the camera parameters. Optionally, the camera module may send the obtained picture to the image signal processor. The image signal processor may process the picture, for example, remove noise from the picture, perform white balance on the picture, etc. The image signal processor may upload the processed picture to the camera hardware abstraction layer through the camera driver. Then, the camera hardware abstraction layer may upload the processed picture to the camera service module. The camera service module may upload the picture to the camera application, and the camera application may display the picture in the preview interface.

[0197] The camera service module can also send the processed picture to the picture / video metadata management module. The picture / video metadata management module can obtain the metadata information and the picture and save it in a picture file.

[0198] In an embodiment of the present application, the application that can display pictures or videos in the electronic device 100 may not be limited to the gallery application. Taking the gallery as an example, the process of displaying pictures by the electronic device 100 may include: when the gallery application responds to the user's operation of displaying picture 1, it may obtain metadata information such as the illumination of the shooting environment of the shooting scene of picture 1 and highly compressed information from the picture / video metadata management module. Then, the gallery application may send metadata information such as the illumination of the shooting environment of the shooting scene of picture 1 and highly compressed information to the display engine. The tone mapping module in the display engine may restore the brightness of the compressed high dynamic range in picture 1 based on the compression information to obtain the restored picture 1. The backlight control module in the display engine may determine the brightness of the picture displayed on the display screen based on the illumination of the shooting environment of the shooting scene of picture 1 and the current viewing environment brightness. When displaying the picture, the backlight control module may set the brightness of each pixel in the picture according to the determined brightness of the picture. For details on how the electronic device 100 specifically adjusts the brightness of the display screen according to the illumination of the shooting environment of the shooting scene of the picture and the brightness of the viewing environment, please refer to the following description. Figure 4 Regarding how the electronic device 100 specifically restores the brightness of the compressed high dynamic range in the picture 1 based on the compression information to obtain the restored picture 1, please refer to the following description of Figure 7 The description of is not repeated here.

[0199] Based on the hardware structure and software framework of the above-mentioned electronic device 100, an embodiment of the present application provides a display method. Figure 4 The flowchart of a display method provided by an embodiment of the present application is exemplarily shown. Figure 4 As shown, a display method provided by an embodiment of the present application may include the following steps:

[0200] S401. The electronic device 100 takes picture 1 and saves picture 1, shooting environment illumination, and brightness 1. The shooting environment illumination is the environment illumination when picture 1 is taken, and brightness 1 is the brightness value of the pixel point of the first grayscale of picture 1 under the shooting environment illumination.

[0201] The electronic device 100 can obtain the picture 1 in response to the user's photographing operation. When obtaining the picture 1, the electronic device 100 can also obtain the illumination of the shooting environment of the shooting scene of the picture 1.

[0202] In a possible implementation, the electronic device 100 may include: Figure 3A The ambient light sensor 305 shown in FIG. The electronic device 100 can obtain the illumination of the shooting environment of the shooting scene of the picture 1 through the ambient light sensor 305 .

[0203] Optionally, in another possible implementation, the electronic device 100 may determine the illumination of the shooting environment of the picture 1 and the shooting scene according to one or more of the sensitivity, aperture value, and exposure time of the camera component.

[0204] In another possible implementation, the electronic device 100 may also determine the illumination of the shooting environment of the shooting scene of the picture 1 according to an algorithm for calculating the ambient brightness. Exemplarily, the algorithm for calculating the ambient brightness may be a neural network model, and the training data of the neural network model includes multiple pictures and the illumination of the shooting environment of the shooting scenes corresponding to the multiple pictures. The electronic device 100 may input the picture 1 into the neural network model, and obtain the illumination of the shooting environment of the shooting scene of the picture 1 output by the neural network model.

[0205] The embodiment of the present application does not limit the method for obtaining the shooting environment illumination of the shooting scene of Picture 1.

[0206] In a possible implementation, the electronic device 100 can save picture 1, and save the shooting environment illumination corresponding to picture 1, and the brightness values ​​corresponding to each grayscale value of picture 1 under the shooting environment illumination. For example, the brightness value of the first grayscale pixel in picture 1 under the shooting environment illumination is brightness 1. Exemplarily, the electronic device 100 can save the shooting environment illumination corresponding to picture 1, and the brightness values ​​corresponding to each grayscale value of picture 1 under the shooting environment illumination in the metadata information corresponding to picture 1. The specific information included in the metadata information of picture 1 can be found in Figure 3C The description in will not be repeated here.

[0207] The metadata information can be stored in various forms:

[0208] 1. The electronic device 100 may store metadata information of the picture 1 in a file for storing the picture 1. For example, the metadata information of the picture 1 is stored in an exchangeable image file (EXIF) format in a file in a Joint Photographic Experts Group (JPEG) format.

[0209] 2. The electronic device 100 may encode the metadata information of the picture 1 into the picture 1 using a specific encoding format.

[0210] The embodiment of the present application does not limit the storage format of the metadata information of the image 1.

[0211] S402 . When the electronic device 100 displays the picture 1 in the scene 1 , the ambient illumination 1 of the scene 1 is obtained.

[0212] The electronic device 100 may display a picture 1 in a scene 1. When the electronic device 100 displays the picture 1 in response to an operation 1 for the picture 1, the electronic device 100 may acquire an ambient illuminance 1 of the current scene 1.

[0213] In a possible implementation, the electronic device 100 may include an ambient light sensor, and the electronic device 100 may detect the ambient illumination 1 through the ambient light sensor.

[0214] Optionally, in another possible implementation, the electronic device 100 may determine the ambient illumination 1 based on the current time, weather, and location. For example, the electronic device 100 may obtain that the current time is 10:00 am, the weather is sunny, and the location is outdoors. Then, based on the current time and location, the electronic device 100 may determine that the current scene 1 is brighter and the value of the ambient illumination 1 is larger, for example, the ambient illumination 1 is 5000 lux. For another example, the electronic device 100 may obtain that the current time is 22:00 pm, the weather is raining, and the location is outdoors. Then, based on the current time and location, the electronic device 100 may determine that the scene 1 is darker and the value of the ambient illumination 1 is smaller, for example, the ambient illumination 1 is 10 lux.

[0215] The embodiment of the present application does not limit how the electronic device 100 specifically obtains the ambient illumination 1 of the scene.

[0216] The electronic device 100 may receive an operation 1 for displaying picture 1 from a user in scene 1. For example, the operation 1 may be a user clicking on a thumbnail of picture 1 in a gallery application. Alternatively, the operation 1 may be a voice command input by the user to the electronic device 100 for displaying picture 1. For example, the voice command may be "display picture 1". The embodiment of the present application does not specifically limit the operation 1.

[0217] In response to the user operation 1, the electronic device 100 can read out the picture 1 and the shooting environment illumination corresponding to the picture 1 from the memory. The shooting environment illumination corresponding to the picture 1 is the environment illumination of the shooting scene when the picture 1 is taken.

[0218] In a possible implementation, the shooting environment illumination corresponding to the picture 1 may be stored in metadata information of the picture 1. The electronic device 100 may obtain the shooting environment illumination corresponding to the picture 1 from the metadata information of the picture 1.

[0219] In another possible implementation, the electronic device 100 does not store the illumination of the shooting environment corresponding to the picture 1, and the picture file of the picture 1 does not contain the illumination of the shooting environment corresponding to the picture 1. The electronic device 100 may be provided with an algorithm for calculating the illumination of the shooting environment. When the input of the algorithm for calculating the illumination of the shooting environment is the picture 1, the output of the algorithm for calculating the illumination of the shooting environment may be the illumination of the shooting environment corresponding to the picture 1.

[0220] S403. The electronic device 100 determines brightness 2 based on the shooting environment illumination, brightness 1 and environment illumination 1, where brightness 2 is the brightness value of the pixel point of the first grayscale of image 1 under environment illumination 1.

[0221] The brightness 1 can be understood as the brightness of the first grayscale pixel of the image 1 viewed by human eyes in the shooting environment. The brightness 1 can be determined based on the illumination of the shooting environment.

[0222] Exemplarily, in a possible implementation, brightness 1=shooting environment illumination / π (" / " represents a division sign).

[0223] The electronic device 100 can determine brightness 2 according to the illumination of the shooting environment, brightness 1, and the brightness of the viewing environment corresponding to the picture 1. Brightness 2 is the brightness value of the pixel points of the first grayscale of the picture 1 under the ambient illumination 1. In this way, the brightness of the pixel points with the grayscale value of the first grayscale in the picture 1 seen by the user in the shooting environment is consistent with the brightness of the pixel points with the grayscale value of the first grayscale in the picture 1 displayed on the display screen in the viewing environment, thereby ensuring that the appearance of the picture 1 in the shooting environment is consistent with that in the viewing environment, that is, the picture 1 displayed on the electronic device 100 has a stronger sense of reality, thereby improving the user experience.

[0224] The electronic device 100 can select a pixel point with a grayscale value of the first grayscale in the picture 1 as a reference point, and first determine the brightness of the pixel point with a grayscale value of the first grayscale displayed on the display screen under the viewing environment. Then, when displaying the picture 1, the electronic device 100 can determine the brightness of the pixel points with different grayscale values ​​in the entire picture based on the brightness of the reference point.

[0225] In a possible implementation, the electronic device 100 may also determine, based on brightness 2, that the brightness value of the pixel point of the second grayscale of the image 1 is brightness 3.

[0226] In a possible implementation, the brightness of a pixel with a grayscale value of the second grayscale in picture 1 (i.e., brightness 3) is the brightness of a pixel with a grayscale value of the first grayscale (i.e., brightness 2) multiplied by a first coefficient. The first coefficient may be equal to the second grayscale divided by the first grayscale.

[0227] Exemplarily, the first grayscale may be 255, and the second grayscale may be 125. That is, the electronic device 100 may use the pixel with a grayscale value of 255 in the picture 1 as a reference point. The electronic device 100 may determine the brightness of the pixel with a grayscale value of 255 in the picture 1 under the viewing environment as brightness 2 according to the illumination of the shooting environment, the brightness of the pixel with a grayscale value of 255 in the picture 1 under the shooting environment (i.e., brightness 1), and the ambient illumination 1. Then, the electronic device 100 may determine the brightness 3 of the pixel with a grayscale value of 125 according to the brightness of the pixel with a grayscale value of 255, and the brightness 3 is approximately half of the brightness 2. When displaying the picture 1, the electronic device 100 may set the brightness of the pixel with a grayscale value of 255 in the picture 1 to brightness 2, and set the brightness of the pixel with a grayscale value of 125 to brightness 3. In this way, the electronic device 100 may determine the brightness of the pixel with each grayscale value in the picture 1 according to the brightness of the pixel with a grayscale value of 255.

[0228] In a possible implementation, a visual consistency model may exist in the electronic device 100, and the input of the visual consistency model may be the illumination of the shooting environment corresponding to the picture 1, brightness 1, and the ambient illumination 1, and the output of the visual consistency model may be brightness 2. In this way, the electronic device 100 may determine, through the visual consistency model, the brightness of the pixel point with the grayscale value of the first grayscale in the picture 1 displayed on the display screen under the viewing environment.

[0229] In some examples, the visual consistency model may also be called a neural network model, a computational model, etc. The embodiment of the present application does not limit the name of the visual consistency model.

[0230] For example, Figure 5A As shown, when the electronic device 100 takes a picture, the illumination of the shooting environment is 7000 lux. The electronic device 100 can obtain the illumination of the shooting environment when shooting. In addition, the electronic device 100 can determine the brightness of the pixel 3 with a grayscale value of 255 in the picture viewed by the human eye under the shooting environment according to the illumination of the shooting environment, that is, the brightness of the pixel 3 with a grayscale value of 255 in the picture displayed on the display screen under the shooting environment is 2000nit. The electronic device 100 can also obtain that the current ambient illumination in the viewing scene 1 is 1000lux. The electronic device 100 can input the shooting environment illumination of 7000lux, the brightness of the pixel 3 with a grayscale value of 255 in the picture displayed on the display screen under the shooting environment, and the ambient illumination of 1000lux into the visual consistency model, and the visual consistency model can output that the brightness of the pixel with a grayscale value of the first grayscale in the picture 1 displayed on the display screen under the viewing environment is 400nit.

[0231] like Figure 5BAs shown, the electronic device 100 can display a picture display interface 500A in a scene with an ambient illumination of 1000 lux, and the picture display interface 500A includes a picture 501. The picture 501 is taken in a shooting scene with a shooting environment illumination of 7000 lux. That is, the electronic device 100 determines that the brightness of the pixel point with a grayscale value of the first grayscale in the picture 1 displayed on the display screen in the viewing environment 1 is 400 nit based on the shooting environment illumination of the picture 501, the brightness of the pixel point 3 with a grayscale value of 255 in the picture displayed on the display screen in the shooting environment, and the ambient illumination. When the electronic device 100 displays the picture 501 in the viewing environment 1, the brightness of the pixel point with a grayscale value of 255 in the picture 501 can be set to 400 nit.

[0232] For example, Figure 5C As shown, when the electronic device 100 takes a picture, the illumination of the shooting environment is 7000 lux. The electronic device 100 can obtain the illumination of the shooting environment when shooting. In addition, the electronic device 100 can determine the brightness of the pixel 3 with a grayscale value of 255 in the picture viewed by the human eye under the shooting environment according to the illumination of the shooting environment, that is, the brightness of the pixel 3 with a grayscale value of 255 in the picture displayed on the display screen under the shooting environment is 2000nit. The electronic device 100 can also obtain that the current ambient illumination under the viewing scene 2 is 100lux. The electronic device 100 can input the shooting environment illumination of 7000lux, the brightness of the pixel 3 with a grayscale value of 255 in the picture displayed on the display screen under the shooting environment, and the ambient illumination of 100lux into the visual consistency model, and the visual consistency model can output that the brightness of the pixel with a grayscale value of the first grayscale in the picture 1 displayed on the display screen under the viewing environment 2 is 150nit.

[0233] like Figure 5D As shown, the electronic device 100 can display a picture display interface 500B in a scene with an ambient illumination of 100 lux, and the picture display interface 500B includes a picture 501. The picture 501 is taken in a shooting scene with a shooting environment illumination of 7000 lux. That is, the electronic device 100 determines that the brightness of the pixel point with a grayscale value of the first grayscale in the picture 1 displayed on the display screen under the viewing environment 2 is 150 nit based on the shooting environment illumination of the picture 501, the brightness of the pixel point 3 with a grayscale value of 255 in the picture displayed on the display screen under the shooting environment, and the viewing environment brightness. When the electronic device 100 displays the picture 501 in the viewing environment 1, the brightness of the pixel point with a grayscale value of 255 in the picture 501 can be set to 150 nit.

[0234] Exemplarily, the input and output of the visual consistency model may be shown in Table 1 below.

[0235] Table 1

[0236]

[0237] As shown in Table 1, when the input of the visual consistency model is: the illuminance of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 1 nit, and the brightness of the viewing environment is 100 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 8 nit.

[0238] As shown in Table 1, when the input of the visual consistency model is: the illumination of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 10 nit, and the brightness of the viewing environment is 100 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 50 nit.

[0239] As shown in Table 1, when the input of the visual consistency model is: the illumination of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 50 nit, and the brightness of the viewing environment is 100 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 200 nit.

[0240] As shown in Table 1, when the input of the visual consistency model is: the illumination of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 100 nit, and the brightness of the viewing environment is 100 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 350 nit.

[0241] As shown in Table 1, when the input of the visual consistency model is: the illumination of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 1 nit, and the brightness of the viewing environment is 1000 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 25 nit.

[0242] As shown in Table 1, when the input of the visual consistency model is: the illumination of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 10 nit, and the brightness of the viewing environment is 1000 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 150 nit.

[0243] As shown in Table 1, when the input of the visual consistency model is: the illumination of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 50 nit, and the brightness of the viewing environment is 1000 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 400 nit.

[0244] As shown in Table 1, when the input of the visual consistency model is: the illumination of the shooting environment is 0 lux, the brightness of the pixel with the first grayscale value in the picture under the shooting environment is 100 nit, and the brightness of the viewing environment is 1000 lux, the output is: the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen under the viewing environment is 700 nit.

[0245] The above Table 1 is only an example, and the embodiment of the present application does not limit the specific input and output of the visual consistency model.

[0246] S404. The electronic device 100 maps the brightness value of the pixel point of the first grayscale in the image 1 to brightness 2.

[0247] When the electronic device 100 determines that in scene 1, the brightness value of the pixel of the first grayscale in picture 1 is brightness 2, the processor in the electronic device 100 can map the brightness value of the pixel of the first grayscale in picture 1 to brightness 2. For example, the electronic device 100 can set the brightness of the pixel of the first grayscale in picture 1 to brightness 1. For example, the picture 1 can be Figure 5B , the brightness of the pixel with a grayscale value of 255 in the picture 501 is set to 400nit. It is understandable that there may be one or more pixels with a grayscale value of the first grayscale in the picture 1, and the embodiment of the present application does not specifically limit the number of pixels with a grayscale value of the first grayscale in the picture 1. The processor of the electronic device 100 may also send the mapping result to the display screen.

[0248] S405. The electronic device 100 displays picture 1 in scene 1, and the brightness of the first grayscale pixel points of picture 1 is brightness 2.

[0249] The electronic device 100 can display the picture 1 through the display screen in the scene 1. The brightness of the pixel points of the first gray scale of the picture 1 displayed by the electronic device 100 is brightness 2.

[0250] In a possible implementation, the display method provided by the embodiment of the present application may also include: when the electronic device 100 displays the picture 1 in the scene 2, the ambient illumination 2 of the scene 2 is obtained; based on the shooting environment illumination, brightness 1 and ambient illumination 2, brightness 4 is determined, and brightness 4 is the brightness value of the first grayscale pixel of the picture 1 under the ambient illumination 2; the brightness value of the first grayscale pixel of the picture 1 is mapped to brightness 4; the picture 1 is displayed in the scene 2, and the brightness value of the first grayscale pixel of the picture 1 is brightness 4. In this way, when the electronic device 100 displays the picture 1 in different viewing scenes, the brightness of the pixel with the first grayscale value in the picture 1 displayed on the display screen of the electronic device 100 is different. For example, Figure 5B and Figure 5D As shown, when the electronic device 100 is in a viewing environment with a brightness of 1000 lux, the brightness of the pixel with a grayscale value of 255 in the picture 501 displayed by the electronic device 100 is 400 nit. When the electronic device 100 is in a viewing environment with a brightness of 100 lux, the brightness of the pixel with a grayscale value of 255 in the picture 501 displayed by the electronic device 100 is 150 nit.

[0251] Through the display method provided in the embodiment of the present application, the electronic device 100 can determine the brightness of the pixel points with a grayscale value of the first grayscale in the picture displayed on the display screen under the viewing environment according to the illumination of the shooting environment of each picture, the brightness of the pixel points with a grayscale value of the first grayscale in the picture under the shooting environment, and the brightness of the viewing environment. In this way, the user views the picture on the electronic device 100, and the perception of the brightness of the pixel points with a grayscale value of the first grayscale in the picture seen by the user is consistent with the perception of the brightness of the pixel points with a grayscale value of the first grayscale in the picture under the shooting environment. That is, the picture displayed by the electronic device 100 has a higher visual consistency than the actual shooting scene of the picture, and the picture looks more real. Thereby, the user experience can be improved.

[0252] For example, Figure 6 The following is a schematic diagram showing the display effect of the picture of this application. Figure 6 As shown, the picture 601 is a picture taken during the day. Figure 1B The picture 106 shown has the same shooting content, and the shooting time of the picture 601 is the same as the shooting time of the picture 106. Through the display method provided by the embodiment of the present application, the brightness of the picture 601 displayed by the electronic device 100 is closer to the brightness of the shooting scene than the brightness of the picture 106.

[0253] like Figure 6 As shown, the picture 602 is a picture taken at night. Figure 1BThe shooting content of the picture 107 shown in FIG. 6 is the same, and the shooting time of the picture 602 is the same as the shooting time of the picture 107. Through the display method provided by the embodiment of the present application, the brightness of the picture 602 displayed by the electronic device 100 is closer to the brightness of the shooting scene than the brightness of the picture 107.

[0254] In the embodiment of this application, Figure 4 The display method shown can be applied to video. The electronic device 100 can be Figure 4 The method shown in performs brightness mapping on each image frame of the video. Exemplarily, when shooting a video, the electronic device 100 can save the video and the shooting environment illumination of each image frame in the video, and the brightness value of the first grayscale pixel in each image frame (for example, brightness 5). When displaying the video, the electronic device 100 can obtain the ambient illumination in the current viewing scene. Then, the electronic device 100 can determine the brightness 6 based on the shooting environment illumination of the first image frame in the video, the brightness value of the first grayscale pixel of the first image frame, and the ambient illumination in the current viewing scene. Brightness 6 is the brightness value of the first grayscale pixel of the first image frame under the ambient illumination of the current viewing scene. Then, the electronic device 100 can map the brightness value of the first grayscale pixel of the first image frame to brightness 6. The electronic device 100 can display the first image frame of the video, and the brightness value of the first grayscale pixel of the first image frame displayed by the electronic device 100 is brightness 6. It can be understood that the electronic device 100 can display each image frame in the video according to the display method of the first image frame, and this application will not repeat it.

[0255] In some scenarios, the electronic device 100 can capture HDR pictures. When the picture captured by the electronic device 100 is an HDR picture, the electronic device 100 will compress the high dynamic range area in the HDR picture when storing it. When displaying, the electronic device 100 will restore the compressed picture according to the brightness capability of the display screen. When the brightness capability of the display screen of the electronic device 100 is lower than the multiple of the dynamic range of the HDR picture, the dynamic range multiple of the HDR picture restored by the electronic device 100 will be lower than the multiple of the dynamic range before compression, resulting in a poor contrast ratio of the brightness in the high dynamic range area of ​​the HDR picture displayed by the electronic device 100. Figure 2ATaking the dynamic range compression curve 203 in as an example, when shooting, the maximum brightness corresponding to HDR is 5000%, which is 50 times the maximum brightness of 100% corresponding to SDR. When encoding the picture, the maximum brightness corresponding to SDR is encoded as 203nit, and the maximum brightness corresponding to HDR is encoded as 1000nit. The maximum brightness corresponding to the encoded HDR is about 5 times the maximum brightness corresponding to the encoded HDR. That is, when shooting an HDR image, the electronic device 100 can store dynamic range information that is much larger than 5 times the reference white. Then, the electronic device 100 can compress the HDR image according to the HLG standard, and finally, when displayed, it will only present a 5-fold brightness dynamic range. In this way, the true brightness dynamic range of the captured HDR picture cannot be restored, which will cause the contrast of the originally bright part of the picture to deteriorate, thereby affecting the realism of the picture.

[0256] The embodiment of the present application provides a display method, which may include: when the electronic device 100 shoots an HDR picture, the electronic device 100 may save the HDR picture and the compression information corresponding to the HDR picture. When the electronic device 100 displays the HDR picture, the HDR picture may be tone mapped according to the display brightness capability of the display screen of the electronic device 100 and the compression information corresponding to the HDR picture to obtain a tone mapped picture. Finally, the electronic device 100 displays the tone mapped picture.

[0257] Figure 7 A display method provided by an embodiment of the present application is exemplarily shown. Figure 7 As shown, a display method provided by an embodiment of the present application may include the following steps:

[0258] S701. The electronic device 100 captures an HDR picture, and compresses a high dynamic range area in the HDR picture to obtain a compressed picture and compression information, where the compression information includes a correspondence between a dynamic range and a compression ratio in the compressed picture.

[0259] The electronic device 100 can take HDR pictures. Generally, considering that different display terminals have different HDR support capabilities and that HDR pictures occupy a relatively large storage space, the electronic device 100 generally compresses the captured HDR pictures before saving them, so that the storage space of the electronic device 100 can be saved, and the HDR pictures can be displayed on display terminals with different display capabilities.

[0260] The electronic device 100 may compress the HDR picture to obtain a compressed picture and compression information. The multiple of the dynamic range of brightness of the compressed picture is smaller than the multiple of the dynamic range of brightness of the HDR picture. For example, Fig. 8AAs shown in (a), the dynamic range compression curve corresponding to the HDR picture can be any one of the dynamic range compression curve 201, the dynamic range compression curve 202 and the dynamic range compression curve 203. Taking the dynamic range compression curve 203 as an example, the maximum brightness corresponding to the HDR picture is 5000%, which is 50 times the maximum brightness 100% corresponding to the SDR. That is, the dynamic range of the HDR picture is multipled by 50 times. After the HDR picture is encoded and compressed, the maximum brightness corresponding to the high dynamic range area in the compressed picture is 1000nit, and the maximum brightness corresponding to the standard dynamic range part is 203nit. The corresponding maximum brightness in the compressed picture is about 5 times the maximum brightness corresponding to the standard dynamic range part. That is, the dynamic range in the compressed picture is multipled by about 5 times.

[0261] The electronic device 100 may store compression information, which may include a correspondence between the dynamic range of the HDR picture and the compression ratio. That is, the compression information may be used to record how the HRD picture is compressed into a compressed picture. Alternatively, the compression information may include a correspondence between the high dynamic range of the HDR picture and the compression ratio.

[0262] In an embodiment of the present application, the corresponding relationship between the dynamic range and the compression ratio of the HDR picture can be saved in the form of a curve. Optionally, the corresponding relationship between the dynamic range and the compression ratio of the HDR picture can exist in the form of a table. This embodiment of the present application is not limited to this.

[0263] For example, the correspondence between the dynamic range and the compression ratio of the HDR picture is saved in the form of a curve. For example, the compression information saved by the electronic device 100 may be a dynamic range compression curve corresponding to the HDR picture, or a compression curve of a high dynamic range area in the HDR picture. For example, the compression information may be a dynamic range compression curve 203, or a highlight information portion in the dynamic range compression curve 203.

[0264] In a possible implementation, the electronic device 100 may store the compression information in the metadata information corresponding to the HDR picture. For example, the compression information may be saved as an extension field in the metadata information. The embodiment of the present application does not limit the storage form of the compression information.

[0265] S702. When the electronic device 100 displays the compressed image, the compressed image and compression information are obtained.

[0266] The electronic device 100 may receive operation 2, which may be used to display the compressed picture. For example, operation 2 may be a user clicking on a thumbnail of the compressed picture in a gallery application of the electronic device 100. Alternatively, operation 2 may be a user inputting a voice command to the electronic device 100 for displaying the compressed picture, for example, the voice command may be "display the compressed picture". The embodiment of the present application does not specifically limit operation 2.

[0267] In response to operation 2, when the electronic device 100 displays the compressed image, the electronic device 100 can obtain the compressed image and compression information.

[0268] S703. The electronic device 100 may obtain a correspondence between the display screen brightness and the dynamic range of the HDR image based on the compression information.

[0269] The electronic device 100 can obtain the correspondence between the display screen brightness and the dynamic range of the HDR picture according to the correspondence between the dynamic range of the compressed picture and the compression ratio.

[0270] In a possible implementation, the electronic device 100 saves the correspondence between the dynamic range and the compression ratio of the compressed image in the form of a curve. The dynamic range of the compressed image can be the horizontal axis and the compression ratio can be the vertical axis. Then, the electronic device 100 can reversely map the curve, that is, the dynamic range of the compressed image is used as the vertical axis and the compression ratio is used as the horizontal axis, and the dynamic range of the HDR image can be parsed. Next, the electronic device 100 maps the dynamic range of the HDR image with the display brightness capability of the display screen according to the display brightness capability of the display screen, and the correspondence between the display brightness capability of the display screen and the dynamic range of the HDR image can be obtained.

[0271] For example, Fig. 8A As shown, the electronic device 100 can save the corresponding relationship between the dynamic range and the compression ratio of HDR in the form of a dynamic compression curve. The corresponding relationship between the dynamic range and the compression ratio of HDR can be as follows: Fig. 8A The electronic device 100 may reversely map the dynamic range compression curve 201 into any one of the dynamic range compression curves 201, 202, and 203 shown in (a) of FIG. Fig. 8A The electronic device 100 can reversely map the dynamic range compression curve 202 into Fig. 8A The electronic device 100 can reversely map the dynamic range compression curve 203 into Fig. 8A Curve 801 shown in (b) of FIG.

[0272] Taking curve 801 as an example, the electronic device 100 can obtain from curve 801 that the maximum brightness corresponding to the HDR area of ​​the HDR picture is 5000%, and the maximum brightness corresponding to the SDR area is 100%. The maximum brightness corresponding to the HDR area in the HDR picture is 50 times the maximum brightness corresponding to the SDR area. The electronic device 100 can make a one-to-one correspondence between the dynamic range of HDR and the display brightness capability of the display screen, and obtain a corresponding relationship between the display brightness capability of the display screen and the dynamic range of the HDR picture.

[0273] Taking curve 801 as an example, the electronic device 100 can obtain from the curve 801 that the maximum brightness corresponding to the HDR area in the HDR picture is 50 times the maximum brightness corresponding to the SDR area. If the maximum brightness of the display brightness capability of the display screen of the electronic device 100 is 500nit, and the SDR brightness that can be displayed is 10nit, then the electronic device 100 has the ability to restore 50 times the dynamic range. The SDR brightness that can be displayed is 10nit. Then, the electronic device 100 can map the HDR maximum brightness corresponding to the display screen and the maximum brightness corresponding to the HDR area in the HDR picture, and map the SDR brightness corresponding to the display screen and the maximum brightness corresponding to the SDR area in the HDR picture. That is, the electronic device 100 can map the maximum brightness of 5000% corresponding to the HDR area in the HDR picture and the maximum brightness of 500nit of the display screen, and map the maximum brightness of 100% corresponding to the SDR area in the HDR picture and the brightness of 10nit of the display screen. In this way, the electronic device 100 can obtain the corresponding relationship between the display brightness capability of the display screen and the dynamic range of the HDR picture. Exemplarily, the corresponding relationship between the display brightness capability of the display screen and the dynamic range of the HDR picture is as follows: Fig. 8A As shown in the curve 804 in (c), the slope of the curve 804 may be 1. The curve 804 can also present a 50-fold dynamic range on the display end, so that the contrast of the highlight area can be better reflected.

[0274] If the electronic device 100 maps the dynamic range of the HDR image to the display brightness capability of the display screen according to the multiple of the dynamic range of the compressed image, then the multiple of the dynamic range of the brightness of the image finally displayed is the same as the multiple of the dynamic range of the compressed image, which will result in poor contrast in the highlight area of ​​the displayed image. Fig. 8A The vertical axis in (a) shows that the dynamic range of the data encoded according to the HLG standard is about 5 times, that is, the dynamic range of the compressed picture is about 5 times. Fig. 8AAs shown in curve 805 shown in (c), the electronic device 100 maps the 50-fold dynamic range of the HDR picture with the 5-fold brightness dynamic range of the display screen. That is, the electronic device 100 can map the maximum brightness of 5000% corresponding to the HDR area in the HDR picture with the maximum brightness of 50nit of the display screen, and map the maximum brightness of 100% corresponding to the SDR area in the HDR picture with the brightness of 10nit of the display screen. In this way, when the pixel point with a brightness of 5000% of the HDR picture is displayed on the display screen, the brightness is 50nit, and when the pixel point with a brightness of 3000% of the HDR picture is displayed on the display screen, the brightness is also 50nit. As a result, the pixel contrast of the high dynamic range area of ​​the HDR picture displayed on the display screen is poor, causing the displayed HDR picture to be distorted. In addition, the display capability of the electronic device 100 is not used.

[0275] S704. The electronic device 100 performs tone mapping on the compressed image based on the correspondence between the display brightness and the dynamic range of the HDR image to obtain a tone-mapped image, in which the brightness at the maximum value of the high dynamic range in the tone-mapped image is the maximum brightness supported by the display.

[0276] The electronic device 100 may perform tone mapping on the compressed image based on the correspondence between the display brightness and the dynamic range of the HDR image. Fig. 8A Taking the correspondence between the display brightness capability and the dynamic range of the compressed image shown in the curve 804 shown in (c) as an example, the electronic device 100 can map the brightness of the pixel with a dynamic range of 5000% in the compressed image to 500nit, and map the brightness of the pixel with a dynamic range of 100% in the compressed image to 10nit. In turn, the electronic device 100 can determine the brightness of each pixel in the compressed image when displayed on the display screen according to the curve 804. In this way, the electronic device 100 can obtain a tone-mapped image. The brightness at the maximum value of the high dynamic range in the tone-mapped image is the maximum brightness supported by the display screen.

[0277] For example, Figure 8B The dynamic range curve corresponding to the compressed image and the dynamic range curve corresponding to the tone-mapped image are exemplarily shown. Figure 8B The compression curve in is the dynamic range curve corresponding to the compressed image. The horizontal axis of the compression curve represents the dynamic range of brightness corresponding to the image before compression (original image), and the vertical axis of the compression curve represents the dynamic range of brightness corresponding to the image after compression. Figure 8BThe restoration curve in is the dynamic range curve corresponding to the tone-mapped image. The horizontal axis of the restoration curve represents the dynamic range of brightness corresponding to the original image, and the vertical axis of the restoration curve represents the dynamic range of brightness corresponding to the tone-mapped image. Figure 8B The dynamic range of the brightness of the original picture, the dynamic range of the brightness of the compressed picture, and the dynamic range of the brightness of the picture after tone mapping shown in can be shown in the following Table 2.

[0278] Table 2

[0279]

[0280] As shown in Table 2, the brightness values ​​of the pixels in the original image range from 0.0 nit to 3.0 nit. The brightness values ​​of the pixels in the compressed image range from 0.0 to 1.0 nit. The brightness values ​​of the pixels in the tone-mapped image range from 0.0 to 3.0 nit.

[0281] As shown in Table 2, the pixel with a brightness value of 0.0 nit in the original image has a brightness value of 0.0 nit in the compressed image; in the image after tone mapping, the brightness value of the pixel is 0.0 nit. The pixel with a brightness value of 0.2 nit in the original image has a brightness value of 0.3 nit in the compressed image; in the image after tone mapping, the brightness value of the pixel is 0.0 nit. Multiple pixels with brightness values ​​of 0.4 nit and 0.6 nit in the original image have brightness values ​​compressed to 0.4 nit in the compressed image; and in the image after tone mapping, the brightness values ​​of the multiple pixels are 0.1 nit and 0.2 nit respectively. The pixel with a brightness value of 0.8 nit in the original image has a brightness value compressed to 0.5 nit in the compressed image; in the image after tone mapping, the brightness value of the pixel is 0.4 nit. There are multiple pixels with brightness values ​​of 0.9 nit and 1.1 nit in the original image. In the compressed image, the brightness values ​​of these multiple pixels are compressed to 0.6 nit. In the image after tone mapping, the brightness values ​​of these multiple pixels are 0.5 nit and 0.7 nit respectively. There are multiple pixels with brightness values ​​of 1.3 nit and 1.5 nit in the original image. In the compressed image, the brightness values ​​of these multiple pixels are compressed to 0.7 nit. In the image after tone mapping, the brightness values ​​of these multiple pixels are 0.9 nit and 1.1 nit respectively. There are multiple pixels with brightness values ​​of 1.7 nit, 1.9 nit and 2.1 nit in the original image. In the compressed image, the brightness values ​​of these multiple pixels are compressed to 0.8 nit. In the image after tone mapping, the brightness values ​​of these multiple pixels are 1.3 nit, 1.5 nit and 1.7 nit respectively. In the original image, the brightness values ​​of multiple pixels are 2.3nit, 2.4nit, and 2.6nit. In the compressed image, the brightness values ​​of these multiple pixels are compressed to 0.9nit. In the image after tone mapping, the brightness values ​​of these multiple pixels are 2.0nit, 2.2nit, and 2.4nit. In the original image, the brightness values ​​of multiple pixels are 2.8nit and 3.0nit. In the compressed image, the brightness values ​​of these multiple pixels are compressed to 1.0nit. In the image after tone mapping, the brightness values ​​of these multiple pixels are 2.7nit and 3.0nit.

[0282] As can be seen from Table 2, the brightness of the tone-mapped image is closer to that of the original image. The contrast between different brightness of the tone-mapped image is also closer to that of the original image.

[0283] S705. The electronic device 100 displays the tone-mapped image.

[0284] The electronic device 100 can display a tone-mapped picture whose dynamic range of brightness is greater than that of the compressed picture and less than or equal to that of the HDR picture (i.e., the original picture).

[0285] Through the display method provided by the embodiment of the present application, when displaying a picture, the electronic device 100 can obtain the compression information of the picture, and determine the corresponding relationship between the dynamic range of the picture's brightness and the display brightness capability of the display screen based on the corresponding relationship between the dynamic range of the picture's brightness and the compression ratio in the compression information. Then, the electronic device 100 can perform tone mapping on the picture based on the corresponding relationship between the dynamic range of the picture and the display brightness capability of the display screen, and restore the area with high dynamic range in the picture. In this way, the contrast and details of the area with high dynamic range (that is, the highlight area in the picture) of the displayed picture can be increased, and the brightness saturation can be reduced.

[0286] For example, Fig. 9 As shown, the electronic device 100 adopts Figure 7 The picture 901 displayed by the display method shown. The shooting environment and shooting content of the picture 901 are the same as Figure 2B Compared with the picture 210, the contrast between the light part and the wall part in the highlight area 9011 in the picture 901 is improved, and the color saturation of the light is reduced. That is, the electronic device 100 displays the original picture according to the prior art, and the picture effect displayed is the picture 210 shown in FIG. Figure 2B The electronic device 100 displays the original image according to the display method provided in the embodiment of the present application, and the displayed image effect is shown in the image 901. The image displayed according to the display method provided in the embodiment of the present application can improve the contrast of the highlight area in the image and reduce the saturation of the highlight area in the image. In this way, the displayed image has a stronger sense of reality, which can improve the user experience.

[0287] In a possible implementation, when taking a photo, the electronic device 100 can infer the illumination of the shooting environment based on the light source information in the shooting environment. For example, the electronic device 100 can detect that the current light is strong, so the electronic device 100 can infer that the illumination of the shooting environment is high. Alternatively, the electronic device 100 can infer that the illumination of the shooting environment corresponding to the picture is high based on the fact that the shooting scene of the picture is daytime. When displaying the picture, the electronic device 100 can enhance the highlight area in the picture and also enhance the saturation of the picture.

[0288] In a possible implementation, the ambient light sensor may not exist in the electronic device 100. The electronic device 100 may determine the type of light source in the current environment based on the image captured by the camera. Then, the electronic device 100 may determine the current ambient brightness based on the light source type. Exemplarily, when the electronic device 100 determines that the light source type is an incandescent lamp based on the image captured by the camera. Generally, the light source rules of incandescent lamps are relatively fixed. In the scene where incandescent lamps are used, the ambient brightness is approximately 500 lux. Therefore, the electronic device 100 can infer that the current ambient brightness is 500 lux based on the light source type being an incandescent lamp.

[0289] In a possible implementation, when displaying a picture, the electronic device 100 adjusts the saturation of the picture based on the illumination of the shooting environment of the picture. Exemplarily, in a possible implementation, the electronic device 100 can determine the saturation of the color of the picture in the viewing environment based on the illumination of the shooting environment of the picture, the saturation of the picture in the shooting environment, and the brightness of the viewing environment. In this way, the saturation of the picture can be kept consistent in the shooting environment and the viewing environment.

[0290] In a possible implementation, when displaying a picture, the electronic device 100 can enhance, or tone map, or color process the picture in different regions according to the relevant information of the picture in the metadata information of the picture, such as the outline, the face, the blue sky, and other information. For example, the picture has a face and a blue sky. Then, when displaying the picture, the electronic device 100 can enhance the color of the blue sky part in the picture to increase the color saturation of the blue sky part, while not processing the face part, so as to retain the details of the face and make the face part more realistic.

[0291] In a possible implementation, when displaying a picture, the electronic device 100 can determine to adjust the brightness of the noise area according to the noise information in the metadata information of the picture, as well as one or more of the viewing environment, the size of the display screen, the viewing distance of the user, and the age of the user. Exemplarily, when there is much noise in the picture, the display screen currently displaying the picture is large, the viewing environment is dark, the viewing distance of the user is short, and the user belongs to a group of people with good vision such as young people or children, then when the electronic device 100 displays the picture, the brightness of the area where the noise is located in the picture can be lowered to a brightness threshold 1. When there is much noise in the picture, the display screen currently displaying the picture is small, the viewing environment is bright, the viewing distance of the user is far, and the user belongs to a group of people with poor vision such as the elderly, then when the electronic device 100 displays the picture, the brightness of the area where the noise is located in the picture can be lowered to a brightness threshold 2. Among them, the brightness threshold 2 is greater than the brightness threshold 1. The specific values ​​of the brightness threshold 1 and the brightness threshold 2 are not limited in the embodiment of the present application.

[0292] In an embodiment of the present application, when displaying a picture, the electronic device 100 may execute the above steps S401-S404, or may only execute steps S701-S705. The electronic device 100 may also execute steps S401-S404 and steps S701-S705 simultaneously. That is, the electronic device 100 may determine the brightness of each pixel in the SDR part of the picture according to steps S401-S404, and then perform tone mapping on the picture according to steps S701-S705 to determine the brightness of the HDR part of the picture. Then, when the electronic device 100 displays the picture on the display screen, the brightness of the SDR part and the brightness of the HDR part of the picture may be set according to the determined brightness of the SDR part and the brightness of the HDR part.

[0293] In a possible implementation, when the picture to be displayed is an SDR picture, the electronic device 100 may display the SDR picture according to steps S401 to S404. When the picture to be displayed is an HDR picture, the electronic device 100 may display the HDR picture according to steps S701 to S705, or simultaneously perform steps S401 to S404 and steps S701 to S705.

[0294] In an embodiment of the present application, the electronic device 100 can perform tone mapping on other parameters of the image according to steps S701 to S705, for example, color saturation, color value of the highlight area, or color value of the face area in the image, color value of the blue sky area in the image, etc., so that the image quality displayed by the electronic device 100 is better.

[0295] Understandably, Figure 7 The display method shown can also be applied to videos. The electronic device 100 compresses the HDR image frame contained in the video to obtain a compressed image frame and image frame compression information. The image frame compression information includes the correspondence between the dynamic range and the compression ratio in the compressed image frame. When the electronic device 100 displays the HDR image frame in the video, the electronic device 100 can obtain the compressed image frame and the image frame compression information. Based on the image frame compression information, the electronic device 100 can obtain the correspondence between the display screen brightness and the dynamic range of the HDR image frame. Based on the correspondence between the display screen brightness and the dynamic range of the HDR image frame, the electronic device 100 performs tone mapping on the compressed image frame to obtain a tone mapped image frame, and the brightness at the maximum value of the high dynamic range in the tone mapped image frame is the maximum brightness supported by the display screen. The electronic device 100 can display the tone mapped image frame when displaying the video.

[0296] Fig.10The following is an exemplary illustration of a camera display system 1000 provided in an embodiment of the present application. Fig.10 As shown, the camera display system 1000 may include a camera device 1001 and a display device 1002. Among them:

[0297] The photographing device 1001 may include a camera. The photographing device 1001 may use the camera to take pictures and save the pictures and metadata information of the pictures.

[0298] The display device 1002 may include a display screen. The display device 1002 may display the picture sent by the shooting device 1001 through the display screen.

[0299] In a possible implementation, the display device 1002 may also be used to determine the brightness of the pixel with the first grayscale value in the picture displayed on the display screen under the viewing environment according to the illumination of the shooting environment of the picture, the brightness of the pixel with the first grayscale value in the picture displayed on the display screen under the shooting environment, and the brightness of the current viewing environment. For how the display device 1002 specifically determines the brightness of the pixel with the first grayscale value in the picture displayed on the display screen under the viewing environment according to the illumination of the shooting environment, the pixel with the first grayscale value in the picture displayed on the display screen under the shooting environment, and the brightness of the current viewing environment, reference may be made to the description in the above step S403, which will not be repeated here.

[0300] In a possible implementation, the display device 1002 can also obtain the corresponding relationship between the display brightness capability of the display screen and the dynamic range of the picture taken by the shooting device 1001 according to the corresponding compression information of the picture. Then, the electronic device 100 performs tone mapping on the compressed picture based on the corresponding relationship between the display brightness capability of the display screen and the dynamic range of the picture to obtain a tone-mapped picture. Finally, the display device 1002 can also display the tone-mapped picture. For details, please refer to the description in the above steps S701 to S705, which will not be repeated here.

[0301] The camera display system 1000 can implement any possible implementation method performed by the above-mentioned electronic device 100.

[0302] The shooting device 1001 may be a device with shooting capability, such as a camera, a mobile phone, a tablet, a laptop computer, a watch, etc. The display device 1002 may be a device with display capability, such as a mobile phone, a tablet, a laptop computer, a watch, etc.

[0303] In some examples, the photographing device 1001 can take pictures and display the taken pictures. The photographing device 1001 can also send the taken pictures to other devices, such as the display device 1002.

[0304] In some examples, the display device 1002 also has a shooting function, can take pictures, and display the taken pictures. The display device 1002 can also receive pictures sent by other devices (for example, the shooting device 1001) and display the received pictures.

[0305] The embodiment of the present application does not limit the photographing device 1001 and the display device 1002.

[0306] In the embodiment of the present application, the first picture may be picture 1. The first brightness may be brightness 1, the second brightness may be brightness 2, the third brightness may be brightness 3, and the fourth brightness may be brightness 4. The first scene may be scene 1, and the second scene may be scene 2. The first ambient illumination may be ambient illumination 1, and the second ambient illumination may be ambient illumination 2.

[0307] As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.

[0308] As used in the above embodiments, the term "when..." may be interpreted to mean "if..." or "after..." or "in response to determining..." or "in response to detecting...", depending on the context. Similarly, the phrases "upon determining..." or "if (the stated condition or event) is detected" may be interpreted to mean "if determining..." or "in response to determining..." or "upon detecting (the stated condition or event)" or "in response to detecting (the stated condition or event)", depending on the context.

[0309] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that contains one or more available media integration. The available medium can be a magnetic medium, (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk), etc.

[0310] Those skilled in the art can understand that to implement all or part of the processes in the above-mentioned embodiments, the processes can be completed by computer programs to instruct related hardware, and the programs can be stored in computer-readable storage media. When the programs are executed, they can include the processes of the above-mentioned method embodiments. The aforementioned storage media include: ROM or random access memory RAM, magnetic disk or optical disk and other media that can store program codes.

Claims

1. An electronic device, characterized in that: The electronic device comprises a camera assembly, a display screen, a memory, and a processor, wherein the camera assembly, the display screen, and the memory are coupled to the processor respectively, wherein: The camera assembly is used to: take a first picture; The memory is used to store the first picture, shooting environment illumination and a first brightness, wherein the shooting environment illumination is the environment illumination when the first picture is shot, and the first brightness is the brightness value of a pixel point of a first grayscale of the first picture under the shooting environment illumination; The processor is configured to: when the electronic device displays the first picture in a first scene, obtain a first environmental illumination of the first scene, determine a second brightness based on the shooting environment illumination, the first brightness, and the first environmental illumination, where the second brightness is a brightness value of a pixel point of a first grayscale in the first picture under the first environmental illumination, and map the brightness value of the pixel point of the first grayscale in the first picture to the second brightness; The display screen is used to display the first picture in the first scene, and the brightness value of the pixel points of the first grayscale of the first picture is the second brightness.

2. The electronic device according to claim 1, characterized in that: The processor is further configured to: Based on the second brightness, determine that the brightness value of the pixel point of the second grayscale of the first image is a third brightness.

3. The electronic device according to claim 2, characterized in that: The processor is used to: Determining the illumination of the shooting environment based on the exposure value of the camera assembly; or, The shooting environment illumination is determined based on one or more of weather, time, and location when the first picture is taken.

4. The electronic device according to claim 3, characterized in that: The processor is used to: The first environmental illumination is determined based on one or more of weather, time, and location when the first picture is displayed.

5. The electronic device according to claim 2, characterized in that: The electronic device further includes an ambient light sensor, which is coupled to the processor and configured to: collecting the shooting environment illumination when shooting the first picture; When the electronic device displays the first picture, the first environmental illumination is collected.

6. The electronic device according to any one of claims 1 to 5, characterized in that: The processor is configured to: when the electronic device displays the first picture in a second scene, obtain a second environmental illumination of the second scene, determine a fourth brightness based on the shooting environment illumination, the first brightness, and the second environmental illumination, the fourth brightness being a brightness value of a pixel point of the first grayscale of the first picture under the second environmental illumination, and map the brightness value of the pixel point of the first grayscale of the first picture to the fourth brightness; The display screen is used to display the first picture in the second scene, and the brightness value of the pixel points of the first grayscale of the first picture is the fourth brightness.

7. The electronic device according to claim 6, characterized in that: If the second ambient illuminance is lower than the first ambient illuminance, the fourth brightness is lower than the second brightness; If the second ambient illuminance is greater than the first ambient illuminance, the fourth brightness is greater than the second brightness; If the second ambient illumination is equal to the first ambient illumination, the fourth brightness is equal to the second brightness.

8. An electronic device, characterized in that: The electronic device comprises a camera assembly, a display screen, a memory, and a processor, wherein the camera assembly, the display screen, and the memory are coupled to the processor respectively, wherein: The camera assembly is used to: take a high dynamic range picture, and compress a high dynamic range area in the high dynamic range picture to obtain a compressed picture and compression information, wherein the compression information includes a correspondence between a dynamic range and a compression ratio in the compressed picture; The memory is used to: store the compressed picture and the compression information; The processor is used to: when the electronic device displays the compressed picture, obtain the compressed picture and the compression information, obtain the corresponding relationship between the brightness of the display screen and the dynamic range of the high dynamic range picture based on the compression information, and perform tone mapping on the compressed picture based on the corresponding relationship between the brightness of the display screen and the dynamic range of the high dynamic range picture to obtain a tone mapped picture, wherein the brightness at the maximum value of the high dynamic range in the tone mapped picture is the maximum brightness supported by the display screen; The display screen is used to display the tone-mapped picture.

9. The electronic device according to claim 8, characterized in that: The processor is used to: Determining a dynamic range in the high dynamic range picture based on the compression information; A corresponding relationship between the dynamic range in the high dynamic range picture and the brightness of the display screen is determined, wherein the brightness of the maximum value of the high dynamic range in the high dynamic range picture is set as the maximum brightness of the display screen.

10. The electronic device according to claim 9, characterized in that: The multiple of the maximum value of the dynamic range in the compressed picture to the maximum value of the standard dynamic range is a first multiple; the multiple of the maximum value of the high dynamic range in the high dynamic range picture to the maximum value of the standard dynamic range is a second multiple; the multiple of the maximum value of the dynamic range in the tone mapped picture to the maximum value of the standard dynamic range is a third multiple; The first multiple is smaller than the second multiple, and the third multiple is larger than the first multiple and smaller than or equal to the second multiple.

11. A display method, characterized in that: Applied to electronic equipment, the method comprises: Taking a first picture, and saving the first picture, shooting environment illumination, and a first brightness, wherein the shooting environment illumination is the environment illumination when the first picture is taken, and the first brightness is the brightness value of a pixel point of a first grayscale of the first picture under the shooting environment illumination; When the first picture is displayed in a first scene, obtaining a first ambient illumination of the first scene; Determine a second brightness based on the shooting environment illumination, the first brightness, and the first environment illumination, where the second brightness is a brightness value of a pixel point of the first grayscale of the first picture under the first environment illumination; Mapping the brightness value of the pixel point of the first grayscale of the first picture to the second brightness; The first picture is displayed in the first scene, and the brightness value of the pixel points of the first grayscale of the first picture is the second brightness.

12. The method according to claim 11, characterized in that When displaying the first picture in the first scene, the method further includes: Based on the second brightness, determine that the brightness value of the pixel point of the second grayscale of the first image is a third brightness.

13. The method according to claim 12, characterized in that The method further comprises: When the electronic device displays the first picture in a second scene, acquiring a second ambient illumination of the second scene; Determine a fourth brightness based on the shooting environment illumination, the first brightness, and the second environment illumination, where the fourth brightness is a brightness value of a pixel point of the first grayscale of the first picture under the second environment illumination; Mapping the brightness value of the pixel point of the first grayscale of the first picture to the fourth brightness; The first picture is displayed in the second scene, and the brightness value of the pixel point of the first gray scale of the first picture is the fourth brightness.

14. The method according to claim 13, characterized in that If the second ambient illuminance is lower than the first ambient illuminance, the fourth brightness is lower than the second brightness; If the second ambient illuminance is greater than the first ambient illuminance, the fourth brightness is greater than the second brightness; If the second ambient illumination is equal to the first ambient illumination, the fourth brightness is equal to the second brightness.

15. A display method, characterized in that: Applied to electronic equipment, the method comprises: Taking a high dynamic range picture, and compressing a high dynamic range region in the high dynamic range picture to obtain a compressed picture and compression information, wherein the compression information includes a correspondence between a dynamic range and a compression ratio in the compressed picture; Storing the compressed image and the compression information; When the electronic device displays the compressed image, acquiring the compressed image and the compression information; Based on the compression information, obtaining a correspondence between display screen brightness and a dynamic range of the high dynamic range image; Based on the correspondence between the brightness of the display screen and the dynamic range of the high dynamic range picture, tone mapping is performed on the compressed picture to obtain a tone-mapped picture, wherein the brightness at the maximum value of the high dynamic range in the tone-mapped picture is the maximum brightness supported by the display screen; Display the tone mapped image.

16. The method according to claim 15, characterized in that The obtaining, based on the compression information, a correspondence between display screen brightness and a dynamic range of the high dynamic range image includes: Determining a dynamic range in the high dynamic range picture based on the compression information; A corresponding relationship between the dynamic range in the high dynamic range picture and the brightness of the display screen is determined, wherein the brightness of the maximum value of the high dynamic range in the high dynamic range picture is set as the maximum brightness of the display screen.

17. The method according to claim 16, characterized in that The multiple of the maximum value of the dynamic range in the compressed picture to the maximum value of the standard dynamic range is a first multiple; the multiple of the maximum value of the high dynamic range in the high dynamic range picture to the maximum value of the standard dynamic range is a second multiple; the multiple of the maximum value of the dynamic range in the tone mapped picture to the maximum value of the standard dynamic range is a third multiple; The first multiple is smaller than the second multiple, and the third multiple is larger than the first multiple and smaller than or equal to the second multiple.

18. A camera display system, characterized in that: The shooting and display system includes a shooting device and a display device, wherein: The photographing device is used to: take a first picture, The first picture, shooting environment illumination and first brightness are stored, wherein the shooting environment illumination is the environment illumination when the first picture is shot, and the first brightness is the brightness value of the pixel point of the first grayscale of the first picture. Sending the first picture, the shooting environment illumination, and the first brightness to the display device; The display device is used to: receive the first picture, the shooting environment illumination and the first brightness, obtain the first environment illumination when displaying the first picture in the first scene, the first environment illumination is the environment illumination of the first scene, determine the second brightness based on the shooting environment illumination, the first brightness and the first environment illumination, the second brightness is the brightness value of the pixel points of the first grayscale of the first picture under the first environment illumination, map the brightness value of the pixel points of the first grayscale of the first picture to the second brightness, display the first picture in the first scene, and the brightness value of the pixel points of the first grayscale of the first picture is the second brightness.

19. The system according to claim 18, characterized in that The display device is used for: When displaying the first picture, based on the second brightness, the brightness value of the pixel point of the second grayscale of the first picture is determined to be a third brightness.

20. The system according to claim 19, characterized in that The display device is used for: When the first picture is displayed in a second scene, obtaining a second ambient illumination of the second scene; Determine a fourth brightness based on the shooting environment illumination, the first brightness, and the second environment illumination, where the fourth brightness is a brightness value of a pixel point of the first grayscale of the first picture under the second environment illumination; Mapping the brightness value of the pixel point of the first grayscale of the first picture to the fourth brightness; The first picture is displayed in the second scene, and the brightness value of the pixel points of the first grayscale of the first picture is the fourth brightness.

21. The system according to claim 18, characterized in that The shooting device is used to: shoot a high dynamic range picture, and compress a high dynamic range area in the high dynamic range picture to obtain a compressed picture and compression information, wherein the compression information includes a correspondence between a dynamic range and a compression ratio in the compressed picture, store the compressed picture and the compression information, and send the compressed picture and the compression information to the display device; The display device is used to: receive the compressed image and the compression information, and when displaying the compressed image, obtain the correspondence between the display screen brightness and the dynamic range of the high dynamic range image based on the compression information, and based on the correspondence between the display screen brightness and the dynamic range of the high dynamic range image, perform tone mapping on the compressed image to obtain a tone-mapped image, the brightness at the maximum value of the high dynamic range in the tone-mapped image is the maximum brightness supported by the display screen, and the tone-mapped image is displayed.

22. The system according to claim 21, characterized in that The multiple of the maximum value of the dynamic range in the compressed picture to the maximum value of the standard dynamic range is a first multiple; the multiple of the maximum value of the high dynamic range in the high dynamic range picture to the maximum value of the standard dynamic range is a second multiple; the multiple of the maximum value of the dynamic range in the tone mapped picture to the maximum value of the standard dynamic range is a third multiple; The first multiple is smaller than the second multiple, and the third multiple is larger than the first multiple and smaller than or equal to the second multiple.

23. An electronic device, characterized in that: The electronic device comprises a camera assembly, a display screen, a memory, and a processor, wherein the camera assembly, the display screen, and the memory are coupled to the processor respectively, wherein: The camera assembly is used to: shoot a first video, wherein the first video includes a first image frame; The memory is used to: store the first image frame, a first shooting environment illumination and a first brightness, wherein the first shooting environment illumination is the environment illumination when the first image frame is shot, and the first brightness is the brightness value of a pixel point of a first grayscale of the first image frame under the shooting environment illumination; The processor is configured to: when the electronic device displays the first image frame in a first scene, obtain a first environmental illumination of the first scene, determine a second brightness based on the first shooting environmental illumination, the first brightness, and the first environmental illumination, where the second brightness is a brightness value of a pixel point of a first grayscale in the first image frame under the first environmental illumination, and map the brightness value of the pixel point of the first grayscale in the first image frame to the second brightness; The display screen is used to display the first image frame in the first scene, and the brightness value of the pixel point of the first gray scale in the first image frame is the second brightness.

24. The electronic device according to claim 23, characterized in that: The processor is further configured to: Based on the second brightness, a brightness value of a pixel point of the second grayscale of the first image frame is determined to be a third brightness.

25. The electronic device according to claim 23, characterized in that: The processor is configured to: when the electronic device displays the first image frame in a second scene, obtain a second environmental illumination of the second scene, determine a fourth brightness based on the shooting environment illumination, the first brightness, and the second environmental illumination, the fourth brightness being the brightness value of the pixel point of the first grayscale of the first image frame under the second environmental illumination, and map the brightness value of the pixel point of the first grayscale of the first image frame to the fourth brightness; The display screen is used to display the first image frame in the second scene, and the brightness value of the pixel point of the first gray scale of the first image frame is the fourth brightness.

26. The electronic device according to any one of claims 23 to 25, characterized in that: The first video includes a second image frame; The memory is used to: store the second image frame, a second shooting environment illumination, and a fifth brightness, wherein the second shooting environment illumination is the environment illumination when the second image frame is shot, and the fifth brightness is the brightness value of the pixel point of the first grayscale of the second image frame under the second shooting environment illumination; The processor is configured to: when the electronic device displays the second image frame in the first scene, obtain a first ambient illumination of the first scene, determine a sixth brightness based on the second shooting ambient illumination, the fifth brightness, and the first ambient illumination, the sixth brightness being a brightness value of a pixel point of the first grayscale of the second image frame under the first ambient illumination, and map the brightness value of the pixel point of the first grayscale of the second image frame to the sixth brightness; The display screen is used to display the second image frame in the first scene, and the brightness value of the pixel point of the first gray scale in the second image frame is the sixth brightness.

27. A computer-readable storage medium, characterized in that: The method comprises computer instructions, which, when executed on an electronic device, cause the electronic device to execute the method as claimed in any one of claims 11 to 17.

28. A computer program product, characterized in that The method comprises computer instructions, which, when executed on an electronic device, cause the electronic device to execute the method as claimed in any one of claims 11 to 17.

Citation Information

Patent Citations

  • Image processing method and device

    CN111601048A

  • Image processing method and electronic equipment

    CN117133252A

  • Image display method and electronic equipment

    CN117255163A

  • Image display method, electronic equipment, readable storage medium and chip

    CN117711300A

  • System and method for adaptive tone mapping for high dynamic ratio digital images

    US20190295504A1

Cited By

  • Display method and electronic equipment

    CN120687054A

  • Display method and electronic device

    CN120687054B

  • Display method and electronic device

    WO2026061363A1