Image shooting method and device, electronic device, and storage medium

By metering and adjusting the exposure parameters of the framing screen of the electronic device, the problem of excessive image exposure under the flash is solved, and the recognition rate of the QR code is improved.

CN114727025BActive Publication Date: 2024-12-17BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110014518.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-01-06
Publication Date
2024-12-17
Estimated Expiration
2041-01-06

AI Technical Summary

Technical Problem

In an environment with insufficient light, electronic devices can easily cause excessive exposure of images when turning on the flash, especially in scenes where the subject has strong reflective ability and close distance, such as scanning a QR code, which causes the QR code to be unrecognized. .

Method used

By metering the framing screen, the initial brightness index is determined, and the exposure parameters, especially the target brightness index of the overexposure area, are adjusted according to the index, so that the overexposure area is exposed normally, thereby improving the recognition rate of the QR code.

Benefits of technology

It effectively avoids the QR code recognition failure caused by excessive exposure, and improves the image quality and recognition rate taken in an environment with insufficient light.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114727025B_ABST
    Figure CN114727025B_ABST
Patent Text Reader

Abstract

The present disclosure relates to an image shooting method and device, an electronic device, and a storage medium. Among them, the method can measure the viewfinder screen when the flash of the electronic device is turned on to obtain an initial brightness index used to characterize the overall brightness of the viewfinder screen, and determine the target brightness index that makes the overall exposure of the viewfinder screen tend to be normal based on the initial brightness index. On this basis, based on the target brightness index, the exposure level of the overexposed area in the viewfinder screen, and the area of ​​the viewfinder screen occupied by the overexposed area, a first area target brightness index corresponding to the overexposed area can be determined, and then shooting is performed using the exposure parameters corresponding to the first area target brightness index, so that the area corresponding to the above-mentioned overexposed area in the captured image is exposed normally.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of images, and in particular to an image shooting method and device, an electronic device, and a storage medium. Background Art

[0002] In the related art, electronic devices are usually equipped with flashes in order to take photos normally in low-light environments. On this basis, when the electronic device detects that the light intensity in the environment is weak, it can turn on the flash to fill in the light of the subject, so as to avoid the problem of underexposure of the captured image.

[0003] However, in actual shooting, when the electronic device is shooting with the flash turned on, the image often suffers from overexposure, which is particularly evident in scenes where the subject has strong reflective ability and is close to the electronic device, such as scanning a QR code. Summary of the invention

[0004] The present disclosure provides an image shooting method and device, an electronic device, and a storage medium, which can adjust the exposure parameters used for shooting by lighting a framing screen to avoid the problem of overexposure in the screen.

[0005] According to a first aspect of the present disclosure, there is provided an image capturing method, which is applied to an electronic device, comprising:

[0006] When the flash of the electronic device is turned on, measuring the light of the viewfinder screen of the electronic device to determine an initial brightness index corresponding to the viewfinder screen according to the light measurement result; the initial brightness index is used to represent the overall brightness of the viewfinder screen at present;

[0007] Determining a target brightness index of the framing picture according to the initial brightness index; during the process of adjusting the framing picture to the target brightness index, the whole picture tends to be normally exposed;

[0008] Determine an overexposed area in the framing picture, and determine a first area target brightness index of the overexposed area based on the exposure degree of the overexposed area, the area occupied by the framing picture, and the target brightness index;

[0009] When the flash is turned on, the content in the viewfinder is photographed based on the exposure parameter corresponding to the target brightness index of the first area, so as to obtain an image with normal exposure of the area corresponding to the overexposed area.

[0010] According to a second aspect of the present disclosure, there is provided an image capturing device, which is applied to an electronic device, comprising:

[0011] a light metering unit, which measures light on a viewfinder screen of the electronic device when a flash of the electronic device is turned on, so as to determine an initial brightness index corresponding to the viewfinder screen according to the light metering result; the initial brightness index is used to represent the overall brightness of the viewfinder screen at present;

[0012] A first determining unit determines a target brightness index of the framing picture according to the initial brightness index; when the framing picture is adjusted to the target brightness index, the whole picture tends to be normally exposed;

[0013] a second determining unit, configured to determine an overexposed area in the framing picture, and to determine a first area target brightness index of the overexposed area based on an exposure degree of the overexposed area, an area occupied by the framing picture, and the target brightness index;

[0014] The shooting unit shoots the content in the viewfinder image based on the exposure parameter corresponding to the target brightness index of the first area when the flash is turned on, so as to obtain an image with normal exposure of the area corresponding to the overexposed area.

[0015] According to a third aspect of the present disclosure, there is provided an electronic device, including:

[0016] processor;

[0017] a memory for storing processor-executable instructions;

[0018] The processor implements the method as described in the first aspect by running the executable instructions.

[0019] According to a fourth aspect of the present disclosure, a computer-readable storage medium is provided, on which computer instructions are stored, and when the instructions are executed by a processor, the steps of the method described in the first aspect are implemented.

[0020] In the technical solution disclosed in the present invention, when the electronic device determines that the flash is turned on, it will first measure the light of the electronic device's viewfinder screen to determine the initial brightness index used to characterize the overall brightness of the current viewfinder screen, and then determine the target brightness index that makes the viewfinder screen tend to be exposed normally based on the initial brightness index. On this basis, the first area target brightness index corresponding to the overexposed area in the viewfinder screen can be further determined based on the target brightness index, as well as the exposure level of the overexposed area in the viewfinder screen and the area occupied by the viewfinder screen, and then the subject is photographed based on the exposure parameters corresponding to the first area target brightness index, so that the area corresponding to the overexposed area in the viewfinder screen in the captured image is exposed normally.

[0021] In other words, the present disclosure measures light on the viewfinder where the subject is located when the flash is turned on, and gradually determines the first area target brightness index that makes the overexposed area in the viewfinder exposed to normal based on the light measurement result. Obviously, using the exposure parameter corresponding to the first area target brightness index as a shooting parameter for image shooting can make the area in the captured image that would have been overexposed normally exposed.

[0022] It should be understood that in scenarios such as scanning a QR code in the dark, if the camera is directly photographed with the flash turned on, it is very likely that the area where the QR code is located in the captured image will be overexposed due to the strong reflective ability of the material on which the QR code is printed, thereby making it impossible for the electronic device to recognize the QR code. If the above method is adopted, since in the scenario of scanning a QR code, the area with strong reflectivity in the framing screen is usually the area where the QR code is located, determining the overexposed area in the framing screen by metering is equivalent to obtaining the position of the QR code in the framing screen. It can be seen that in the scenario of scanning a QR code with the flash turned on, through the scheme disclosed in the present invention, the area where the QR code is located can be identified by means of the overexposed area in the framing screen, and the camera is photographed by using exposure parameters that make the area tend to be exposed normally, so that the area where the QR code is located in the captured image is exposed normally, thereby improving the success rate of identifying the QR code. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0024] Figure 1 is a flow chart of an image capturing method shown in an exemplary embodiment of the present disclosure;

[0025] Figure 2 is a flow chart of another image capturing method shown in an exemplary embodiment of the present disclosure;

[0026] Figure 3 is a schematic diagram showing a method of scanning a QR code with a flash turned on, according to an exemplary embodiment of the present disclosure;

[0027] Figure 4 is a flow chart showing a method of determining a regional target brightness index according to an exemplary embodiment of the present disclosure;

[0028] Figure 5 is a block diagram of an image capturing device shown in an exemplary embodiment of the present disclosure;

[0029] Figure 6 is a block diagram of another image capturing device according to an exemplary embodiment of the present disclosure;

[0030] Figure 7It is a schematic structural diagram of an electronic device in an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION

[0031] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0032] The terms used in this disclosure are for the purpose of describing specific embodiments only and are not intended to limit the disclosure. The singular forms of "a", "said" and "the" used in this disclosure and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.

[0033] It should be understood that although the terms first, second, third, etc. may be used in the present disclosure to describe various information, such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the present disclosure, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein may be interpreted as "at the time of image capture" or "when the image is captured" or "in response to determination".

[0034] In the related art, electronic devices are usually equipped with flashes in order to take photos normally in low-light environments. On this basis, when the electronic device detects that the light intensity in the environment is weak, it can turn on the flash to fill in the light of the subject, so as to avoid the problem of underexposure of the captured image.

[0035] In actual applications, the above method is mostly used for long-distance shooting, such as portrait shooting in low light conditions. Therefore, the flash is usually given a higher brightness to effectively fill in the light for the distant subject. However, when the subject is close and / or has strong reflective ability, if the flash is turned on for shooting, the image obtained is likely to be overexposed.

[0036] For example, when scanning a QR code, the QR code is often printed on a plastic material with strong reflective properties, and the user is usually close to the QR code when scanning the QR code, which causes the area where the QR code is located to be overexposed in the image captured by the electronic device with the flash turned on. Obviously, when the area where the QR code is located is overexposed, the electronic device cannot accurately obtain the information on the QR code, which leads to the failure of QR code scanning.

[0037] To this end, the present disclosure proposes an image capturing method to avoid the problem in the related art that the area where the subject is located in the captured image is overexposed due to the subject being close to the electronic device and / or having strong reflective ability.

[0038] Figure 1 An image capturing method is shown as an exemplary embodiment of the present disclosure. The method is applied to electronic equipment. Figure 1 As shown, the method may include the following steps:

[0039] Step 102, when the flash of the electronic device is turned on, measure the viewfinder screen of the electronic device to determine the initial brightness index corresponding to the viewfinder screen according to the light measurement result; the initial brightness index is used to represent the overall brightness of the viewfinder screen.

[0040] The execution subject of the technical solution of the present disclosure may be any type of electronic device, for example, the electronic device may be a smart phone, a tablet computer, etc. It should be understood that any electronic device equipped with a flash and having a shooting function may be used as the electronic device in the present disclosure, and which type of electronic device is used as the execution subject of the technical solution of the present disclosure may be determined by those skilled in the art according to actual needs, and the present disclosure does not limit this.

[0041] Before introducing the technical solution of the present disclosure in detail, it should be stated that the brightness index in the present disclosure is: a comprehensive parameter used to characterize the brightness of the picture. The brightness index can be related to at least one parameter related to brightness, for example, it can be related to exposure parameters such as exposure time and exposure gain. Of course, this example is only illustrative, and the specific parameters related to the brightness index can be determined by those skilled in the art according to actual conditions, and the present disclosure does not limit this.

[0042] During the image capture process, the electronic device usually needs to frame the subject and its background to adjust the shooting parameters according to the framed image. For example, the framing process may include operations such as metering and focusing to ensure that the image captured by the adjusted shooting parameters has normal focus and exposure.

[0043] However, in the related art, the shooting parameters are usually determined based on the overall brightness of the picture. Since the shooting parameters are adjusted from the perspective of the entire picture, if the exposure conditions of various areas in the framing screen vary greatly, such as when shooting a subject with strong reflectivity and / or a close distance with the flash turned on as described above, it is usually difficult to expose all areas of the screen normally. For example, in the above-mentioned scenario of scanning a QR code, since the material printed with the QR code has a strong reflectivity, the area where the QR code is located in the framing screen is overexposed, resulting in a failure in scanning the QR code. In this scenario, what actually needs to be identified is only the overexposed area where the QR code is located, that is, only the area where the QR code is located needs to be exposed normally. In the related art, it is obviously impossible to expose the area where the key information is located normally.

[0044] In view of this, when the flash is turned on, the present disclosure no longer determines the shooting parameters based only on the overall brightness of the framing picture as in the related art; instead, the shooting parameters are determined based on the regional brightness of the overexposed area in the framing picture as the main factor and the overall brightness of the framing picture as the auxiliary factor. Specifically, after the framing picture is metered, a target brightness index that makes the overall exposure of the framing picture tend to be normal is determined based on the metering result, and then based on the target brightness index, the area occupied by the overexposed area and the exposure degree of the overexposed area, a regional target brightness index that makes the exposure of the overexposed area tend to be normal is determined.

[0045] It should be understood that in a scenario similar to the above where the QR code is scanned with the flash turned on, the area where the key information is located is the overexposed area in the viewfinder. Since the first area target exposure index for image shooting finally determined by the present disclosure is to make the overexposed area in the viewfinder exposed normally, it is equivalent to identifying the area where the key information is located by determining the overexposed area through light metering, and then determining the shooting parameters for image shooting according to the exposure condition of the area where the key information is located, so as to achieve the purpose of making the area where the key information is exposed normally.

[0046] In the present disclosure, similar to the related art, an initial brightness index for characterizing the overall brightness of the framing picture is determined based on the overall brightness of the framing picture, and then a target brightness index for making the overall exposure of the framing picture tend to be normal is determined based on the initial brightness index.

[0047] The present disclosure can use any photometry method to measure the framing picture to obtain the initial brightness index corresponding to the framing picture. For example, in one case, a photometry weight can be assigned to each position in the framing picture according to the distance between each position and the picture, wherein the photometry weight of each position is negatively correlated with the "respective distance from the center of the picture", that is, for any position, the closer to the center of the picture, the higher the photometry weight. On this basis, the brightness index of each position in the framing picture can be weightedly calculated based on the photometry weight of each position to obtain the initial brightness index corresponding to the framing picture.

[0048] It should be understood that the present disclosure is aimed at shooting scenarios similar to scanning a QR code to identify key information. Users usually aim the lens at the area where the key information is located, so that the key information is located in the center of the viewfinder. In other words, in this scenario, the overexposed area in the viewfinder is mostly located in the center of the picture. It can be seen that assigning a higher metering weight to the central area of ​​the viewfinder can more accurately identify the overexposed area in the viewfinder, indirectly improving the accuracy of the final determined regional target brightness index for image capture.

[0049] Step 104, determining a target brightness index of the framing picture according to the initial brightness index; when the framing picture is adjusted to the target brightness index, the overall exposure of the picture tends to be normal.

[0050] In the present disclosure, a target brightness index that makes the overall exposure of the picture tend to be normal can also be determined according to the initial brightness index in a variety of ways. For example, a correspondence between several initial brightness index ranges and target brightness indexes can be preset in the electronic device. Then, after determining the initial brightness index corresponding to the framing picture, the target initial brightness index range to which the initial brightness index belongs can be determined from the preset several initial brightness index ranges; and the target brightness index corresponding to the target initial brightness index range is determined as the target brightness index of the framing picture.

[0051] In practical applications, the correspondence between several initial brightness index ranges and target brightness indexes can be determined by those skilled in the art based on their own experience and professional knowledge. Of course, the above examples are all illustrative, and how to determine the target brightness index based on the initial brightness index, and how to preset the correspondence between the initial brightness index range and the target brightness index can be determined by those skilled in the art according to actual needs, and the present disclosure does not limit this.

[0052] Step 106 , determining an overexposed area in the framing image, and determining a first area target brightness index of the overexposed area based on the exposure level of the overexposed area, the area occupied by the framing image, and the target brightness index.

[0053] It should be stated that, although in most cases, the overexposed area in the viewfinder is the area where the key information is located, such as in a scenario similar to the above-mentioned QR code scanning, the area where the entire QR code is located is overexposed in the viewfinder. However, it is also possible that most areas in the QR code are overexposed, but there are areas where some QR codes are located that are not overexposed. In this case, if the image is captured only according to the exposure parameters corresponding to the determined first area target exposure index, other areas will be underexposed, and in the above scenario, the QR code scanning may still fail. Therefore, after the image is acquired through the exposure parameters corresponding to the area target exposure index, the brightness of other areas in the image can be further adjusted to ensure that all areas in the obtained image are exposed normally, thereby avoiding failure in key information recognition.

[0054] Specifically, after the metering of the framing screen is completed, the underexposed area of ​​the framing screen (i.e., the underexposed area) and other areas with exposure levels between the overexposed area and the underexposed area (i.e., the medium-bright area with normal exposure) can be further determined; and the second area target brightness index corresponding to the other area is determined according to the above target brightness index, the area of ​​the framing screen occupied by the other area, and the exposure level of the other area, and the third area target brightness index corresponding to the underexposed area is determined according to the above target brightness index, the area of ​​the framing screen occupied by the underexposed area, and the exposure level of the underexposed area. In the process of adjusting the other area to the second area target brightness index, the other area tends to be normally exposed; in the process of adjusting the underexposed area to the third area target brightness index, the underexposed area tends to be normally exposed. On this basis, the brightness of the area corresponding to the other area in the captured image can be adjusted based on the second area target brightness index, and the brightness of the area corresponding to the underexposed area in the captured image can be adjusted based on the third area target brightness index, so that the entire image after adjustment is normally exposed.

[0055] In actual operation, the first ratio of the target brightness index of the second area to the target brightness index of the first area and the second ratio of the target brightness index of the third area to the target brightness index of the first area can be calculated respectively, and the brightness values ​​of each pixel in other areas can be amplified according to the first ratio, and the brightness values ​​of each pixel in the underexposed area can be amplified according to the second ratio.

[0056] Step 108 , when the flash is turned on, the content in the viewfinder is photographed based on the exposure parameter corresponding to the target brightness index of the first area, to obtain an image with normal exposure of the area corresponding to the overexposed area.

[0057] In the present disclosure, the reasons for overexposure of the subject may be due to the strong reflective ability of the subject itself and the close distance to the electronic device, as well as the strong brightness of the flash. Therefore, the brightness of the flash can also be controlled to avoid overexposure of the subject. For example, when the flash is turned on, the electronic device can determine which application the flash is called by, and control the flash to emit light through control signals of different intensities according to whether the called application is a third-party application. Among them, when it is determined that the flash is turned on by being called by a third-party application, the brightness of the flash is controlled by a first control signal; when it is determined that the flash is not turned on by being called by a third-party application, the brightness of the flash is controlled by a second control signal. Among them, the intensity of the first control signal is weaker than the intensity of the second control signal.

[0058] It should be understood that if an electronic device uses a third-party application to call the flash, it is mostly in a scenario similar to the above-mentioned scanning of a QR code to identify key information, and it is very easy for the captured image to have a large area of ​​overexposure. Therefore, when it is determined that the electronic device is called by a third-party application, reducing the signal strength of the flash brightness can reduce the overexposure of the viewfinder from the hardware level, thereby alleviating the pressure of subsequent image capture and image adjustment.

[0059] Of course, in addition to controlling the signal strength by identifying whether the application that calls the flash is a third-party application, the signal strength can also be controlled directly based on the business being executed by the electronic device. Specifically, when the flash is called, the business being executed by the electronic device can be determined to determine the control signal strength for controlling the brightness of the flash based on the business. In the case where the business being executed by the electronic device is used to implement the code scanning function, the brightness of the flash is controlled by a third control signal; in the case where the business being executed by the electronic device is not used to implement the code scanning function, the brightness of the flash is controlled by a fourth control signal, wherein the strength of the third control signal is weaker than the strength of the fourth control signal.

[0060] In addition to the above steps, the present disclosure also includes a process of how to obtain a framing picture. In this embodiment, a plurality of correspondences between control signal strengths and framing parameters can be preset. Then, after determining the current control signal strength for controlling the brightness of the flash, the framing parameters corresponding to the current control signal strength can be obtained from the preset plurality of correspondences as the initial framing parameters used for this framing.

[0061] This method is equivalent to determining the initial framing parameters based on the brightness of the flash, so that the obtained framing picture is as close to normal exposure as possible, thereby reducing the difficulty of subsequent image shooting and adjustment.

[0062] In the present disclosure, it is also emphasized that during the process from when the flash is called to when the image is captured, the flash can be either always on or intermittently on, and it is sufficient to ensure that the flash is on when capturing the image and measuring the light. For example, the flash can flash once when acquiring the viewfinder image for light measurement, and flash again when capturing based on the first area target brightness index.

[0063] It can be seen from the above technical solution that when the electronic device determines that the flash is turned on, it will first measure the light of the electronic device's viewfinder screen to determine the initial brightness index used to characterize the overall brightness of the current viewfinder screen, and then determine the target brightness index that makes the viewfinder screen tend to be exposed normally based on the initial brightness index. On this basis, the first area target brightness index corresponding to the overexposed area in the viewfinder screen can be further determined based on the target brightness index, as well as the exposure level of the overexposed area in the viewfinder screen and the area occupied by the viewfinder screen, and then the subject is photographed based on the exposure parameters corresponding to the first area target brightness index, so that the area corresponding to the overexposed area in the viewfinder screen in the captured image is exposed normally.

[0064] In other words, the present disclosure measures light on the viewfinder where the subject is located when the flash is turned on, and gradually determines the first area target brightness index that makes the overexposed area in the viewfinder exposed to normal based on the light measurement result. Obviously, using the exposure parameter corresponding to the first area target brightness index as a shooting parameter for image shooting can make the area in the captured image that would have been overexposed normally exposed.

[0065] It should be understood that in scenarios such as scanning a QR code in the dark, if the camera is directly photographed with the flash turned on, it is very likely that the area where the QR code is located in the captured image will be overexposed due to the strong reflective ability of the material on which the QR code is printed, thereby making it impossible for the electronic device to recognize the QR code. If the above method is adopted, since in the scenario of scanning a QR code, the area with strong reflectivity in the framing screen is usually the area where the QR code is located, determining the overexposed area in the framing screen by metering is equivalent to obtaining the position of the QR code in the framing screen. It can be seen that in the scenario of scanning a QR code with the flash turned on, through the scheme disclosed in the present invention, the area where the QR code is located can be identified by means of the overexposed area in the framing screen, and the camera is photographed by using exposure parameters that make the area tend to be exposed normally, so that the area where the QR code is located in the captured image is exposed normally, thereby improving the success rate of identifying the QR code.

[0066] Furthermore, the present disclosure can also determine a third area target brightness index and a second area target brightness index corresponding to the underexposed area and the medium-bright area in the framing screen based on the metering results of the framing screen, so as to adjust the brightness of the areas corresponding to the underexposed area and the medium-bright area in the captured image according to the two area target brightness indices, respectively, thereby avoiding the situation where a large number of underexposed areas are present in the obtained image due to the image being captured only by the area target brightness index obtained according to the exposure condition of the overexposed area.

[0067] It should be understood that the first area target brightness index is a target brightness index obtained in order to make the originally overexposed area exposed normally. If an image is captured using this area target brightness index, the brightness of other areas outside the originally overexposed area will inevitably be darker, even if the originally normally exposed area is underexposed, making the originally underexposed area even more underexposed. If, in the above-mentioned scenario of scanning a QR code, part of the QR code is located outside the originally overexposed area, the part of the QR code in the captured image may not be recognized due to underexposure. It can be seen that adjusting the captured image by determining the second area target brightness index and the third area target brightness index can effectively avoid the problem of recognition failure caused by underexposure of key information in the image.

[0068] Furthermore, the present disclosure can also identify the application that calls the flash, and when the flash is called by a third-party application, control the brightness of the flash through a weaker control signal. It should be understood that the third-party application calls the flash, which is usually used to implement functions such as scanning codes and identifying key information. In this case, the subject usually has a strong reflective ability and is at a close distance. Therefore, controlling the flash brightness with a weaker control signal can reduce the degree of overexposure of the image from a hardware level.

[0069] Below, the technical solution of the present disclosure is introduced by taking a smartphone scanning a QR code with the flash turned on as an example.

[0070] Figure 2 FIG. 1 is a flow chart of another image capturing method according to an exemplary embodiment of the present disclosure. Figure 2 As shown, the method comprises the following steps:

[0071] Step 201, start the camera function.

[0072] Step 202: Detect that the flashlight is called by a third-party application.

[0073] It should be understood that when the camera function is enabled and the flash is called by a third-party application, it means that it is likely to be used in shooting scenarios such as scanning a code, which requires getting close to the subject and the subject has a strong reflective ability.

[0074] For example, when a user needs to unlock a shared bicycle, he needs to open the shared bicycle APP (i.e. the third-party application mentioned above) to scan the QR code on the shared bicycle. At this time, if the light at the location of the shared bicycle may be dim, the QR code will not be recognized. Therefore, the shared bicycle APP can call the flash to fill the QR code. It should be understood that QR codes are usually printed on materials with smoother surfaces, mostly on plastic materials. In this scenario, in order to scan the QR code, the user must point the lens directly at the QR code, causing the flash to directly illuminate the QR code, causing the area where the QR code is located in the acquired image to be overexposed. Obviously, when the QR code is overexposed, the smartphone cannot recognize the QR code, resulting in the user being unable to unlock the shared bicycle.

[0075] Specifically, you can Figure 3 As shown, the QR code is overexposed under the flash and cannot be recognized.

[0076] Step 203, turning on the flashlight and controlling its brightness through a weak current.

[0077] Since it is very easy to overexpose the QR code when the flash is turned on, in this embodiment, the brightness of the flash is appropriately reduced to reduce the overexposure of the QR code.

[0078] Specifically, if the flash brightness is controlled by a current of a first intensity when taking an image through a camera APP provided by a smartphone, then in this step, the flash brightness may be controlled by a current of a second intensity, wherein the second intensity is weaker than the first intensity.

[0079] Step 204, obtaining framing parameters to obtain a framing image through a camera.

[0080] Step 205: Perform center-weighted exposure metering on the framing image.

[0081] In this embodiment, when scanning a QR code, the user usually points the camera of the smartphone directly at the QR code, resulting in the QR code being located in the center of the viewfinder, that is, the key information is located in the center of the viewfinder. At this time, giving the center area a higher weight can make the QR code in the captured image clearer.

[0082] Step 206 , determining a first area target brightness index of an overexposed area, a second area target brightness index of a medium-bright area, and a third area target brightness index of an underexposed area in the framing image based on the light metering result.

[0083] In this embodiment, the target brightness index that makes the overall exposure of the framing image normal can be determined first, and then the regional target brightness index corresponding to each region is determined based on the target brightness index and the exposure conditions of each region.

[0084] Specific, combined Figure 4 , describes how to determine the regional target brightness index corresponding to each region in this embodiment. Figure 4 As shown, the following steps may be included:

[0085] Step 401, determining an overexposed area, a medium-bright area, and an underexposed area in the viewfinder image based on the light metering result.

[0086] In this embodiment, the overexposed area, the medium-bright area, and the underexposed area in the viewfinder image can be determined based on the light metering result. On this basis, each area can be analyzed to obtain a regional target exposure index that makes each area tend to be exposed normally.

[0087] Step 402, determining the areas occupied by the overexposed area, the medium-bright area, and the underexposed area in the framing image.

[0088] It should be understood that, in this embodiment, the size of the area occupied by each area with different exposure levels in the framing picture represents, to a certain extent, the overall exposure bias of the current framing picture. For example, when the overexposed area occupies a large area in the framing picture, it means that the overall picture tends to be overexposed; when the underexposed area occupies a large area in the framing picture, it means that the overall picture tends to be underexposed. Based on this, it is not difficult to understand that after determining the area occupied by each area with different exposure levels in the framing picture, it is beneficial to determine the regional target exposure index of each area based on the target brightness index that makes the entire framing picture tend to be exposed normally. For example, when it is determined that the area occupied by the overexposed area is large, it means that the overall picture tends to be overexposed. Then, after determining the target brightness index that makes the overall framing picture tend to be exposed normally, the target brightness index can be appropriately reduced based on an algorithm to serve as the first regional target brightness index corresponding to the overexposed area, and the degree of reduction is positively correlated with the area occupied by the overexposed area in the framing picture; when the underexposed area occupies a large area, it is similar, and no repeated explanation is given here.

[0089] Of course, in actual operation, the area sizes of the various regions are not compared, but the area occupied by each region in the viewfinder can be converted into a parameter for adjusting the target brightness index, thereby obtaining the target brightness index of each region. For example, the proportion of each region in the viewfinder can be used as a parameter to adjust the target brightness index to obtain the corresponding regional target brightness index.

[0090] Step 403, determining the exposure levels of the overexposed area, the medium-bright area, and the underexposed area.

[0091] It should be understood that, in addition to the area occupied by each region in the framing image, the exposure level of each region needs to be considered to obtain the regional target exposure index corresponding to each region.

[0092] For example, assuming that the proportion of the overexposed area in the frame is certain, the higher the overexposure degree of the overexposed area, the higher the degree to which the entire frame tends to be overexposed. When determining the target brightness index of the first area based on the target brightness index, the value of the target brightness index of the first area should be further reduced; and for the underexposed area, the lower the exposure degree, the higher the degree to which the entire frame tends to be underexposed. Therefore, when determining the target brightness index of the third area based on the target brightness index, the value of the target brightness index of the third area should be further increased.

[0093] It should be noted that whether it is the introduction of area to regional target brightness index or the introduction of exposure to regional target brightness index, it is based on other factors remaining unchanged. In actual operation, the regional target exposure index should be determined in combination with various factors.

[0094] Step 404 , determining the regional target brightness index corresponding to each region based on the target brightness region, the exposure level of each region, and the area occupied by each region in the framing image.

[0095] In this embodiment, the first area target brightness index corresponding to the overexposed area can be determined based on the target brightness index, the area occupied by the overexposed area in the framing image, and the exposure level of the overexposed area; the second area target brightness index corresponding to the overexposed area can be determined based on the target brightness index, the area occupied by the medium-bright area in the framing image, and the exposure level of the medium-bright area; and the third area target brightness index corresponding to the underexposed area can be determined based on the target brightness index, the area occupied by the underexposed area in the framing image, and the exposure level of the underexposed area.

[0096] In actual operation, the target brightness index can be used as a benchmark, and the area occupied by each area in the framing screen and the exposure level of each area can be used as influencing parameters to determine the regional target brightness index corresponding to each area. In other words, the regional target brightness index is obtained by adjusting the target brightness index, and the direction and amplitude of the adjustment are affected by the area occupied by the framing screen and the exposure level of the area.

[0097] Step 207 : capturing an image based on the exposure parameter corresponding to the first area target brightness index corresponding to the overexposed area.

[0098] In actual operation, a corresponding relationship table between brightness index and exposure parameter can be preset, so as to obtain corresponding exposure parameter values ​​after determining the regional target brightness index corresponding to each region, so as to be used for shooting or adjusting the brightness of any region in the image.

[0099] Step 208 , adjusting the brightness of the area corresponding to the medium-bright area in the image based on the second area target brightness index, and adjusting the brightness of the area corresponding to the underexposed area in the image based on the third area target brightness index.

[0100] It should be understood that the regional target brightness index refers to: the brightness index that makes the corresponding area exposed normally. Obviously, among the three areas, the first regional target brightness index of the overexposed area must be the smallest, while the third regional target brightness index of the underexposed area is the largest. In the captured image, the original medium-bright area and the underexposed area must be underexposed, and the degree of underexposure is related to the ratio of the regional target brightness index of the two areas to the target brightness index of the first area. Therefore, in actual operation, the ratio of the second area target brightness index to the first area target brightness index can be calculated, and the brightness value of the area corresponding to the medium-bright area can be directly increased according to the ratio; the ratio of the third area target brightness index to the first area target brightness index can be calculated, and the brightness value of the area corresponding to the underexposed area can be increased according to the ratio.

[0101] It can be seen from the above technical solution that the present disclosure can determine the target brightness index that makes the exposure of the viewfinder tend to be normal based on the light measurement results, as well as the exposure level of each area and the area occupied by each area in the viewfinder. On this basis, the target brightness index can be used as a reference to adjust the regional target brightness index corresponding to each area.

[0102] Furthermore, the present disclosure can capture an image based on the exposure parameter corresponding to the first area target brightness index of the overexposed area, so that the originally overexposed area in the image tends to be exposed normally. It should be understood that in the scenario of scanning a QR code with the flash turned on, the exposed area is usually the area where the QR code is located. It can be seen that the present disclosure can make the area where the QR code is located be exposed normally, thereby avoiding the problem that the QR code cannot be recognized due to overexposure.

[0103] Furthermore, the present disclosure can further adjust the brightness of the area corresponding to the underexposed area in the captured image based on the third area target brightness index corresponding to the underexposed area; and adjust the brightness of the area corresponding to the medium-bright area in the captured image based on the second area target brightness index corresponding to the medium-bright exposed area, so that the entire image tends to be normally exposed, avoiding the problem of underexposure in the image captured based on the exposure parameters corresponding to the first area target brightness index, which leads to the failure of QR code recognition.

[0104] Figure 5 FIG. 1 is a block diagram of an image capturing device according to an exemplary embodiment of the present disclosure. Figure 5 The device includes a light metering unit 501, a first determination unit 502, a second determination unit 503 and a shooting unit 504.

[0105] The light metering unit 501 measures light on the viewfinder screen of the electronic device when the flash of the electronic device is turned on, so as to determine an initial brightness index corresponding to the viewfinder screen according to the light metering result; the initial brightness index is used to represent the overall brightness of the viewfinder screen at present;

[0106] A first determining unit 502 determines a target brightness index of the framing picture according to the initial brightness index; during the process of adjusting the framing picture to the target brightness index, the whole picture tends to be normally exposed;

[0107] A second determining unit 503 determines an overexposed area in the framing picture, and determines a first area target brightness index of the overexposed area based on the exposure degree of the overexposed area, the area occupied by the framing picture, and the target brightness index;

[0108] The photographing unit 504 photographs the content in the viewfinder image based on the exposure parameter corresponding to the target brightness index of the first area when the flash is turned on, so as to obtain an image with normal exposure of the area corresponding to the overexposed area.

[0109] Optionally, the light measuring unit 501 is further used for:

[0110] Allocating a photometric weight to each position in the framing picture according to the distance between each position and the picture center; the photometric weight of each position is negatively correlated with the corresponding distance;

[0111] Based on the light metering weights of the various positions, the brightness indexes of the various positions are weightedly calculated to obtain an initial brightness index corresponding to the framing picture.

[0112] Optionally, a corresponding relationship between an initial brightness index range and a target brightness index is preset in the electronic device; and the first determining unit 502 is further used to:

[0113] Determining a target initial brightness index range to which the initial brightness index belongs from a plurality of preset initial brightness index ranges;

[0114] And the target brightness index corresponding to the target initial brightness index range is determined as the target brightness index of the framing picture.

[0115] like Figure 6 As shown, Figure 6is a block diagram of another image capturing device shown in an exemplary embodiment of the present disclosure. Figure 5 On the basis of the illustrated embodiment, it further includes: an adjustment unit 505 , a first control unit 506 , a second control unit 507 and a framing unit 508 .

[0116] Optionally, also include:

[0117] The adjustment unit 505 determines an underexposed area in the framing image, and other areas whose exposure levels are between the overexposed area and the underexposed area; determines a second area target brightness index of the other areas and a third area target brightness index of the underexposed area according to the exposure levels of the other areas and the underexposed area, the areas occupied by the framing image, and the target brightness index; and performs brightness adjustment on areas corresponding to the other areas and the underexposed area in the captured image based on the second area target brightness index and the third area target brightness index, respectively.

[0118] Optionally, also include:

[0119] The first control unit 506 controls the brightness of the flash through a first control signal when it is determined that the flash is turned on by a third-party application installed in the electronic device; the intensity of the first control signal is weaker than the second control signal used to control the brightness of the flash when the flash is turned on by an application other than the third-party application.

[0120] Optionally, also include:

[0121] The second control unit 507 determines the business currently being executed by the electronic device when the flash is called, so as to determine the strength of the control signal for controlling the brightness of the flash according to the business; wherein, when the business being executed by the electronic device is for realizing a code scanning function, the brightness of the flash is controlled by a third control signal; the strength of the third control signal is weaker than the fourth control signal for controlling the brightness of the flash when the business executed by the electronic device is not for realizing a code scanning function.

[0122] Optionally, the electronic device is preset with a corresponding relationship between the control signal strength and the framing parameter; and the method further includes:

[0123] The framing unit 508 obtains the current control signal strength for controlling the brightness of the flash when the flash is turned on; determines the framing parameters corresponding to the current control signal strength, and uses the determined framing parameters as initial framing parameters for capturing the framing picture.

[0124] For the device embodiments, since they basically correspond to the method embodiments, the relevant parts can refer to the partial description of the method embodiments. The device embodiments described above are only schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the disclosed solution. A person of ordinary skill in the art can understand and implement it without paying any creative work.

[0125] Accordingly, the present disclosure also provides an image capturing device, comprising: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to implement an image capturing method as described in any of the above embodiments, for example, the method may include: when the flash of the electronic device is turned on, measuring the viewfinder screen of the electronic device to determine an initial brightness index corresponding to the viewfinder screen according to the light measuring result; the initial brightness index is used to characterize the overall brightness of the viewfinder screen at present; determining a target brightness index of the viewfinder screen according to the initial brightness index; in the process of adjusting the viewfinder screen to the target brightness index, the overall exposure of the screen tends to be normal; determining an overexposed area in the viewfinder screen to determine a first area target brightness index of the overexposed area based on the exposure degree of the overexposed area, the area occupied by the viewfinder screen and the target brightness index; when the flash is turned on, photographing the content in the viewfinder screen based on the exposure parameters corresponding to the first area target brightness index to obtain an image with normal exposure of the area corresponding to the overexposed area.

[0126] Accordingly, the present disclosure also provides an electronic device, which includes a memory and one or more programs, wherein one or more programs are stored in the memory and are configured to be executed by one or more processors. The one or more programs include instructions for implementing the image shooting method as described in any of the above embodiments. For example, the method may include: when the flash of the electronic device is turned on, the viewfinder of the electronic device is metered to determine the initial brightness index corresponding to the viewfinder according to the metering result; the initial brightness index is used to characterize the overall brightness of the viewfinder at present; the target brightness index of the viewfinder is determined according to the initial brightness index; in the process of adjusting the viewfinder to the target brightness index, the overall exposure of the picture tends to be normal; determining an overexposed area in the viewfinder to determine a first area target brightness index of the overexposed area based on the exposure degree of the overexposed area, the area occupied by the viewfinder and the target brightness index; when the flash is turned on, the content in the viewfinder is photographed based on the exposure parameters corresponding to the first area target brightness index to obtain an image with normal exposure of the area corresponding to the overexposed area.

[0127] Figure 7 1 is a block diagram of an apparatus 700 for implementing a process scheduling method according to an exemplary embodiment. For example, the apparatus 700 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0128] Reference Figure 7 , the device 700 may include one or more of the following components: a processing component 702 , a memory 704 , a power component 706 , a multimedia component 708 , an audio component 710 , an input / output (I / O) interface 712 , a sensor component 714 , and a communication component 716 .

[0129] The processing component 702 generally controls the overall operation of the device 700, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 702 may include one or more processors 720 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 702 may include one or more modules to facilitate the interaction between the processing component 702 and other components. For example, the processing component 702 may include a multimedia module to facilitate the interaction between the multimedia component 708 and the processing component 702.

[0130] The memory 704 is configured to store various types of data to support operations on the device 700. Examples of such data include instructions for any application or method operating on the device 700, contact data, phone book data, messages, pictures, videos, etc. The memory 704 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0131] The power supply component 706 provides power to the various components of the device 700. The power supply component 706 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 700.

[0132] The multimedia component 708 includes a screen that provides an output interface between the device 700 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 708 includes a front camera and / or a rear camera. When the device 700 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0133] The audio component 710 is configured to output and / or input audio signals. For example, the audio component 710 includes a microphone (MIC), and when the device 700 is in an operating mode, such as a call mode, a recording mode, and a speech recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 704 or sent via the communication component 716. In some embodiments, the audio component 710 also includes a speaker for outputting audio signals.

[0134] I / O interface 712 provides an interface between processing component 702 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.

[0135] The sensor assembly 714 includes one or more sensors for providing various aspects of status assessment for the device 700. For example, the sensor assembly 714 can detect the open / closed state of the device 700, the relative positioning of components, such as the display and keypad of the device 700, the sensor assembly 714 can also detect the position change of the device 700 or a component of the device 700, the presence or absence of user contact with the device 700, the orientation or acceleration / deceleration of the device 700, and the temperature change of the device 700. The sensor assembly 714 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 714 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 714 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0136] The communication component 716 is configured to facilitate wired or wireless communication between the device 700 and other devices. The device 700 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, 4G LTE, 5G NR (New Radio) or a combination thereof. In an exemplary embodiment, the communication component 716 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 716 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0137] In an exemplary embodiment, the apparatus 700 may be implemented by one or more application specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components to perform the above methods.

[0138] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 704 including instructions, and the instructions can be executed by the processor 720 of the device 700 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0139] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the disclosure disclosed herein. The present disclosure is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are to be considered exemplary only, and the true scope and spirit of the present disclosure are indicated by the following claims.

[0140] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

[0141] The above description is only a preferred embodiment of the present disclosure and is not intended to limit the present disclosure. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present disclosure shall be included in the scope of protection of the present disclosure.

Claims

1. An image capturing method, It is characterized in that Used in electronic equipment, including: When the flash of the electronic device is turned on, measuring the light of the viewfinder screen of the electronic device to determine an initial brightness index corresponding to the viewfinder screen according to the light measurement result; the initial brightness index is used to represent the overall brightness of the viewfinder screen at present; Determining a target brightness index of the framing picture according to the initial brightness index; during the process of adjusting the framing picture to the target brightness index, the whole picture tends to be normally exposed; Determine an overexposed area in the framing picture, and determine a first area target brightness index of the overexposed area based on the exposure degree of the overexposed area, the area occupied by the framing picture, and the target brightness index; When the flash is turned on, the content in the viewfinder is photographed based on the exposure parameter corresponding to the target brightness index of the first area, so as to obtain an image with normal exposure of the area corresponding to the overexposed area.

2. The method according to claim 1, It is characterized in that Also includes: Determine an underexposed area in the framing image, and other areas whose exposure levels are between the overexposed area and the underexposed area; Determine a second area target brightness index of the other area and a third area target brightness index of the underexposed area according to the exposure levels of the other area and the underexposed area, the areas occupied by the framing screen and the target brightness index respectively; Based on the second area target brightness index and the third area target brightness index respectively, brightness adjustment is performed on an area corresponding to the other area and an area corresponding to the underexposed area in the captured image.

3. The method according to claim 1, It is characterized in that Also includes: When it is determined that the flashlight is turned on by being called by a third-party application installed in the electronic device, controlling the brightness of the flashlight through a first control signal; The intensity of the first control signal is weaker than the second control signal used to control the brightness of the flash when the flash is called by an application other than the third-party application.

4. The method according to claim 1, It is characterized in that Also includes: In the case where the flashlight is called, determining the service currently being executed by the electronic device, so as to determine the strength of the control signal for controlling the brightness of the flashlight according to the service; Among them, when the business being executed by the electronic device is for realizing the code scanning function, the brightness of the flash is controlled by a third control signal; the intensity of the third control signal is weaker than the fourth control signal used to control the brightness of the flash when the business being executed by the electronic device is not for realizing the code scanning function.

5. The method according to claim 1, It is characterized in that The method of measuring light on a framing picture of the electronic device to determine an initial brightness index corresponding to the framing picture according to the light measuring result comprises: Allocating a photometric weight to each position in the framing picture according to the distance between each position and the picture center; the photometric weight of each position is negatively correlated with the corresponding distance; Based on the light metering weights of the various positions, the brightness indexes of the various positions are weightedly calculated to obtain an initial brightness index corresponding to the framing picture.

6. The method according to claim 1, It is characterized in that The electronic device is preset with a correspondence between an initial brightness index range and a target brightness index; and determining the target brightness index of the framing picture according to the initial brightness index includes: Determining a target initial brightness index range to which the initial brightness index belongs from a plurality of preset initial brightness index ranges; And the target brightness index corresponding to the target initial brightness index range is determined as the target brightness index of the framing picture.

7. The method according to claim 1, It is characterized in that The electronic device is preset with a corresponding relationship between the control signal strength and the framing parameter; the method further includes: When the flashlight is turned on, obtaining a current control signal strength for controlling the brightness of the flashlight; Determine a framing parameter corresponding to the current control signal strength, and use the determined framing parameter as an initial framing parameter for capturing the framing picture.

8. An image capturing device, It is characterized in that Used in electronic equipment, including: a light metering unit, which measures light on a viewfinder screen of the electronic device when a flash of the electronic device is turned on, so as to determine an initial brightness index corresponding to the viewfinder screen according to the light metering result; the initial brightness index is used to represent the overall brightness of the viewfinder screen at present; A first determining unit determines a target brightness index of the framing picture according to the initial brightness index; when the framing picture is adjusted to the target brightness index, the whole picture tends to be normally exposed; a second determining unit, configured to determine an overexposed area in the framing picture, and to determine a first area target brightness index of the overexposed area based on an exposure degree of the overexposed area, an area occupied by the framing picture, and the target brightness index; The shooting unit shoots the content in the viewfinder image based on the exposure parameter corresponding to the target brightness index of the first area when the flash is turned on, so as to obtain an image with normal exposure of the area corresponding to the overexposed area.

9. An electronic device, It is characterized in that include: processor; a memory for storing processor-executable instructions; The processor implements the method according to any one of claims 1 to 7 by running the executable instructions.

10. A computer-readable storage medium having computer instructions stored thereon, It is characterized in that When the instruction is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.