Shooting method, electronic equipment and computer storage medium

By identifying the type and location of light sources and formulating targeted shooting rules to adjust parameters, the problem of shooting electronic devices in complex lighting scenarios has been solved, and image quality has been improved.

CN121509804APending Publication Date: 2026-02-10HONOR DEVICE CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411045866.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-31
Publication Date
2026-02-10

AI Technical Summary

Technical Problem

When shooting in complex lighting conditions, existing electronic devices are prone to problems such as abnormal exposure, subject artifacts, color malfunctions, and ghosting, resulting in poor image quality.

Method used

By identifying the type and location of light sources in the shooting scene, different scene types are classified, and corresponding shooting rules are formulated for each scene type, including metering, focus, and white balance strategies, and shooting parameters are dynamically adjusted to improve image quality.

Benefits of technology

It effectively improves shooting quality in complex lighting conditions, reduces overexposure and color loss, and enhances image detail and overall picture quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121509804A_ABST
    Figure CN121509804A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of shooting, and provides a shooting method, electronic equipment and a computer storage medium. In the method, the electronic equipment can collect a preview image of a shooting scene, and identifies a scene type of the shooting scene based on the preview image. And then, based on the scene information of the current shooting scene, determining shooting parameters of the shooting rule corresponding to the scene type, and shooting the shooting scene through the adjusted shooting parameters to obtain a corresponding image. Therefore, according to different shooting scenes with different light complexity, the electronic equipment can adopt different shooting rules for shooting instead of adopting only one default shooting rule for shooting. And shooting scenes with different light complexity degrees are shot through different shooting rules, so that the electronic equipment can be flexibly adjusted to proper shooting parameters for shooting, and the image quality of a shot picture can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of photography technology, and more particularly to a photography method, electronic device, and computer storage medium. Background Technology

[0002] When users take photos using electronic devices such as mobile phones, tablets, and cameras, if the users do not actively adjust the shooting parameters of the electronic devices, the electronic devices will usually use the 3A (auto focus (AF), auto exposure (AE), auto white balance (AWB)) decision mechanism to take photos using the default shooting rules. For example, the average brightness of the preview image is measured first, then the exposure parameters of the electronic devices are adjusted according to the average brightness, and then the photos are taken using the adjusted exposure parameters.

[0003] However, the default shooting rules of electronic devices are only suitable for shooting common scenes with relatively simple lighting. For scenes with more complex lighting, such as stage scenes, when electronic devices shoot using the default shooting rules, abnormalities such as exposure errors, subject artifacts, color malfunctions, and ghosting of moving subjects may occur, resulting in poor image quality.

[0004] For example, in stage scenes with complex light sources, if the electronic device adjusts the exposure parameters based on the average brightness of the preview image, it may cause overexposure in areas that were originally bright in the captured image, resulting in the loss of color and texture details in those areas and thus poor image quality. Summary of the Invention

[0005] Some embodiments of this application provide a shooting method, an electronic device, and a storage medium. The following describes this application from multiple aspects, and the embodiments and beneficial effects of the following aspects can be referred to each other.

[0006] In a first aspect, this application provides a shooting method for an electronic device, the method comprising: acquiring a preview image of a shooting scene; identifying the scene type of the shooting scene based on the preview image, wherein the scene type is classified based on the type and position of the light source; determining shooting parameters corresponding to the shooting rules corresponding to the scene type based on the scene information of the shooting scene; and, in response to the detection of a shooting command, taking a picture of the shooting scene using the determined shooting parameters to obtain a first image.

[0007] When an electronic device captures a scene, it first identifies the scene type based on the preview image. Then, it applies the shooting rules corresponding to that scene type and determines the shooting parameters based on the scene information. Finally, it captures the scene using these parameters. This allows the electronic device to use different shooting rules for scenes with varying lighting complexity, rather than relying on a single default rule. Using different shooting rules for scenes with varying lighting complexity allows the device to flexibly adjust the shooting parameters, thereby improving the image quality of the captured footage.

[0008] In some implementations, identifying the scene type of the shooting scene based on the preview image includes: obtaining light source position information of the shooting scene based on the preview image, the light source position information including the type and position of the light source in the shooting scene; and determining the scene type of the shooting scene based on the light source position information.

[0009] Electronic devices can capture a preview image of the current shooting scene, and then input the preview image into a trained light source position detection model to obtain the light source position information output by the light source position detection model.

[0010] It is understandable that the light source detection model can be an image detection model based on deep learning methods, such as a convolutional neural network model, a fully convolutional network model, or a generative adversarial network model.

[0011] In some embodiments, images with varying degrees of light complexity—that is, images with different types and positions of light sources—can be acquired as sample images for training the light source position detection model. These sample images are then input into the light source position detection model to be trained. The model performs light source position detection on the sample images and outputs predicted light source position information. A loss function is then calculated based on the difference between the predicted light source position information output by the model and the corresponding true light source position information. The model parameters are then adjusted according to this loss function. Training ends when the light source position detection model achieves the expected results, the loss function converges, or the number of training iterations reaches a set number.

[0012] In some implementations, the scene type of the shooting scene is determined based on the light source position information, including:

[0013] The light source position information indicates that the types of light sources in the shooting scene include spotlight, diffused light, soft light, and imaging light. In addition, the positions of the light sources include front light sources, side light sources, top light sources, backlight sources, and first background light sources. The scene type of the shooting scene is a first-level stage scene.

[0014] The light source position information indicates that the type of light source in the shooting scene includes spotlight, diffused light, and soft light. In addition, the position of the light source includes front light source, side light source, top light source, backlight source, and second background light source. The scene type of the shooting scene is a secondary stage scene.

[0015] The light source position information indicates that the types of light sources in the shooting scene include spotlight, diffused light, and soft light. In addition, the positions of the light sources include front light sources, side light sources, and third background light sources. The scene type of the shooting scene is a level three stage scene.

[0016] The first background light source includes a screen light source and a sign light source. The second background light source includes a screen light source. The third background light source includes a sign light source.

[0017] In some implementations, identifying the scene type of the shooting scene based on the preview image further includes:

[0018] Perform first-level scene recognition on the preview image to obtain the first-level scene recognition result;

[0019] The primary scene recognition result corresponds to a stage scene. The secondary scene recognition is then performed on the preview image to obtain the secondary scene recognition result.

[0020] Based on the results of the secondary scene recognition, the scene type to which the shooting scene belongs is determined.

[0021] In some implementations, the scene type to which the shooting scene belongs is determined based on the secondary scene recognition results, including:

[0022] The corresponding secondary scene recognition result is one of the following, and the scene type of the shooting scene is a primary stage scene: gala, concert, music festival and e-sports competition;

[0023] The scene type corresponding to the secondary scene recognition result is one of the following: secondary stage scene: press conference, drama, play, stage play, musical, and situational drama;

[0024] The corresponding level 2 scene recognition result is one of the following, and the scene type of the shooting scene is a level 3 stage scene: bar, live music venue, stand-up comedy.

[0025] In some implementations, based on scene information of the shooting scene, shooting parameters corresponding to the shooting rules corresponding to the scene type are determined, including:

[0026] For a scene type of Level 1 stage scene, the first shooting rule is used to determine the shooting parameters based on the scene information; or...

[0027] For a scene type of Level 2 stage, the second shooting rule is used to determine the shooting parameters based on the scene information; or,

[0028] For a stage scene of type 3, the third shooting rule is used to determine the shooting parameters based on the scene information.

[0029] The first shooting rule can be shooting rule A mentioned in this application, the second shooting rule can be shooting rule B mentioned in this application, and the third shooting rule can be shooting rule C mentioned in this application.

[0030] In some implementations, a first shooting rule is used to determine shooting parameters based on scene information, including:

[0031] Meter the light in the center area of ​​the stage in the shooting scene, and determine the exposure parameters based on the metering results; or,

[0032] For shooting scenes that include screens, meter the light on the area where the screen is located, and determine the exposure parameters based on the metering results; or,

[0033] For shooting scenes that include people, partial metering mode is used to meter the area where the people are located, and the exposure parameters are determined based on the metering results; or,

[0034] For shooting scenes that include people, spot side lighting mode is used to meter the face area of ​​one of the people, and the exposure parameters are determined based on the metering results.

[0035] In some implementations, a second shooting rule is used to determine shooting parameters based on scene information, including:

[0036] Meter the light in the center area of ​​the stage in the shooting scene, and determine the exposure parameters based on the metering results; or,

[0037] For shooting scenes that include screens, meter the light on the area where the screen is located, and determine the exposure parameters based on the metering results; or,

[0038] For shooting scenes that include people, partial metering mode is used to meter the area where the people are located, and the exposure parameters are determined based on the metering results; or,

[0039] For shooting scenes that include people, spot side lighting is used to meter the facial area of ​​one of the people, and the exposure parameters are determined based on the metering result; or,

[0040] For shooting scenes that include people, center-weighted metering mode is used to meter the area where the people are located, and the exposure parameters are determined based on the metering results.

[0041] In some implementations, a third shooting rule is used to determine shooting parameters based on scene information, including:

[0042] For shooting scenes that include people, spot side lighting mode is used to meter the face area of ​​one of the people, and the exposure parameters are determined based on the metering results.

[0043] In some implementations, determining the shooting parameters corresponding to the shooting rules for the scene type based on scene information of the shooting scene further includes:

[0044] For scenes that are not classified as Level 1, Level 2, or Level 3 stage scenes, preset shooting rules are used to determine the shooting parameters based on the scene information.

[0045] The preset shooting rules can be the general shooting rules mentioned in this application.

[0046] Secondly, embodiments of this application provide an electronic device, including a memory for storing instructions executable by one or more processors of the electronic device; and a processor, which, when executing the instructions in the memory, causes the electronic device to perform the method described in any embodiment of the first aspect of this application. The beneficial effects achievable in the third aspect can be referred to the beneficial effects of the method provided in any embodiment of the first aspect, and will not be repeated here.

[0047] Thirdly, embodiments of this application provide a computer-readable storage medium storing instructions that, when executed on a computer, cause the computer to perform the method described in any embodiment of the first aspect. The beneficial effects achievable in the fourth aspect can be found in the beneficial effects of the method provided in any embodiment of the first aspect, and will not be repeated here.

[0048] Fourthly, embodiments of this application provide a computer program product including computer program code. When the computer program code is run on a computer, it causes the computer to implement the method described in any embodiment of the first aspect. The beneficial effects achievable in this fourth aspect can be found in the beneficial effects of the method provided in any embodiment of the first aspect, and will not be repeated here. Attached Figure Description

[0049] Figure 1 This is an exemplary application scenario for this application;

[0050] Figure 2 A schematic diagram illustrating the working principle of the 3A statistical decision-maker provided in this application embodiment;

[0051] Figure 3 This application provides a flowchart of the 3A statistical decision-making process performed by the embodiment.

[0052] Figure 4 A schematic diagram of light source position detection is provided for embodiments of this application;

[0053] Figure 5 A schematic flowchart illustrating a shooting method provided in an embodiment of this application;

[0054] Figure 6 Scenes captured by mobile phone as provided in the embodiments of this application Figure 1 ;

[0055] Figure 7 Scenes captured by mobile phone as provided in the embodiments of this application Figure 2 ;

[0056] Figure 8 A flowchart illustrating another shooting method provided in an embodiment of this application;

[0057] Figure 9 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0058] The embodiments of this application provide a shooting method for improving the shooting quality of electronic devices under complex lighting conditions.

[0059] It should be noted that the shooting method provided in this application can be applied to any electronic device with shooting capabilities, including but not limited to mobile phones, tablets, cameras, smartwatches, drones, and other electronic devices with shooting capabilities. The following uses a mobile phone as an example of an electronic device.

[0060] To facilitate understanding, the types of light sources and light positions (locations of the light sources) involved in this application will be introduced below. The light position type can also be called the lighting type, which refers to the way the light sources are arranged.

[0061] (1) Type of light source

[0062] Table 1 below shows several types of light sources, but is not limited to these.

[0063] Table 1

[0064]

[0065]

[0066] As shown in Table 1, light source types can include diffused light, spotlight, soft light, and imaging light. Diffuse light sources are characterized by a large illumination range and soft, uniform light, and are often used as ceiling lights, floor lights, footlights, and overhead lights. Their main fixtures include, but are not limited to, tungsten halogen lamps, LED diffusers, and strobe lights. Spotlight light sources are characterized by a small illumination range, high illuminance, and relatively clear light spot edges, which can highlight specific areas. They are often used as front lights, side lights, follow spots, and other lighting. Their main fixtures include, but are not limited to, stage spotlights, stage backlights, PAR lights, computer-controlled beam lights, and follow spots. Soft light sources are characterized by soft, uniformly distributed light with a relatively blurred light spot outline. They are often used as overhead lights, and their main fixtures include, but are not limited to, spiral spotlights, tri-phosphor soft lights, and computer-controlled soft lights. Imaging light sources can be light sources with a certain shape obtained by adding a shaping insert to a spotlight. They can be provided by multi-functional stage lighting fixtures that combine spotlights, imaging lights, and portable beams, such as stage imaging lights, computer imaging lights, and digital projection lights.

[0067] (2) Light position type (lighting type)

[0068] Table 2 below shows several types of optical positions, but is not limited to these.

[0069] Table 2

[0070]

[0071]

[0072] As shown in Table 2, lighting types include front light sources, side light sources, top light sources, backlighting, and background light sources. Front light sources include front lights, bridge lights, stage lights, footlights, and follow spots. Side light sources include ear lights, orchestra pit side lights, pillar lights, bridge lights, and flowing lights. Top light sources include orchestra pit top lights and stage top lights. Background light sources include top and bottom lighting and screen lighting.

[0073] Front lighting, which is light projected onto the stage from above and directly in front of the audience, serves the following purposes: 1. To illuminate the front of the performers. 2. To provide basic stage lighting.

[0074] The lighting for the stage bridge is located on the upper edge of the stage platform, close to the back of the main curtain. It is placed on the lighting bridge (a platform or passageway erected above the stage) or on the upper part of the false proscenium (the part of the decorative structure at the front of the stage where the lighting fixtures are installed).

[0075] The stage light, usually placed on the balustrade at the front of the audience seating area, is also known as a low-level surface light. Its function is to increase the overall brightness of the front of the stage and to supplement the surface light.

[0076] Footlights are lights projected onto the stage from the platform in front of the proscenium arch. Their functions include: 1. Eliminating shadows created by high-positioned front lights shining on the nose and chin of performers. 2. Illuminating the lower part of the curtain after the main curtain closes. 3. Creating a sinister or eerie atmosphere when used alone.

[0077] Follow spot, a light that shines on a target person and moves with that person, is mainly used to follow an actor's performance or to highlight a specific light source. It is also used by hosts or main characters and is a close-up detail in stage art, playing a finishing touch role.

[0078] The ear slap, located on both sides outside the proscenium, is a light projected obliquely onto the stage. It is divided into several layers, mainly serving as auxiliary front lighting to enhance facial illumination and increase the sense of flatness of characters and scenery.

[0079] The orchestra pit side lights, located on both sides just outside the proscenium, provide side lighting for the extended parts of the stage, enhancing the sense of three-dimensionality and contour.

[0080] Column lights, located on either side of the stage curtain at the stage entrance, are mounted on column light frames or false proscenium side panels. Also called proscenium side lights, their primary function is to illuminate the sides of figures and scenery, enhancing the sense of plane and contour. Basic lighting connects with ear lights, serving a similar purpose.

[0081] Bridge lighting, also known as "side lighting," is the side lighting projected onto the stage from the first skybridge on either side of the stage. It is mainly used to supplement pillar lighting, enhance the sense of flatness, and is also used in other locations where projection is inconvenient. It can also serve as a specific light source. There are three lighting methods: forward projection, local projection, and backward projection, used to highlight the figures and the three-dimensional shapes of scenery.

[0082] The moving lights, located on moving light stands on both sides of the stage, serve to supplement the bridge lights.

[0083] The orchestra pit top light shines vertically downwards from the top of the orchestra pit, serving as top lighting for the orchestra pit or, after the orchestra pit is raised, becomes an extended stage. Its function is the same as that of a top light.

[0084] Stage overhead lighting is light projected onto the stage from above. It is divided into a first row of overhead lights, a second row of lights, a third row of lights, etc., from front to back. It is mainly used for general stage lighting, increasing the brightness of the stage, and also for fixed-point illumination of many scenery and props.

[0085] Backlighting, light projected from the opposite direction of the stage (usually using top lighting, bridge lighting, or temporary stage lighting), can outline the contours of people and objects, enhance the perception of planes and transparency, and can also serve as a specific light source. It delineates outlines, separates the subject or task from the background, and creates a sense of spatial depth.

[0086] The "sky and earth light" refers to the light projected onto the canopy from above and below, primarily used for illuminating the canopy and changing its colors.

[0087] Screen light refers to the light emitted from the background screen at the press conference venue, used to display the released content, etc.

[0088] Figure 1 This is an exemplary application scenario for this application.

[0089] refer to Figure 1 Stage B01 is equipped with diffuser lights 10A and 10B, spotlight lights 20A and 20B, follow spotlight 30, and soft light lights 40A and 40B to provide light sources of different brightness, angles, and types.

[0090] The diffuser 10A is positioned on the far left above stage B01 to provide diffused light to the left side of stage B01.

[0091] The diffuser 10B is positioned on the far right above stage B01 to provide diffused light to the right side of stage B01.

[0092] Spotlight 20A is adjacent to diffuser 10A and is located to the right of diffuser 10A, used to provide bright spotlight to the left side of stage B01.

[0093] Spotlight 20B is adjacent to diffuser 10B and is positioned to the left of diffuser 10B to provide bright spotlight to the right side of stage B01.

[0094] Follow spot 30 is positioned directly above stage B01 to provide a light source for following the target person on stage B01.

[0095] The soft light 40A is positioned at the front left of stage B01 to provide soft light to the left side of stage B01.

[0096] The soft light 40B is positioned at the front right of stage B01 to provide soft light to the right side of stage B01.

[0097] Users can use their mobile phones (100) in the audience seats in front of stage B01 to take pictures of stage B01 and obtain the corresponding images.

[0098] As mentioned earlier, when a user opens the camera app on mobile phone 100 and directly clicks the shutter button 16, mobile phone 100 will use default shooting rules to shoot stage B01. For example, it first measures the average brightness of preview image 15, which is the average brightness of stage B01, then adjusts the exposure parameters based on this average brightness, and then takes a picture of stage B01 using the adjusted exposure parameters to obtain image M1. Since there are many types of light sources on stage B01 and the positions of these light sources (hereinafter referred to as light positions) are complex, there may be some brighter areas. In this case, if mobile phone 100 adjusts the exposure parameters based on the average brightness of stage B01, the brighter areas in the captured image M1 may appear overexposed, resulting in a loss of texture details and color in these areas, thus leading to poor image quality in image M1.

[0099] In view of this, this application provides a shooting method. In this method, scene types corresponding to different levels of lighting complexity (e.g., concerts, plays, stand-up comedy, etc.) can be pre-defined, and different shooting rules can be established for different types of shooting scenes. For example, based on the lighting complexity of the shooting scene (type of light source, complexity of light source position), the shooting scene can be divided into different scene types, and different shooting rules can be set for different scene types, such as different light interference reduction strategies, different metering strategies, different focusing strategies, different color temperature detection strategies, etc.

[0100] Then, during real-time shooting, the electronic device can acquire a preview image of the shooting scene and identify the scene type based on the complexity of the light sources in the preview image (e.g., the type and location of the light sources). The electronic device can then use the shooting rules corresponding to the determined scene type to determine the shooting parameters (e.g., exposure parameters, color temperature parameters, white balance parameters, etc.) for that scene. Finally, the electronic device can use these determined shooting parameters to capture the corresponding image of the current scene.

[0101] In some embodiments, the electronic device can employ shooting rules corresponding to the scene type of the shooting scenario. Based on the scene information of the current shooting scenario (e.g., stage lines, screen, camera position, face, human body, etc.), it determines the shooting parameters (e.g., metering position, focus position, etc.) for the corresponding scene type's shooting rules, and then uses the adjusted shooting parameters to capture the scene and obtain the corresponding image. In this way, the electronic device can use different shooting rules for shooting scenarios with varying lighting complexity, instead of just using a single default rule. Using different shooting rules for shooting scenarios with varying lighting complexity allows the electronic device to flexibly adjust to appropriate shooting parameters, thereby improving the image quality of the captured footage.

[0102] The technical solution of this application is illustrated below using a stage scene as an example. However, this application is not limited to this. The technical solution of this application is also applicable to other scenes, such as sports competition scenes, landscape scenes, amusement park scenes, movie-watching scenes, etc. For ease of description, the "type of light source" will be referred to as "light source type", the "position of light source" will be referred to as "light position", and the "type of light source position" will be referred to as "light position type".

[0103] In some embodiments, the stage scene can be divided into different types (levels) based on the complexity of the light source type and light position type, such as a first-level stage scene, a second-level stage scene and a third-level stage scene, and different shooting rules can be formulated, such as shooting rule A, shooting rule B and shooting rule C.

[0104] For example, since the light source types and lighting positions of stage scenes such as galas, performances, concerts, music festivals, and e-sports competitions are the most complex, they can be classified as primary stage scenes. Since the light source types and lighting positions of stage scenes such as press conferences, dramas, plays, stage plays, musicals, and sitcoms are less complex than those of primary stage scenes, they can be classified as secondary stage scenes. Since the light source types and lighting positions of stage scenes such as bars, live music venues, and stand-up comedy shows are the least complex, they can be classified as tertiary stage scenes. Then, shooting rules A can be formulated for primary stage scenes, shooting rules B for secondary stage scenes, and shooting rules C for tertiary stage scenes.

[0105] For example, as shown in Table 3 below, the stage scenes covered by Level 1 stage scenes include, but are not limited to, parties, performances, concerts, music festivals, and e-sports competitions. Their light source types include, but are not limited to, spotlights, diffused light, soft light, and imaging light. Their light position types include, but are not limited to, front light sources, side light sources, top light sources, backlight sources, and the first background light source (screen light source + signboard light source). The shooting rules are as follows: Shooting Rule A. The stage scenes covered by Level 2 stage scenes include, but are not limited to, press conferences, dramas, plays, stage plays, musicals, and situational dramas. Their light source types include, but are not limited to, spotlights, diffused light, soft light, and imaging light. Their light position types include, but are not limited to, front light sources, side light sources, and the second background light source (screen light source). The shooting rules are as follows: Shooting Rule B. The stage scenes covered by Level 3 stage scenes include, but are not limited to, bars, live music venues, and stand-up comedy shows. Their light source types include, but are not limited to, spotlights, diffused light, and soft light. Their light position types include, but are not limited to, front light sources, side light sources, and the third background light source (signboard light source). The shooting rules are as follows: Shooting Rule C.

[0106] Table 3

[0107]

[0108] The following sections introduce shooting rules A, B, and C.

[0109] 1. Shooting Rules A

[0110] 1.1 When stage lines (the outline of the stage) and screens are detected, interference light is removed using appropriate algorithms for complex light source positions (light source type and light position type). For example, the metering window (the window for measuring light intensity) and the focus window (the window for focusing) are controlled in the center area of ​​the stage to reduce the impact of interfering light sources on metering. The metering window is used to measure light intensity, and the focus window is used by the camera to focus.

[0111] 1.2 When multiple people or faces appear in a scene, activate the motion reduction exposure and shutter priority rules.

[0112] 1.3 When multiple people are present, and a prominent single person area appears, the focus window and metering window should be controlled within the region of interest (ROI) of the person, and local metering mode should be used for metering. Local metering mode measures the average light intensity of a specific local area within the preview image (e.g., an area occupying 10% to 25% of the preview image).

[0113] 1.4 When a single face area appears and there is frontal spotlighting to emphasize the main character, the focus and metering windows should be controlled on the main character's face ROI, and spot metering mode should be selected for metering. Spot metering mode measures the average light intensity of a small area within the preview image (e.g., an area occupying 2% to 5% of the preview image).

[0114] 2. Shooting Rules B

[0115] 2.1 When stage lines and screens are detected, interference light is removed using appropriate algorithms for complex light source positions. For example, the metering window and focus window are controlled in the center area of ​​the stage to reduce the impact of interference light sources on metering.

[0116] 2.2 For press conferences with display screens, the display screen area is detected by light source position detection (detection of light source type and position type), the exposure of the screen area is reduced by one level to lower the overall brightness, and human faces are detected in adjacent frames.

[0117] 2.3 When a single person is present, control the focus and metering windows to cover that area and use partial metering. If both the screen and the person are present, calculate the light ratio (the ratio of light intensity) between the screen and the person areas, and adjust the position and size of the focus and metering windows accordingly to ensure proper exposure of the person area. For example, if the light ratio between the screen and the person areas is large or small, control the focus and metering windows to cover the person area and use partial metering. If the light ratio between the screen and the person areas is close to 1 (i.e., the brightness of the screen and the person areas are similar), control the focus and metering windows to cover both the screen and the person areas and use partial metering.

[0118] 2.4 When a single face appears and there is frontal spotlighting, in order to highlight the main character, control the focus window and metering window to the main character's face ROI, and select spot metering mode for metering.

[0119] 2.5 When multiple people or faces are present in a scene, center-weighted metering mode is used for metering, and shutter priority rule is activated. Center-weighted metering mode meters the central area and other areas of the preview image separately, and calculates the weighted average of the metering results of the central area and other areas as the metering result of the entire preview image. The weight of the central area is greater than that of other areas. For example, the weight of the central area is 0.6, and the weight of other areas is 0.4.

[0120] 3. Shooting Rules C

[0121] 3.1 When a single face area appears and there is frontal spotlighting, in order to highlight the main character, control the focus window and metering window to the main character's face ROI, and select spot metering mode for metering.

[0122] In some embodiments, a general shooting rule (as a preset shooting rule) can also be pre-defined. When the electronic device identifies that the stage scene being shot does not belong to the above-mentioned first-level stage scene, second-level stage scene, and third-level stage scene, or identifies that the confidence level of the stage level (first-level stage scene, second-level stage scene, or third-level stage scene) to which the scene being shot belongs is low (e.g., confidence level less than 50%, 45%, 40%, etc.), in order to avoid large deviations in the overall exposure and color parameters of the shot image, such as ensuring that the overall exposure and color parameters of the shot image are roughly correct and that the brightness areas of the shot image are properly exposed, the electronic device can use the general shooting rule to shoot the current shooting scene.

[0123] For example, a general shooting rule could be: when the stage type and light source position of the shooting scene are unclear, such as when the confidence level of detecting the stage type and light source position (light source type and light position type) of the current shooting scene is low, if there are no human faces in the scene, use the center area of ​​the stage as the focus area of ​​the focus window and the bright area as the metering area of ​​the metering window to ensure that the bright area is properly exposed, without having to ensure whether the dark area is properly exposed.

[0124] In some embodiments, during the shooting process of the electronic device, the electronic device can use a 3A statistical decision-maker to determine the shooting rules of the current shooting scene, and then shoot the current shooting scene according to the shooting rules to obtain the corresponding image.

[0125] Figure 2 This is a schematic diagram illustrating the working principle of the 3A statistical decision-maker provided in this embodiment. The 3A statistical decision-maker will be described below.

[0126] refer to Figure 2 The 3A statistical decision-maker includes a Level 1 stage image decision package, a Level 2 stage image decision package, a Level 3 image decision package, and a general escape image decision package. The Level 1 stage image decision package contains shooting rule A, the Level 2 stage image decision package contains shooting rule B, the Level 3 stage image decision package contains shooting rule C, and the general escape image decision package (as a Level 0 stage scene image decision package) contains general shooting rules.

[0127] When the electronic device takes a picture, it can capture a preview image of the scene to determine if it is a stage scene. Then, it uses this preview image to perform primary scene recognition to identify if the scene is a stage. If the electronic device identifies the scene as a stage, it can perform secondary scene recognition (stage type recognition) on the preview image, as well as light source position detection, human body detection, face detection, motion detection, and camera position detection. This yields secondary scene recognition results, light source position information, human body ROI information, face ROI information, motion information, and camera position information, which are then input into the 3A statistical decision-making unit. The 3A statistical decision-making unit then uses the secondary scene recognition results as a reference to determine the stage level of the scene based on the light source position information. It selects the corresponding stage scene image decision package and, according to the shooting rules of this package, determines the shooting parameters based on the human body ROI information, face ROI information, motion information, and camera position information. These parameters are then sent to the camera module (the software module responsible for adjusting the shooting parameters). Then, the camera adjusts the current shooting parameters of the electronic device to the shooting parameters determined by the 3A statistical decision-maker, and uses these shooting parameters to capture the current shooting scene and obtain the corresponding image.

[0128] It's understandable that Level 2 scene recognition identifies the stage type of the shooting scene. Light source and position detection detects the type and position of light sources in the shooting scene. Human detection detects the area where a human is located in the shooting scene. Face detection detects the area where a face is located in the shooting scene. Motion detection detects the state of human movement during shooting. Camera position detection detects the camera position, that is, the location of the electronic device.

[0129] It is understandable that the secondary recognition result can be one of the following stage types: gala, performance, concert, music festival, e-sports competition, press conference, drama, play, stage play, musical, sitcom, bar, live music venue, talk show, etc.

[0130] Light source position information includes light source type, position type, and number of light sources. Human ROI information includes the area of ​​the human body in the shooting scene. Face ROI information includes the area where the face is located in the shooting scene. Motion information includes the motion state of the human body in the shooting scene. Camera position information includes the location of electronic devices.

[0131] refer to Figure 3After the electronic device inputs light source position information, human ROI information, facial ROI information, motion information, and camera position information into the 3A statistical decision-making unit, the 3A statistical decision-making unit selects the X-level stage scene image decision package corresponding to the current shooting scene based on the input information. Then, according to the shooting rules of the X-level stage scene image decision package, it determines the shooting parameters based on the human ROI information, facial ROI information, motion information, and camera position information, and sends them to the camera side. The camera side then shoots the current shooting scene according to the shooting parameters determined by the A statistical decision-making unit. The X-level stage scene image decision package is one of the following image decision packages: Level 1 stage image decision package, Level 2 stage image decision package, Level 3 stage image decision package, and general escape image decision package.

[0132] It should be noted that the secondary scene recognition is an optional step. The recognition results obtained from the secondary scene recognition serve as a reference for the 3A statistical decision-maker in selecting the stage image decision package, thus improving the accuracy of the 3A statistical decision-maker's selection.

[0133] In some embodiments, the electronic device may not perform secondary scene recognition on the current shooting scene, but directly input the light source position information, human ROI information, face ROI information, motion information and camera position information into the 3A statistical decision unit. The 3A statistical decision unit determines the stage level to which the current shooting scene belongs based on the light source position information, and then selects the stage image decision package corresponding to the stage level.

[0134] Table 4 below shows the input information for the 3A statistical decision maker.

[0135] Table 4

[0136]

[0137] As shown in Table 4, the light source position information input to the 3A statistical decision-maker includes light source type, human ROI information, face ROI information, motion information, camera position information, and secondary scene recognition results. The light source position information includes light source type, tracking light (present / absent), screen (present / absent), and number of light sources. The camera position information input to the A statistical decision-maker includes the following:

[0138] Directly in front: This indicates that the electron is located within the first distance directly in front of the stage;

[0139] Center: This indicates that the electron is located between the first and second distances directly in front of the stage;

[0140] Directly behind: This indicates that the electron is located between the second and third distances directly in front of the stage;

[0141] Zhengyuan: Indicates that the electron is located between the third and fourth distances directly in front of the stage;

[0142] Positive distance: indicates that the electron is located at a distance of four units directly in front of the stage;

[0143] Front left: This indicates that the electronic device is located within the first distance from the front left of the stage;

[0144] Left center: This indicates that the electron is located between the first and second distances in front of the left side of the stage;

[0145] Left rear: This indicates that the electron is located between the second and third distances from the left front of the stage;

[0146] Left Far: This indicates that the electron is located between the third and fourth distances to the left front of the stage;

[0147] Left Chaoyuan: This indicates that the electron is located four distances away from the left front of the stage;

[0148] Right front: Indicates that the electron is located within the first distance to the right front of the stage;

[0149] Right center: This indicates that the electron is located between the first and second distances on the right front of the stage;

[0150] Right rear: This indicates that the electron is located between the second and third distances to the right front of the stage;

[0151] Right far: This indicates that the electron is located between the third and fourth distances to the right front of the stage;

[0152] Right super far: indicates that the electron is located beyond the fourth distance to the right left front of the ball.

[0153] It is understood that the first distance is less than the second distance, the second distance is less than the third distance, and the third distance is less than the fourth distance. In some embodiments, the first, second, third, and fourth distances can be set according to the actual scenario and are not limited thereto. For example, the first distance can be 10m, the second distance can be 32m, the third distance can be 99m, and the fourth distance can be 200m.

[0154] Figure 4 The schematic diagram of light source position detection is shown.

[0155] In some embodiments, reference Figure 4 The electronic device can capture a preview image of the current shooting scene, and then input the preview image into the trained light source position detection model to obtain light source position information such as light source type, number of light sources, and position type output by the light source position detection model.

[0156] It is understandable that the light source detection model can be an image detection model based on deep learning methods, such as a convolutional neural network model, a fully convolutional network model, or a generative adversarial network model.

[0157] In some embodiments, images with varying degrees of light complexity—that is, images with different types and positions of light sources—can be acquired as sample images for training the light source position detection model. These sample images are then input into the light source position detection model to be trained. The model performs light source position detection on the sample images and outputs predicted light source position information. A loss function is then calculated based on the difference between the predicted light source position information output by the model and the corresponding true light source position information. The model parameters are then adjusted according to this loss function. Training ends when the light source position detection model achieves the expected results, the loss function converges, or the number of training iterations reaches a set number.

[0158] The following sections introduce the Level 1 Stage Image Decision Package, Level 2 Stage Image Decision Package, Level 3 Stage Image Decision Package, and General Escape Image Decision Package.

[0159] (1) Level 1 Stage Image Decision Package

[0160] As shown in Table 5 below, the Level 1 stage image decision package includes shooting rule A corresponding to the Level 1 stage scene. The Level 1 stage scene has the highest complexity of lighting position types and the most types of light sources. The subjects on the stage often present a state of multiple people, multiple faces, and multiple subject relationships. Its lighting methods are often seen in stage scenes such as galas, performances, concerts, music festivals, and e-sports competitions.

[0161] In some embodiments, when the input information of the 3A statistical decision-maker meets the input conditions of light source type and light position type shown in Table 5 below, the 3A statistical decision-maker will select the first-level stage image decision package.

[0162] For example, when the input information of the 3A statistical decision-maker is {light position type: front light source, side light source, top light source, backlight source, first background light source; light source type: spotlight, diffused light, soft light, imaging light}, the 3A statistical decision-maker can select the first-level stage scene decision package. It can be understood that the first background light source includes screen light sources and signage light sources.

[0163] Table 5

[0164]

[0165]

[0166] (2) Second-level stage image decision package

[0167] As shown in Table 6 below, the secondary stage image decision package includes shooting rule B corresponding to the secondary stage scene. Compared with the primary stage scene, the secondary stage scene has lower lighting complexity and fewer light source types. Its lighting methods are mostly found in stage scenes such as press conferences, dramas, plays, stage plays, musicals, and situational dramas.

[0168] In some embodiments, when the input information of the 3A statistical decision-maker meets the input conditions of light source type and light position type shown in Table 6 below, the 3A statistical decision-maker will select the secondary stage image decision package.

[0169] For example, when the input information of the 3A statistical decision-maker is {light position type: front light source, side light source, second background light source; light source type: spotlight, diffused light, soft light}, the 3A statistical decision-maker can select a secondary stage image decision package. It can be understood that the second background light source includes screen light sources.

[0170] Table 6

[0171]

[0172]

[0173] (3) Three-level stage image decision package

[0174] As shown in Table 7 below, the Level 3 stage image decision package includes shooting rule B corresponding to the Level 2 stage scene. The Level 3 stage scene has the lowest complexity of lighting type and the fewest types of light sources. Its lighting methods are mostly found in stage scenes such as bars, live music venues, and stand-up comedy shows.

[0175] In some embodiments, when the input information of the 3A statistical decision-maker meets the input conditions of light source type and light position type shown in Table 7 below, the 3A statistical decision-maker will select the three-level stage image decision package.

[0176] For example, when the input information for the 3A statistical decision-maker is {front light source, side light source, third background light source; light source type: spotlight, diffused light, soft light}, the 3A statistical decision-maker can select a three-level stage scene decision package. It can be understood that the third background light source includes signage light sources.

[0177] Table 7

[0178]

[0179]

[0180] (4) Escape general image decision package

[0181] As shown in Table 8 below, the general escape image decision package includes general shooting rules. When the light source position information input to the 3A statistical decision unit does not meet the input conditions of light position type and light source type shown in Tables 5, 6 and 7 above, and the secondary scene recognition result input to the 3A decision unit is unclear or does not belong to the above-mentioned primary stage scene, secondary stage scene and tertiary stage scene, the 3A statistical decision unit can select the general escape image decision package.

[0182] Table 8

[0183]

[0184] Figure 5 This is a flowchart illustrating a shooting method provided in an embodiment of this application.

[0185] refer to Figure 5 The shooting method includes the following steps:

[0186] S101: Electronic device captures preview images of the shooting scene.

[0187] When an electronic device is taking a picture, it can capture a preview image of the current shooting scene.

[0188] For example, refer to Figure 6 When a user opens the camera application of mobile phone 100 to take a picture of stage B01, mobile phone 100 can capture a preview image 15 of stage B01.

[0189] S102: The electronic device identifies the scene type of the shooting scene based on the type and location of the light source in the preview image.

[0190] In some embodiments, the scene type of a shooting scene can be determined by the type and location of the light source. For example, for a stage scene, the scene type (i.e., stage level) can be divided into the aforementioned Level 1 stage scene, Level 2 stage scene, and Level 3 stage scene. The specific division method can be referred to the relevant introduction in Table 3 above, and will not be repeated here.

[0191] In some embodiments, the electronic device can perform light source position detection on the preview image to obtain the light source position information of the current shooting scene, and then identify the scene type, i.e., the stage level, based on the light source information.

[0192] In some embodiments, refer to the above Figure 4 Electronic devices can input preview images into a light source position detection model, which then performs light source position detection on the preview image and outputs light source position information such as light source type, number of light sources (not a necessary parameter), and position type.

[0193] In some embodiments, refer to the above Figure 3 The electronic device can input the light position information of the light source into the aforementioned 3A statistical decision-making unit, which will then determine the stage level of the current shooting scene based on the input light position information.

[0194] For example, as shown in Table 3 above, if the light source position information input to the 3A statistical decision-maker is {light source type: spotlight, diffused light, soft light, imaging light; light position type: front light source, side light source, top light source, backlight source, first background light source}, then the 3A statistical decision-maker can determine that the current shooting scene belongs to a level one stage scene. If the light source position information input to the 3A statistical decision-maker is {light source type: spotlight, diffused light, soft light; light position type: front light source, side light source, second background light source (screen light source)}, then the 3A statistical decision-maker can determine that the current shooting scene belongs to a level two stage scene. If the light source position information input to the 3A statistical decision-maker is {light source type: spotlight, diffused light, soft light; light position type: front light source, side light source, third background light source (signboard light source)}, then the 3A statistical decision-maker can determine that the current shooting scene belongs to a level three stage scene.

[0195] In other embodiments, the electronic device can first perform primary scene recognition on the current shooting scene using a preview image to determine whether the current shooting scene is a stage scene. When the electronic device recognizes that the current shooting scene is a stage scene, it can perform secondary scene recognition on the current shooting scene using the preview image to identify the stage type to which the current shooting scene belongs, and then determine the stage level to which the current shooting scene belongs based on the stage type.

[0196] It is understandable that stage types include, but are not limited to, galas, performances, concerts, music festivals, e-sports competitions, press conferences, dramas, plays, stage plays, musicals, sitcoms, bars, live music venues, and stand-up comedy.

[0197] For example, as shown in Table 3 above, if the secondary scene recognition result indicates that the current shooting scene is a concert, then the current shooting scene belongs to the primary stage scene. If the secondary scene recognition result indicates that the current shooting scene is a press conference, then the current shooting scene belongs to the secondary stage scene. If the secondary scene recognition result indicates that the current shooting scene is a bar, then the current shooting scene belongs to the tertiary stage scene.

[0198] For example, refer to Figure 6After capturing a preview image 15 of stage B01, mobile phone 100 identifies the stage scene type of stage B01 as a concert through the preview image 15. It can then display the prompt text "Concert" on the preview image 15 to inform the user that the currently captured scene is a concert. In this case, mobile phone 100 can determine that stage B01 belongs to a Level 1 stage scene.

[0199] In other embodiments, the electronic device may also input the secondary scene recognition results and light source position information together into the 3A statistical decision unit, which will then determine the stage level of the current shooting scene based on the light source position information and the secondary scene recognition results.

[0200] In some cases, when the light source position information input to the 3A statistical decision-maker does not meet the input conditions of the light source position shown in Tables 5 to 7 above, the 3A statistical decision-maker can determine the stage level to which the current shooting scene belongs based on the secondary scene recognition results.

[0201] For example, the light source position information input to the 3A statistical decision-maker is {light source type: front light source, side light source; light source type: spotlight, diffused light}, and the secondary scene recognition result is a live music venue. Because this light source position information does not meet the input conditions shown in Tables 5-7 above, the 3A statistical decision-maker cannot identify the stage level of the current shooting scene based on this light source position information. In this case, since the secondary scene recognition result—live music venue—belongs to a secondary stage scene, the 3A statistical decision-maker can determine that the current shooting scene belongs to a secondary stage scene based on the secondary scene recognition result.

[0202] In other cases, when the confidence level of the secondary scene recognition result is low, the 3A statistical decision-maker can determine the stage level of the current shooting scene based on the input light source position information.

[0203] For example, if the secondary scene recognition result is a concert with a confidence level of 30% (lower than the preset confidence level (e.g., 70%, 80%, 85%)), the light source position information input to the 3A statistical decision-making unit is {light source type: spotlight, diffused light, soft light; light position type: front light source, side light source, top light source, backlight source, first background light source}. Because the confidence level of the secondary scene recognition result is low, the accuracy of determining the stage level of the current shooting scene based on the secondary scene recognition result is low. In this case, since the light source position information input to the 3A statistical decision-making unit meets the input conditions for light source positions shown in Table 5 above, the 3A statistical decision-making unit can determine that the current shooting scene belongs to a primary stage scene based on this light source position information.

[0204] S103: The electronic device uses the shooting rules corresponding to the determined scene type to determine the shooting parameters.

[0205] In some embodiments, the electronic device can obtain scene information of the current shooting scene based on the preview image, such as performing human detection, face detection, motion detection, and camera position detection on the preview image to obtain human ROI information, face ROI information, motion information, and camera position information of the current shooting scene. Then, the electronic device can input the scene information of the current shooting scene into the aforementioned 3A statistical decision-making unit, which determines the corresponding shooting parameters based on the scene information of the current shooting scene and the shooting rules corresponding to the scene type of the current shooting scene.

[0206] As can be understood, scene information includes, but is not limited to, human ROI information, face ROI information, motion information, and camera position information. Shooting parameters include, but are not limited to, the size and position parameters of the focus window, metering window, and color window, shutter parameters (such as shutter priority), metering mode, etc. The color window is used to detect color temperature.

[0207] It is understandable that, when the current shooting scene is a primary stage scene, the electronic device can determine the corresponding shooting parameters according to shooting rule A shown in Table 5 above, based on the scene information of the current shooting scene.

[0208] For example, if the current shooting scene is a concert (a primary stage scene) and there are multiple people present, it meets rule 3 of shooting rule A. In this case, the electronic device can control the focus window and metering window to the human ROI, use partial metering mode for metering, and then use an after-effect algorithm to determine the exposure parameters based on the metering results.

[0209] It is understandable that, when the current shooting scene is a secondary stage scene, the electronic device can determine the corresponding shooting parameters according to shooting rule B shown in Table 6 above, based on the scene information of the current shooting scene.

[0210] For example, if the current shooting scene is a press conference (a secondary stage scene) and contains multiple people and faces, it meets the requirements of rule 5 of shooting rule B. In this case, the electronic device can use center-weighted metering mode to meter and activate shutter priority mode, and then use the AE algorithm to determine the exposure parameters based on the metering results.

[0211] It is understandable that, given that the current shooting scene is a level three stage scene, the electronic device can determine the corresponding shooting parameters based on the scene information of the current shooting scene, according to shooting rule C shown in Table 7 above.

[0212] For example, if the current shooting scene is a bar (a level 3 stage scene) and features a single face with frontal backlighting to highlight the main character, it meets shooting rule C. In this case, the electronic device can control the focus window and metering window to the ROI of the main character's face, select spot metering mode for metering, and then use the AE algorithm to determine the exposure parameters based on the metering results.

[0213] For example, refer to Figure 6 The mobile phone 100 detects that the current shooting scene is a concert, which is a Level 1 stage scene. There is a single face area on the stage, which meets the requirements of Rule A, 3. Furthermore, there is no screen on the stage. Therefore, the mobile phone 100 can control the focus window Q1 and metering window Q2 to focus on the face area on the stage. The focus window Q1 and metering window Q2 overlap. Then, the mobile phone 100 can measure the average light intensity within metering window Q2 and use the AE algorithm to determine the exposure parameters of the preview image 15 based on the average light intensity within metering window Q2.

[0214] In some embodiments, when the electronic device identifies that the currently captured stage scene does not belong to the aforementioned Level 1, Level 2, or Level 3 stage scenes, or identifies that the confidence level of the stage level (Level 1, Level 2, or Level 3 stage scene) to which the currently captured scene belongs is low, the electronic device can determine the corresponding shooting parameters based on the scene information of the currently captured scene and through the aforementioned general shooting rules. Please refer to the relevant introduction in Table 8 above, which will not be repeated here.

[0215] It is understandable that the preview image captured by the electronic device before shooting can be determined based on the current shooting scene information using this general shooting rule.

[0216] S104: The electronic device detects the shooting command, and captures the first image of the shooting scene by using the determined shooting parameters.

[0217] In some embodiments, when an electronic device detects a shooting command, it can take a picture of the current shooting scene using predetermined shooting parameters to obtain a first image. Shooting commands include, but are not limited to, instructions to the electronic device to take a picture, voice commands, and gesture commands (such as air gestures).

[0218] For example, refer to Figure 7 When the mobile phone 100 detects that the user clicks the shooting button 16, the mobile phone 100 takes a picture of the stage B01 using the determined shooting parameters to obtain image M2 (as an example of the first image).

[0219] In this embodiment, the electronic device can identify the scene type of the shooting scene, and then determine the shooting parameters corresponding to the shooting rules for that scene type based on the scene information. It then uses these shooting parameters to capture the current shooting scene and obtain the corresponding image. Thus, for different types of shooting scenes, the electronic device can use different shooting rules instead of just a default rule. Using different shooting rules allows the electronic device to flexibly select appropriate shooting parameters, thereby improving the image quality of the captured image.

[0220] Figure 8 A flowchart illustrating another shooting method provided in an embodiment of this application.

[0221] refer to Figure 8 The shooting method includes the following steps:

[0222] S201: Electronic device captures preview images of the shooting scene.

[0223] Step S201 is essentially the same as step S101 above, and will not be repeated here.

[0224] S202: The electronic device identifies the scene type of the shooting scene based on the preview image. The scene type is classified based on the type and location of the light source.

[0225] In some embodiments, the electronic device can obtain the light source position information of the shooting scene based on the preview image. The light source position information includes the type and position of the light source in the shooting scene, and then determine the scene type to which the shooting scene belongs based on the light source position information.

[0226] The light source position information indicates that the types of light sources in the shooting scene include spotlight, diffused light, soft light, and imaging light. In addition, the positions of the light sources include front light sources, side light sources, top light sources, backlight sources, and first background light sources. The scene type of the shooting scene is a first-level stage scene.

[0227] The light source position information indicates that the type of light source in the shooting scene includes spotlight, diffused light, and soft light. In addition, the position of the light source includes front light source, side light source, top light source, backlight source, and second background light source. The scene type of the shooting scene is a secondary stage scene.

[0228] The light source position information indicates that the types of light sources in the shooting scene include spotlight, diffused light, and soft light. In addition, the positions of the light sources include front light sources, side light sources, and third background light sources. The scene type of the shooting scene is a level three stage scene.

[0229] In some embodiments, the electronic device may also perform primary scene recognition on the preview image to obtain a primary scene recognition result, which corresponds to a stage scene. It may also perform secondary scene recognition on the preview image to obtain a secondary scene recognition result, and determine the scene type to which the shooting scene belongs based on the secondary scene recognition result.

[0230] The corresponding secondary scene recognition result is one of the following, and the scene type of the shooting scene is a primary stage scene: gala, concert, music festival and e-sports competition.

[0231] The corresponding secondary scene recognition result is one of the following, and the scene type of the shooting scene is a secondary stage scene: press conference, drama, play, stage play, musical, and situational drama.

[0232] The corresponding level 2 scene recognition result is one of the following, and the scene type of the shooting scene is a level 3 stage scene: bar, live music venue, stand-up comedy.

[0233] S203: The electronic device determines the shooting parameters corresponding to the shooting rules for the scene type based on the scene information of the shooting scene.

[0234] In some embodiments, corresponding to a Level 1 stage scene, the electronic device may use a first shooting rule to determine the shooting parameters based on the scene information. Alternatively, corresponding to a Level 2 stage scene, the electronic device may use a second shooting rule to determine the shooting parameters based on the scene information. Alternatively, corresponding to a Level 3 stage scene, the electronic device may use a third shooting rule to determine the shooting parameters based on the scene information.

[0235] In some embodiments, a first shooting rule is used to determine shooting parameters based on scene information, including:

[0236] Meter the light in the center area of ​​the stage in the shooting scene, and determine the exposure parameters based on the metering results.

[0237] Alternatively, corresponding to a shooting scene that includes a screen, meter the area where the screen is located, and determine the exposure parameters based on the metering result; or...

[0238] For shooting scenes that include people, a partial metering mode is used to meter the area where the people are located, and the exposure parameters are determined based on the metering results.

[0239] Alternatively, for shooting scenes that include people, spot lighting mode can be used to meter the face area of ​​one of the people, and the exposure parameters can be determined based on the metering results.

[0240] In some embodiments, a second shooting rule is used to determine shooting parameters based on scene information, including:

[0241] Meter the light in the center area of ​​the stage in the shooting scene, and determine the exposure parameters based on the metering results.

[0242] Alternatively, if the shooting scene includes a screen, meter the area where the screen is located, and determine the exposure parameters based on the metering results.

[0243] Alternatively, if the shooting scene includes people, use partial metering mode to meter the area where the people are located, and determine the exposure parameters based on the metering results.

[0244] Alternatively, for shooting scenes that include people, spot lighting mode can be used to meter the face area of ​​one of the people, and the exposure parameters can be determined based on the metering results.

[0245] Alternatively, if the shooting scene includes people, use center-weighted metering mode to meter the area where the people are located, and determine the exposure parameters based on the metering results.

[0246] In some embodiments, a third shooting rule is used to determine shooting parameters based on scene information, including:

[0247] For shooting scenes that include people, spot side lighting mode is used to meter the face area of ​​one of the people, and the exposure parameters are determined based on the metering results.

[0248] It is understood that the first shooting rule can be the aforementioned shooting rule A, the second shooting rule can be the aforementioned shooting rule B, and the third shooting rule can be the aforementioned shooting rule C. For details, please refer to the relevant introductions of the aforementioned shooting rules A, B, and C, which will not be repeated here.

[0249] In other embodiments, for scenes that do not belong to the first-level stage scene, the second-level stage scene, or the third-level stage scene, the shooting parameters are determined based on the scene information using preset shooting rules.

[0250] S204: The electronic device detects the shooting command, and captures the first image of the shooting scene by using the determined shooting parameters.

[0251] Step S204 is essentially the same as step S104 above, and will not be repeated here.

[0252] Figure 9A schematic diagram of the structure of electronic device 1000 is shown. Electronic device 1000 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, antenna 1, antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, buttons 190, a motor 191, an indicator 192, a camera 193, a screen 10, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0253] In some embodiments, the internal memory 121 may store shooting rules corresponding to each scene type, as well as the first image obtained after shooting.

[0254] In some embodiments, during the process of the electronic device 1000 capturing the current shooting scene, the camera 193 of the electronic device 1000 can acquire a preview image of the current shooting scene. When the electronic device 1000 detects a shooting command, the camera 193 of the electronic device 1000 can capture the current shooting scene to obtain a first image.

[0255] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device 1000. In other embodiments of this application, the electronic device 1000 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0256] Processor 110 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU). In some embodiments, processor 110 may include one or more interfaces. Interfaces may include inter-integrated circuit (I2C) interfaces, inter-integrated circuit sound (I2S) interfaces, pulse code modulation (PCM) interfaces, universal asynchronous receiver / transmitter (UART) interfaces, mobile industry processor interfaces (MIPI), general-purpose input / output (GPIO) interfaces, and subscriber identification module (SIM) interfaces.

[0257] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via a USB interface 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of the electronic device 1000. While charging the battery 142, the charging management module 140 can also supply power to the electronic device via the power management module 141.

[0258] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, screen 10, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.

[0259] The wireless communication function of the electronic device 1000 can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor, and baseband processor.

[0260] The mobile communication module 150 can provide wireless communication solutions, including 2G / 3G / 4G / 5G, for use on the electronic device 1000. The wireless communication module 160 can provide wireless communication solutions, including wireless local area networks (WLANs) (such as Wi-Fi), Bluetooth, GNSS, frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies, for use on the electronic device 1000. In some embodiments, antenna 1 of the electronic device 1000 is coupled to the mobile communication module 150, and antenna 2 is coupled to the wireless communication module 160, enabling the electronic device 1000 to communicate with networks and other devices via wireless communication technologies.

[0261] The electronic device 1000 implements display functions through a GPU, a screen 10, and an application processor. The GPU is a microprocessor for image processing, connected to the screen 10 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0262] Screen 10 is used to display images, videos, etc. Screen 10 includes a display panel. In some embodiments, electronic device 1000 may include one or N screens 10, where N is a positive integer greater than 1.

[0263] Electronic device 1000 can achieve shooting function through ISP, camera 193, video codec, GPU, screen 10 and application processor.

[0264] The external storage interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 1000. The external memory card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external memory card.

[0265] Internal memory 121 can be used to store computer executable program code, which includes instructions. Internal memory 121 may include a program storage area and a data storage area. Electronic device 1000 can implement audio functions, such as music playback and recording, through audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor.

[0266] The embodiments disclosed in this application can be implemented in hardware, software, firmware, or a combination of these implementation methods. Embodiments of this application can be implemented as computer programs or program code executable on a programmable system, the programmable system including at least one processor, a storage system (including volatile and non-volatile memory and / or storage elements), at least one input device, and at least one output device.

[0267] Program code can be applied to input instructions to execute the functions described in this application and generate output information. The output information can be applied to one or more output devices in a known manner. For the purposes of this application, the processing system includes any system having a processor such as, for example, a digital signal processor, a microcontroller, an application-specific integrated circuit, or a microprocessor.

[0268] The program code can be implemented using a high-level procedural language or an object-oriented programming language to communicate with the processing system. Assembly language or machine language can also be used when needed. In fact, the mechanisms described in this application are not limited to any particular programming language. In either case, the language can be a compiled language or an interpreted language.

[0269] In some cases, the disclosed embodiments may be implemented in hardware, firmware, software, or any combination thereof. The disclosed embodiments may also be implemented as instructions carried or stored thereon on one or more temporary or non-temporary machine-readable (e.g., computer-readable) storage media, which may be read and executed by one or more processors. For example, the instructions may be distributed via a network or through other computer-readable media. Therefore, machine-readable media may include any mechanism for storing or transmitting information in a machine-readable (e.g., computer-readable) form, including but not limited to floppy disks, optical disks, optical discs, read-only memory, magneto-optical disks, random access memory, erasable programmable read-only memory, electrically erasable programmable read-only memory, magnetic cards or optical cards, flash memory, or tangible machine-readable storage for transmitting information (e.g., carrier waves, infrared signals, digital signals, etc.) using the Internet in the form of electrical, optical, acoustic, or other propagation signals. Therefore, machine-readable media include any type of machine-readable medium suitable for storing or transmitting electronic instructions or information in a machine-readable (e.g., computer-readable) form.

[0270] In the accompanying drawings, some structural or methodological features may be shown in a specific arrangement and / or order. However, it should be understood that such a specific arrangement and / or order may not be necessary. Rather, in some embodiments, these features may be arranged in a manner and / or order different from that shown in the illustrative drawings. Furthermore, the inclusion of structural or methodological features in a particular figure does not imply that such features are required in all embodiments, and in some embodiments, these features may be omitted or may be combined with other features.

[0271] It should be noted that all units / modules mentioned in the device embodiments of this application are logical units / modules. Physically, a logical unit / module can be a physical unit / module, a part of a physical unit / module, or a combination of multiple physical units / modules. The physical implementation of these logical units / modules themselves is not the most important factor; the combination of functions implemented by these logical units / modules is the key to solving the technical problems proposed in this application. Furthermore, to highlight the innovative aspects of this application, the above-described device embodiments of this application have not introduced units / modules that are not closely related to solving the technical problems proposed in this application. This does not mean that the above-described device embodiments do not contain other units / modules.

[0272] It should be noted that in the examples and description of this application, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one" does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0273] Although this application has been illustrated and described with reference to certain preferred embodiments thereof, those skilled in the art will understand that various changes in form and detail may be made thereto without departing from the scope of this application.

Claims

1. A shooting method for electronic devices, characterized in that, The method includes: Capture preview images of the shooting scene; Based on the preview image, the scene type of the shooting scene is identified, and the scene type is classified based on the type and location of the light source; Based on the scene information of the shooting scene, the shooting parameters corresponding to the shooting rules corresponding to the scene type are determined; In response to the detected shooting command, the shooting scene is captured using the determined shooting parameters to obtain a first image.

2. The method according to claim 1, characterized in that, The step of identifying the scene type of the shooting scene based on the preview image includes: Based on the preview image, the light source position information of the shooting scene is obtained, and the light source position information includes the type and position of the light source in the shooting scene; Based on the light source position information, the scene type to which the shooting scene belongs is determined.

3. The method according to claim 2, characterized in that, Determining the scene type of the shooting scene based on the light source position information includes: The light source position information indicates that the type of light source in the shooting scene includes spotlight, diffused light, soft light and imaging light, and the position of the light source includes front light source, side light source, top light source, backlight source and first background light source. The scene type of the shooting scene is a first-level stage scene. The light source position information indicates that the type of light source in the shooting scene includes spotlight, diffused light, and soft light, and the position of the light source includes front light source, side light source, top light source, backlight source, and second background light source. The scene type of the shooting scene is a secondary stage scene. The light source position information indicates that the type of light source in the shooting scene includes spotlight, diffused light, and soft light, and the position of the light source includes front light source, side light source, and third background light source. The scene type of the shooting scene is a level three stage scene.

4. The method according to claim 1, characterized in that, The step of identifying the scene type of the shooting scene based on the preview image also includes: Perform first-level scene recognition on the preview image to obtain the first-level scene recognition result; Corresponding to the first-level scene recognition result being a stage scene, the preview image is then subjected to second-level scene recognition to obtain the second-level scene recognition result; Based on the secondary scene recognition results, the scene type to which the shooting scene belongs is determined.

5. The method according to claim 4, characterized in that, The step of determining the scene type of the shooting scene based on the secondary scene recognition result includes: The scene type of the shooting scene is a primary stage scene, corresponding to one of the following secondary scene recognition results: gala, concert, music festival and e-sports competition; The scene type of the shooting scene is a secondary stage scene, corresponding to one of the following secondary scene recognition results: press conference, drama, play, stage play, musical, and situational drama; The scene type corresponding to the secondary scene recognition result is one of the following: the scene type of the shooting scene is a tertiary stage scene: bar, live music venue, stand-up comedy.

6. The method according to claim 3 or 5, characterized in that, The step of determining the shooting parameters corresponding to the shooting rules for the scene type based on the scene information of the shooting scene includes: Corresponding to the scene type being the first-level stage scene, the shooting parameters are determined based on the scene information using the first shooting rule; or, Corresponding to the scene type being the secondary stage scene, the shooting parameters are determined based on the scene information using the second shooting rule; or, Corresponding to the scene type of the third-level stage scene, the shooting parameters are determined based on the scene information using the third shooting rule.

7. The method according to claim 6, characterized in that, The step of determining the shooting parameters based on the scene information using the first shooting rule includes: Meter the light in the center area of ​​the stage in the shooting scene, and determine the exposure parameters based on the metering results; or, Corresponding to the shooting scene including a screen, metering is performed on the area where the screen is located, and the exposure parameters are determined based on the metering results; or, For shooting scenes that include people, a partial metering mode is used to meter the area where the person is located, and the exposure parameters are determined based on the metering results; or, Since the shooting scene includes people, a spot side lighting mode is used to meter the facial area of ​​one of the people, and the exposure parameters are determined based on the metering results.

8. The method according to claim 6, characterized in that, The step of determining the shooting parameters based on the scene information using the second shooting rule includes: Meter the light in the center area of ​​the stage in the shooting scene, and determine the exposure parameters based on the metering results; or, Corresponding to the shooting scene including a screen, metering is performed on the area where the screen is located, and the exposure parameters are determined based on the metering results; or, For shooting scenes that include people, a partial metering mode is used to meter the area where the person is located, and the exposure parameters are determined based on the metering results; or, For shooting scenes that include people, spot lighting is used to meter the facial area of ​​one of the people, and the exposure parameters are determined based on the metering results; or, Since the shooting scene includes people, the center-weighted metering mode is used to meter the area where the people are located, and the exposure parameters are determined based on the metering results.

9. The method according to claim 6, characterized in that, The step of determining the shooting parameters based on the scene information using a third shooting rule includes: Since the shooting scene includes people, a spot side lighting mode is used to meter the face area of ​​one of the people, and the exposure parameters are determined based on the metering results.

10. The method according to claim 6, characterized in that, The step of determining the shooting parameters corresponding to the shooting rules for the scene type based on the scene information of the shooting scene further includes: For the scene types that do not belong to the first-level stage scene, the second-level stage scene, and the third-level stage scene, the shooting parameters are determined based on the scene information using preset shooting rules.

11. An electronic device, characterized in that, include: Memory, used to store instructions; At least one processor is configured to execute the instructions to cause the electronic device to implement the method of any one of claims 1 to 10.

12. A computer-readable storage medium, characterized in that, The readable storage medium stores instructions that, when executed on a computer, cause the computer to perform the method of any one of claims 1 to 10.

13. A computer program product, characterized in that, When the computer program product is run on the device, it causes the device to perform the method according to any one of claims 1 to 10.

Citation Information

Patent Citations

  • Shooting method and equipment

    CN113905182A

  • Shooting method, shooting parameter training method, electronic equipment and storage medium

    CN115701113A

  • Photometric device and imaging apparatus

    JP2015166767A