Method and electronic equipment for photographing the moon

By combining wide-angle lenses and telephoto lenses in electronic devices, using zoom magnification and exposure parameters to fuse the moon and foreground images, the problem of invisible for the foreground in the moon image in the prior art is solved, and the image presentation of both the moon and the foreground is achieved. Improves the aesthetics and flexibility of shooting the moon.

CN117956299BActive Publication Date: 2024-11-08HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211340119.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-10-29
Publication Date
2024-11-08
Estimated Expiration
2042-10-29

AI Technical Summary

Technical Problem

When photographing the moon, it is difficult for the existing technology to clearly present the moon and the foreground at the same time, resulting in limited aesthetics of the moon images.

Method used

By combining a wide-angle lens and telephoto lens in an electronic device, using zoom magnification and exposure parameters to fuse the moon and foreground images, a clear image presentation of both the moon and foreground is achieved. The specific method includes using a telephoto lens to acquire the moon image and a wide-angle lens to acquire the foreground image when determining that the zoom magnification is greater than or equal to the preset magnification, and performing exposure parameter adjustment and fusion processing to ensure the clarity and brightness of the moon and foreground.

Benefits of technology

It realizes that under the same prospect, users can flexibly adjust the size of the moon body, improve the aesthetics and flexibility of shooting moon images, ensure that the moon and the foreground are clearly visible, and enhance the composition harmony of the image.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117956299B_ABST
    Figure CN117956299B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a method and electronic device for photographing the moon. The method may include: displaying a preview display interface of a camera, wherein the preview display interface includes a first zoom ratio control; when it is determined that the photographed scene is a moon scene, the main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, and the auxiliary preview display interface of the preview display interface displays the wide-angle image acquired by the wide-angle lens; when it is determined that the first zoom ratio is greater than or equal to the first preset ratio, in response to the user's first shooting operation, the first moon image is acquired with the first exposure parameter according to the first zoom ratio through the telephoto lens, and the first foreground image is acquired with the second exposure parameter; the first moon image is merged with the first foreground image to obtain a first target image. The present application can capture a beautiful moon and a clear foreground in the scene of photographing the moon, and present a beautiful picture to the user.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present application relate to the field of electronic technology, and more specifically, to a method and electronic device for photographing the moon. Background Art

[0002] When users use electronic devices to take photos, the moon is often the subject of the photo. When electronic devices take photos of the moon, they generally use low exposure to restore the overexposed moon, then use high dynamic range imaging (HDR) technology to obtain a moon image with a high signal-to-noise ratio, and finally use algorithms to improve the resolution of the moon to obtain a clear moon image.

[0003] However, the moon image only includes a clear moon, and the foreground area is basically invisible, which affects the beauty of the entire moon image. Summary of the invention

[0004] The embodiments of the present application provide a method and electronic device for photographing the moon. The technical solution can capture a beautiful moon and a clear foreground in a scene of photographing the moon, and present a beautiful image to the user.

[0005] In a first aspect, a method for photographing the moon is provided, the method being applied to an electronic device, the electronic device comprising a wide-angle lens and a telephoto lens, the method comprising: the electronic device displaying a preview display interface of a camera, the preview display interface comprising a first zoom ratio control, the first zoom ratio control being used to control a first zoom ratio of the telephoto lens; when the electronic device determines that a photographed scene is a moon scene, a main preview display interface of the preview display interface displays an image of the moon acquired by the telephoto lens, and an auxiliary preview display interface of the preview display interface displays a wide-angle image acquired by the wide-angle lens; when the electronic device determines that the first zoom ratio is greater than or equal to a first preset ratio, in response to a first photographing operation of a user, the electronic device acquires a first moon image with a first exposure parameter according to the first zoom ratio through the telephoto lens, and acquires a first foreground image with a second exposure parameter; the electronic device fuses the first moon image with the first foreground image to acquire a first target image.

[0006] In an embodiment of the present application, when the electronic device determines to shoot the moon, the electronic device can display the image of the moon acquired by the telephoto lens in the main preview display interface of the camera, and display the image acquired by the wide-angle lens in the form of picture-in-picture in the auxiliary preview display interface, so that when the user shoots the moon, the moon can be composed according to the foreground image, which is more conducive to the user to take a harmoniously composed moon picture. In addition, when it is determined that the zoom ratio of the electronic device is greater than or equal to the first preset ratio, during the shooting stage, the electronic device acquires the moon image with a high exposure parameter through the telephoto lens, acquires the foreground image with a low exposure parameter, and merges the moon image with the foreground image to obtain the final target image. This is conducive to the user taking a clear picture of the moon subject and the foreground scenery.

[0007] In combination with the first aspect, in an implementation of the first aspect, the preview display interface further includes a second zoom ratio control, the second zoom ratio control is used to control a second zoom ratio for additionally magnifying the moon under the first zoom ratio, and the main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, including: the first moon image magnified according to the second zoom ratio is displayed in the main preview display interface;

[0008] The electronic device fuses the first moon image with the first foreground image, including: the electronic device fuses the first moon image magnified according to the second zoom ratio with the first foreground image.

[0009] In an embodiment of the present application, the preview display interface of the camera may further include a second zoom ratio control for controlling the magnification of the moon subject at the first zoom ratio, and the moon subject in the main preview display interface may be magnified according to the second zoom ratio. During the shooting phase, the electronic device may merge the moon image magnified according to the second zoom ratio with the foreground image to obtain the final picture. This technical solution enables the user to flexibly adjust the size of the moon subject under the same foreground, which is conducive to improving the flexibility of shooting the moon.

[0010] In combination with the first aspect, in an implementation of the first aspect, when the electronic device detects that the user adjusts the first zoom ratio to be less than the first preset ratio, the method further includes: in response to the user's second shooting operation, the electronic device obtains a second moon image through the telephoto lens according to the first zoom ratio, and obtains a first wide-angle image through the wide-angle lens; the electronic device fuses the second moon image magnified according to the second zoom ratio with the first wide-angle image to obtain a second target picture.

[0011] In the embodiment of the present application, at a higher zoom ratio, due to the poor clarity of the wide-angle lens, the acquired foreground image may be blurred, which is lower than the clarity of the foreground image acquired by the telephoto lens. Therefore, by fusing the foreground image acquired by the telephoto lens with the moon image acquired by the telephoto lens, a target image in which both the moon main body and the foreground are clearly visible can be obtained. When the electronic device switches the zoom ratio to a lower ratio, the wide-angle image acquired by the wide-angle lens has a larger area and a higher clarity. Fusion of the moon image acquired by the telephoto lens with the wide-angle image acquired by the wide-angle lens can make the foreground beautiful and the moon clear. Thus, a fusion solution at full focal length can be achieved.

[0012] In combination with the first aspect, in an implementation manner of the first aspect, the wide-angle image also includes a first display frame, and the first display frame is used to indicate the framing size of the first target image.

[0013] In the embodiment of the present application, the first display frame allows the user to determine the size of the image captured by the telephoto lens, thereby facilitating the user to compose a picture of the moon.

[0014] In combination with the first aspect, in an implementation of the first aspect, the method further includes: in response to a user clicking the wide-angle image or a switch button, the electronic device displays the image of the moon acquired by the telephoto lens in the auxiliary preview display interface, and displays the wide-angle image in the main preview display interface.

[0015] In an embodiment of the present application, the electronic device can support the interchange of the preview display positions of the display interface of the moon image obtained by the telephoto lens and the wide-angle image obtained by the wide-angle lens, so that the user can flexibly switch the preview display interface of the lens when using the electronic device to shoot the moon.

[0016] In combination with the first aspect, in an implementation of the first aspect, before the electronic device merges the first moon image with the first foreground image, the method also includes: the electronic device obtains the center point of the moon in the first moon image and the first foreground image; and the electronic device performs moon alignment processing on the moon in the first moon image and the moon in the first foreground image according to the center point of the moon.

[0017] In the embodiment of the present application, the moon can be aligned during the image fusion process, so that the moon area in the final image is clearer.

[0018] In combination with the first aspect, in an implementation manner of the first aspect, the method further includes: after the electronic device fuses the first moon image with the first foreground image, suppressing the halo of the moon in the fused image.

[0019] In the embodiment of the present application, since there is a strong halo around the moon, the halo can be processed by filtering, AI algorithm, etc. to make the moon halo natural.

[0020] In combination with the first aspect, in an implementation of the first aspect, a main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, and an auxiliary preview display interface of the preview display interface displays the wide-angle image acquired by the wide-angle lens, including: the electronic device performs distribution statistics on the brightness value of the first foreground image to obtain a first brightness value; when it is determined that the first brightness value is less than a preset brightness value, the scenery other than the moon in the first foreground image displays a silhouette effect.

[0021] In the embodiment of the present application, when the foreground includes fewer objects, forcibly increasing the foreground brightness will result in a poor display effect. The embodiment of the present application does not aim to increase the foreground brightness, but displays the objects in the foreground as silhouettes, so that the final picture has a certain artistic beauty.

[0022] In combination with the first aspect, in an implementation manner of the first aspect, the scenery other than the moon in the first target image is displayed as a silhouette effect.

[0023] In a second aspect, an electronic device is provided, comprising: one or more processors; one or more memories; the one or more memories storing one or more computer programs, the one or more computer programs comprising instructions, which, when executed by the one or more processors, enable the method for photographing the moon as described in the first aspect and any possible implementation thereof to be executed.

[0024] In a third aspect, a device for photographing the moon is provided, comprising a module for implementing the method for photographing the moon as described in the first aspect and any possible implementation thereof.

[0025] In a fourth aspect, a chip is provided, comprising a processor and a communication interface, wherein the communication interface is used to receive a signal and transmit the signal to the processor, and the processor processes the signal so that the method for photographing the moon as described in the first aspect and any possible implementation thereof is executed.

[0026] In a fifth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions. When the computer instructions are executed on a computer, the method for photographing the moon as described in the first aspect and any possible implementation thereof is executed.

[0027] In a sixth aspect, a computer program product is provided, the computer program product comprising a computer program code, and when the computer program code is run on a computer, the method for photographing the moon as described in the first aspect and any possible implementation thereof is executed. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application.

[0029] Figure 2 A schematic diagram of the software structure of an electronic device provided in an embodiment of the present application.

[0030] Figure 3 It is a schematic diagram of a group of GUIs provided in an embodiment of the present application.

[0031] Figure 4 It is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application.

[0032] Figure 5 It is a schematic diagram of another set of GUIs provided in an embodiment of the present application.

[0033] Figure 6 It is a schematic diagram of another set of GUIs provided in an embodiment of the present application.

[0034] Figure 7 It is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application.

[0035] Figure 8 It is an exemplary flowchart of a shooting stage provided in an embodiment of the present application.

[0036] Fig. 9 It is a schematic diagram of another set of GUIs provided in an embodiment of the present application.

[0037] Fig.10 It is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application.

[0038] Fig.11 Yes Yes Fig. 9 An exemplary flow chart of the capture phase in FIG.

[0039] Fig.12 It is a schematic diagram of another set of GUIs provided in an embodiment of the present application.

[0040] Fig.13 It is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application. DETAILED DESCRIPTION

[0041] The technical solutions in the embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0042] The display method in the embodiments of the present application can be applied to electronic devices such as smart phones, tablet computers, laptops, personal computers (PCs), ultra-mobile personal computers (UMPCs), netbooks, personal digital assistants (PDAs), vehicle-mounted devices, wearable devices, and foldable devices.

[0043] Figure 1 1 shows a schematic diagram of the structure of the electronic device 100. The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light 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.

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

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

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

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

[0048] In some embodiments, the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0049] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL).

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

[0051] The PCM interface can also be used for audio communication, sampling, quantizing and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 can be coupled via a PCM bus interface.

[0052] The UART interface is a universal serial data bus for asynchronous communication. The bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, the UART interface is generally used to connect the processor 110 and the wireless communication module 160.

[0053] The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 .

[0054] The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 with the camera 193, the display 194, the wireless communication module 160, the audio module 170, the sensor module 180, etc.

[0055] The USB interface 130 is an interface that complies with USB standard specifications, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 may be used to connect a charger to charge the electronic device 100, and may also be used to transmit data between the electronic device 100 and a peripheral device.

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

[0057] The charging management module 140 is used to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger through the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100. While the charging management module 140 is charging the battery 142, it may also power the electronic device through the power management module 141.

[0058] The power management module 141 is used to connect the battery 142 , the charging management module 140 and the processor 110 .

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

[0060] The mobile communication module 150 can provide wireless communication solutions including 2G / 3G / 4G / 5G etc. applied on the electronic device 100 .

[0061] The modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs a sound signal through an audio device (not limited to a speaker 170A, a receiver 170B, etc.), or displays an image or video through a display screen 194. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 110 and be set in the same device as the mobile communication module 150 or other functional modules.

[0062] The wireless communication module 160 can provide wireless communication solutions for application in the electronic device 100, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), Bluetooth low energy (BLE), global navigation satellite system (GNSS), frequency modulation (FM), near field communication technology (NFC), infrared technology (IR), etc.

[0063] In some embodiments, antenna 1 of electronic device 100 is coupled to mobile communication module 150, and antenna 2 is coupled to wireless communication module 160, so that electronic device 100 can communicate with the network and other devices through wireless communication technology.

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

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

[0066] The electronic device 100 can realize the shooting function through ISP, camera 193, video codec, GPU, display screen 194 and application processor.

[0067] The ISP is used to process data fed back by the camera 193. The camera 193 is used to capture still images or videos.

[0068] Digital signal processors are used to process digital signals. In addition to processing digital image signals, they can also process other digital signals.

[0069] The video codec is used to compress or decompress digital video. The electronic device 100 may support one or more video codecs.

[0070] The external memory 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 100 .

[0071] The internal memory 121 may be used to store computer executable program codes, wherein the executable program codes include instructions. The processor 110 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 121 .

[0072] The electronic device 100 can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0073] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals.

[0074] The speaker 170A, also called a "horn", is used to convert audio electrical signals into sound signals.

[0075] The receiver 170B, also called a "handset", is used to convert audio electrical signals into sound signals.

[0076] Microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals.

[0077] The earphone jack 170D is used to connect a wired earphone.

[0078] The pressure sensor 180A is used to sense the pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be disposed on the display screen 194 .

[0079] The gyro sensor 180B may be used to determine the motion posture of the electronic device 100 .

[0080] The air pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist positioning and navigation.

[0081] The acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes).

[0082] The distance sensor 180F is used to measure the distance.

[0083] The fingerprint sensor 180H is used to collect fingerprints.

[0084] The touch sensor 180K is also called a “touch panel.” The touch sensor 180K may be disposed on the display screen 194 , and the touch sensor 180K and the display screen 194 form a touch screen, also called a “touch screen.”

[0085] The bone conduction sensor 180M can obtain vibration signals. In some embodiments, the bone conduction sensor 180M can obtain vibration signals of vibrating bones of the human body. The bone conduction sensor 180M can also contact the human body's pulse to receive blood pressure beating signals.

[0086] Buttons 190 include a power button, a volume button, and the like.

[0087] Motor 191 can generate vibration prompts.

[0088] Indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, messages, missed calls, notifications, etc.

[0089] The SIM card interface 195 is used to connect a SIM card.

[0090] The software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a micro-kernel architecture, a micro-service architecture, or a cloud architecture. The embodiment of the present application takes an operating system of a layered architecture as an example to exemplify the software structure of the electronic device 100.

[0091] Figure 2 1 is a software structure diagram of the electronic device 100 of the embodiment of the present application. The layered architecture divides the software into several layers, each layer has a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the operating system is divided into four layers, from top to bottom, namely, the application layer, the application framework layer, the system library, and the kernel layer. The application layer can include a series of application packages.

[0092] like Figure 2As shown, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, wallet, etc.

[0093] The application framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer includes some predefined functions.

[0094] like Figure 2 As shown, the application framework layer may include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, and the like.

[0095] The window manager is used to manage window programs. The window manager can obtain the display screen size, determine whether there is a status bar, lock the screen, capture the screen, etc.

[0096] Content providers are used to store and retrieve data and make it accessible to applications. The data may include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.

[0097] The view system includes visual controls, such as controls for displaying text, controls for displaying images, etc. The view system can be used to build applications. A display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying images.

[0098] The phone manager is used to provide communication functions of the electronic device 100, such as management of call status (including connecting, hanging up, etc.).

[0099] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, video files, and so on.

[0100] The notification manager enables applications to display notification information in the status bar. It can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be a notification that appears in the system top status bar in the form of a chart or scroll bar text, such as notifications of applications running in the background, or a notification that appears on the screen in the form of a dialog window. For example, a text message is displayed in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.

[0101] The core library consists of two parts: one part is the function that the Java language needs to call, and the other part is the core library.

[0102] The application layer and the application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.

[0103] The system library may include multiple functional modules, such as surface manager, media libraries, 3D graphics processing library (such as OpenGL ES), 2D graphics engine (such as SGL), etc.

[0104] The surface manager is used to manage the display subsystem and provide the fusion of 2D and 3D layers for multiple applications.

[0105] The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.

[0106] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0107] A 2D graphics engine is a drawing engine for 2D drawings.

[0108] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.

[0109] Before introducing the technical solutions of the embodiments of the present application, some professional terms that may be involved in the present application are briefly introduced.

[0110] High Dynamic Range (HDR) imaging: A set of technologies used to achieve a larger exposure dynamic range (i.e., greater difference between light and dark) than ordinary digital imaging technology.

[0111] Wide-angle lens: short focal length, wide angle of view, can capture a larger area of ​​scenery within a shorter shooting distance. The lens has a very short focal length, a wide angle of view, and a deep depth of field, which is more suitable for taking photos of larger scenes, such as architecture, landscapes, etc.

[0112] Telephoto lens: A telephoto lens is a photographic lens with a longer focal length than a standard lens. It is generally used to shoot distant subjects, such as wildlife photography and sports photography. Due to the heavy body and short depth of field, it is more likely to be out of focus due to hand shaking, and the shutter speed requirement is also higher.

[0113] Halo: refers to the virtual shadow that appears on the edge of the image due to overexposure when strong light is projected onto the photosensitive area during the shooting process.

[0114] Overexposure: The brightness of the photo exceeds the exposure brightness range that should be used to shoot this picture, which can be simply referred to as overexposure.

[0115] Silhouette effect: A picture with the outline of a person, object, or other scene.

[0116] Optical zoom: It is produced by changing the position of the lens, the object and the focus. The greater the optical zoom ratio, the farther the scene can be photographed.

[0117] Digital zoom: also known as digital zoom. It uses a processor to increase the area of ​​each pixel in the image to achieve the purpose of magnification.

[0118] When users use electronic devices to take photos, the moon is often the subject of the photo. When electronic devices take photos of the moon, they generally use low exposure to restore the overexposed moon, then use high dynamic range imaging (HDR) technology to obtain a moon image with a high signal-to-noise ratio, and finally use algorithms to improve the resolution of the moon to obtain a clear moon image.

[0119] However, the moon image only includes a clear moon, and the foreground area outside the moon is basically invisible, which affects the beauty of the entire moon image.

[0120] In some scenarios, for example, in the evening when the moon has just risen, or in a city with a beautiful night view, when a user takes a picture of the moon, if the final picture only contains the moon but not the foreground, the user's shooting experience will be reduced.

[0121] In view of this, an embodiment of the present application provides a method and electronic device for photographing the moon. This technical solution can fuse the images of the wide-angle lens and the telephoto lens when the electronic device is at a low-magnification focal length, and when the magnification is switched to a high-magnification, fuse the images of the telephoto lens and the telephoto lens, so as to obtain a clear image of both the moon and the foreground, thereby improving the aesthetics of the images of the moon taken by users.

[0122] The following will introduce the method of photographing the moon in the embodiment of the present application in combination with several sets of graphical user interfaces (GUIs).

[0123] Figure 3 is a schematic diagram of a set of GUIs provided in an embodiment of the present application. Figure 3 (a) to (d) in FIG. 1 show the process of a user photographing the moon using the mobile phone 200 .

[0124] See also Figure 3In (a), the GUI is a display interface 210 of the mobile phone 200. The display interface 210 may include multiple applications installed in the mobile phone 200. When the mobile phone 200 detects that the user clicks the camera icon 211, the following may be displayed: Figure 3 GUI shown in (b) in .

[0125] See also Figure 3 In (b), the GUI is a display interface 220 of a camera with a zoom ratio of 10. The display interface 220 may include at least a function bar 226, a main preview display interface 221, an auxiliary preview display interface 230, a mode bar 225, a shooting control 223, and the like.

[0126] The function bar 226 may include a flash function button, an artificial intelligence (AI) photography function button, a smart vision function button, a setting function button, and the like.

[0127] The main preview display interface 221 can be used to display the moon photographed by the telephoto lens, and the upper left corner of the main preview display interface 221 can also display the auxiliary preview display interface 230 of the wide-angle lens and the first zoom ratio control 222. Among them, the auxiliary preview display interface 230 can be used to display the image obtained by the wide-angle lens, and the auxiliary preview display interface 230 is displayed in the preview display interface 221 in the form of picture-in-picture. The auxiliary preview display interface 230 can also include a preview display interface 231 of the telephoto lens.

[0128] It should be understood that the first zoom ratio control 222 may be a fusion zoom ratio that controls the optical zoom and digital zoom of the mobile phone.

[0129] It should be understood that the area in the auxiliary preview display interface 230 except the preview display interface 231 of the telephoto lens can be called a foreground area.

[0130] It should be understood that the preview display interface 231 may also include a close button so that the user can close it as needed.

[0131] In this way, the auxiliary preview display interface 230 includes the preview display interface 231 of the telephoto lens and the foreground area, so that the user can compose the moon in the main preview display interface 231 according to the auxiliary preview display interface 230, which is conducive to taking pictures with better composition effects.

[0132] The auxiliary preview display interface 230 may be located at the upper left corner of the main preview display interface 221. In other exemplary embodiments, the auxiliary preview display interface 230 may also be located at other positions of the main preview display interface 221, or the user may also move the position of the auxiliary preview display interface 230 by dragging.

[0133] In other examples, the auxiliary preview display interface 230 is a preview display interface of an image captured by a wide-angle lens, and the preview display interface 231 included therein is also a preview display interface of a wide-angle lens. In this case, the preview display interface 231 is a part of the auxiliary preview display interface 230. The preview display interface 231 can be used to indicate the size of the image obtained after the user clicks the shooting control. In this case, the user can complete the composition of the moon according to the area of ​​the auxiliary preview display interface 231.

[0134] In some cases, the positions of the image of the moon displayed in the main preview display interface and the image displayed in the auxiliary preview display interface can be switched. For example, when the mobile phone 200 detects that the user clicks the preview display interface 231 or the auxiliary preview display interface 230, the image obtained by the wide-angle lens can be displayed in the main preview display interface of the camera, and the image of the moon obtained by the telephoto lens can be displayed in the auxiliary preview display interface, which is not limited in the embodiment of the present application.

[0135] When the mobile phone 200 detects that the user clicks the shooting control 223, the following display may be displayed: Figure 3 GUI shown in (c) in FIG.

[0136] See also Figure 3 In (c), the display control 224 in the display interface 220 can partially display the picture taken by the mobile phone. When the mobile phone 200 detects that the user clicks the display control 224, it can display the following Figure 3 GUI shown in (d).

[0137] In other examples, the user can also operate the phone to exit the camera, open the gallery, and view the taken pictures from the gallery.

[0138] See also Figure 3 In (d), the GUI is a display interface 240 of the mobile phone. The display interface 240 can be used to display a picture 241 taken by the mobile phone. In the picture 241, the moon is clear and bright, and the building part in the foreground is also clearly visible. The composition of the moon in the whole picture is also relatively harmonious, making the moon picture taken by the mobile phone more beautiful.

[0139] It should be understood that the content included in the picture 241 is the content included in the preview display interface 231. The area size of the preview display interface 231 is the area size of the telephoto lens framing.

[0140] In an embodiment of the present application, when a user uses a mobile phone to shoot the moon, the moon image obtained by the telephoto lens can be displayed in the main preview display interface of the mobile phone, and the image obtained by the wide-angle lens can be displayed in the auxiliary preview display interface. The image obtained by the wide-angle lens is displayed as a picture-in-picture, thereby helping the user to compose the moon and foreground, and finally take a beautiful picture including the moon and foreground.

[0141] The following will combine Figure 4 introduce Figure 3 The implementation process of the method of photographing the moon.

[0142] Figure 4 FIG. 1 is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application. Figure 4 As shown, the method may include steps 510 to 540.

[0143] In the embodiment of the present application, the method for photographing the moon may include a preview phase of steps 510-520 and a photographing phase of steps 530-540.

[0144] 510, determine the zoom ratio.

[0145] For example, see Figure 3 In (b), the user uses a mobile phone to shoot at the moon, opens the camera, and selects a zoom ratio of 10, then the mobile phone can determine that the zoom ratio is 10. It should be understood that the zoom ratio can be used to control the zoom ratio of the telephoto lens.

[0146] In some examples, before step 510, the method may further include: determining to enter the moon mode.

[0147] For example, the mobile phone can automatically identify the moon in the preview stage to enter the moon mode. In other examples, after the mobile phone enters the moon mode, the main preview display interface of the camera can display a moon icon, text content of the moon mode, and a close control.

[0148] 520, display the image of the moon acquired by the telephoto lens according to the zoom ratio in the main preview display interface, and display the image acquired by the wide-angle lens in the auxiliary preview display interface.

[0149] It should be understood that the first preset zoom ratio may be 10, 8, etc. The embodiment of the present application does not limit the specific value of the first preset zoom ratio.

[0150] For example, see Figure 3In (b), the main preview display interface may be the main preview display interface 221, which may be used to display the image of the moon acquired by the telephoto lens of the mobile phone according to the zoom ratio. The auxiliary preview display interface may be the auxiliary preview display interface 230, which may be used to display the image acquired by the wide-angle lens of the mobile phone.

[0151] It should be understood that the auxiliary preview interface can be displayed in the form of a picture-in-picture of the main preview interface, so as to facilitate the user to compose the final moon picture according to the auxiliary preview display interface.

[0152] It should be understood that before step 520, the method may further include: a focusing process.

[0153] The focusing process is to measure the distance to the subject being photographed, and then adjust the lens in the lens to form a focus, so that the image of the subject being photographed in the shooting preview interface looks clearer.

[0154] In an embodiment of the present application, the mobile phone can automatically focus after recognizing the moon, and the user can also focus by manually clicking on the moon in the camera interface, which is not limited in the embodiment of the present application.

[0155] It should be understood that Figure 4 In the processing flow shown in , the electronic device does not support additional magnification of the moon subject at a fixed zoom ratio. That is, in the interface of the camera of the electronic device, only one zoom ratio control is included to control the zoom ratio of the telephoto lens.

[0156] 530. When it is determined that the zoom ratio is greater than or equal to the first preset ratio, in response to the user's shooting operation, an image of the moon is acquired with a first exposure parameter according to the zoom ratio through a telephoto lens, and an image of the foreground is acquired with a second exposure parameter.

[0157] The embodiment of the present application does not limit the specific value of the first preset magnification. For example, the first preset magnification may be 10, 8, etc.

[0158] Exemplarily, in response to a shooting operation of a user clicking a shooting control, the mobile phone acquires multiple frames of images according to a zoom ratio through a telephoto lens, wherein the multiple frames of images include an image of the moon and an image of a foreground.

[0159] Since the main area of ​​the moon is brighter and the foreground area is darker, when a telephoto lens acquires an image of the moon according to the zoom ratio, a lower first exposure parameter is used to obtain a clear image of the main body of the moon, and a higher second exposure parameter is used when acquiring an image of the foreground to obtain a clear and bright foreground image.

[0160] In this case, the multiple frames of images acquired by the telephoto lens include images of the foreground in high-exposure frames and images of the moon in low-exposure frames.

[0161] In some examples, exposure parameters may include exposure time, sensitivity value, exposure compensation, white balance, and the like.

[0162] 540, fusing the image of the moon acquired by the telephoto lens according to the zoom ratio and the image of the foreground acquired by the telephoto lens according to the zoom ratio to obtain a first picture.

[0163] For example, after the telephoto lens acquires the image of the moon in the high-exposure frame and the image of the foreground in the low-exposure frame, the two can be fused to obtain a final first picture in which both the moon and the foreground are clear and bright. The technical solution for fusing the image of the moon with the image of the foreground will be introduced below in conjunction with a specific embodiment, which will not be described in detail here.

[0164] In the embodiment of the present application, when shooting the moon, the mobile phone can display the image of the moon acquired by the telephoto lens according to the zoom ratio in the main preview display interface, and display the image acquired by the wide-angle lens in the auxiliary preview display interface, so as to facilitate the user to compose the moon. During the shooting stage, the mobile phone can acquire the foreground image of the high-exposure frame and the moon image of the low-exposure frame through the telephoto lens according to the user's shooting operation, and merge the two to obtain a clear and bright picture of the foreground and the moon.

[0165] In some cases, the phone can also support additional partial zooming of the moon in the preview interface and captured pictures at a fixed zoom ratio. Figures 5 to 12 Introduce the technical solution.

[0166] Figure 5 is a schematic diagram of another set of GUIs provided in an embodiment of the present application. Figure 5 (a) to (d) in FIG. 3 show the process of a user photographing the moon using the mobile phone 300 .

[0167] It should be understood that Figure 5 For (a) in Figure 3 For the sake of brevity, the relevant description of (a) will not be repeated here.

[0168] When the mobile phone 300 detects that the user clicks the camera icon 311, the following display may be displayed: Figure 5 GUI shown in (b) in .

[0169] See also Figure 5 In (b), the GUI is a display interface 320 of a camera of the mobile phone 300 with an optical zoom ratio of 10 times and a moon magnification ratio of 1 times. The display interface 320 may include a main preview display interface 325, an auxiliary preview display interface 330, a shooting control 323, a function bar, a mode bar, and the like.

[0170] The main preview display interface 325 can display the image of the moon obtained by the telephoto lens, and can also include a zoom ratio control 322 and a moon magnification ratio control 321. The upper left corner of the main preview display interface 325 can also display an auxiliary preview display interface 330, which displays the image obtained by the wide-angle lens.

[0171] The user can select a zoom ratio through the zoom ratio control 322 , and can also select an additional magnification ratio for the moon on the main preview display interface under the above zoom ratio through the moon magnification ratio control 321 .

[0172] It should be understood that the zoom ratio may include an optical zoom ratio and a digital zoom ratio. The moon magnification ratio may be understood as a ratio for further digitally zooming the moon under the above zoom ratio.

[0173] The preview display interface 331 is a part of the auxiliary preview display interface 330, and is used to indicate the size of the picture obtained after the user clicks the shooting control. In this case, the user can complete the composition of the moon according to the area of ​​the preview display interface 331.

[0174] In this way, the user can compose the moon and the foreground according to the preview display interface of the telephoto lens and the preview display interface of the wide-angle lens, which is conducive to taking beautiful pictures including the moon and the foreground.

[0175] It should be understood that Figure 5 In (b), when the zoom ratio is 10 times, the additional magnification of the moon is 1. In other embodiments, the user can also adjust the additional magnification of the displayed moon in the moon magnification control 321. For example, when the user selects the moon magnification control 321 to 2 times, the moon displayed in the main interface of the display interface 325 will become larger.

[0176] In other examples, when the user selects the moon magnification control 321 to pure, the moon magnification control 321 may be turned off.

[0177] In some cases, the positions of the image of the moon displayed in the main preview display interface and the image displayed in the auxiliary preview display interface can be switched. For example, when the mobile phone 400 detects that the user clicks the preview display interface 331 or the auxiliary preview display interface 330, the image captured by the wide-angle lens can be displayed in the main preview display interface of the camera, and the image of the moon captured by the telephoto lens can be displayed in the auxiliary preview display interface, which is not limited in the embodiments of the present application.

[0178] When the mobile phone 300 detects that the user clicks the shooting control 323, the following display may be displayed: Figure 5 GUI shown in (c) in FIG.

[0179] See also Figure 5 In (c), the display control 324 in the display interface 320 can partially display the picture taken by the mobile phone 300. When the mobile phone 300 detects that the user clicks the display control 324, it can display the following Figure 5 GUI shown in (d).

[0180] In other examples, the user can also operate the phone to exit the camera, open the gallery, and view the taken pictures from the gallery.

[0181] See also Figure 5 In (d), the GUI is a display interface 340 of the mobile phone. The display interface 340 can be used to display a picture 341 taken by the mobile phone. In the picture 341, the moon is clear and bright, and the foreground part is also clearly visible. The composition of the moon in the whole picture is also relatively harmonious, making the moon picture taken by the mobile phone more beautiful.

[0182] In the embodiment of the present application, when a user uses a mobile phone to shoot the moon, the main preview display interface of the mobile phone can display the image of the moon shot by the telephoto lens, and the auxiliary preview display interface can display the image obtained by the wide-angle lens, and the image obtained by the wide-angle lens is displayed in the form of picture-in-picture, so as to help the user compose the moon and the foreground, and finally shoot a beautiful picture including the moon and the foreground. In addition, the user can also use the moon magnification control to additionally magnify the moon while keeping the foreground size unchanged, so as to improve the flexibility of the user in shooting the moon image.

[0183] Figure 6 is a schematic diagram of another set of GUIs provided in an embodiment of the present application. Figure 6 (a) to (d) in FIG. 5 show the process of a user photographing the moon using a mobile phone 500 .

[0184] It should be understood that Figure 6 For (a) in Figure 3 For the sake of brevity, the relevant description in (a) is not repeated here.

[0185] When the mobile phone 500 detects that the user clicks the camera icon 511, the following display may be displayed: Figure 6 GUI shown in (b) in .

[0186] See also Figure 6 In (b), the GUI is a display interface 520 of a camera of the mobile phone 500 with a zoom factor of 20 and a moon magnification factor of 2.

[0187] Different from the display interface 320 , the magnification of the moon magnification control 521 in the display interface 520 is 2 times, and the moon in the main preview display interface 525 in the display interface 520 is larger than the moon in the main preview display interface 325 in the display interface 320 .

[0188] In this way, when the magnification in the zoom ratio control 522 is 10 times, the user can further partially magnify the moon by selecting the moon magnification to 2 times when the magnification in the zoom ratio control 522 is 10 times, which helps to improve the user's flexibility in photographing the moon.

[0189] in, Figure 6 For (c) in Figure 5 The relevant description in (c) in .

[0190] When the mobile phone detects that the user clicks the shooting control 524, the following display may be displayed: Figure 6 The GUI shown in (d) in FIG.

[0191] See also Figure 6 In (d), the GUI is a display interface 540 of the mobile phone 500. The display interface 540 can be used to display a picture 541 taken by the mobile phone 500. In the picture 541, the moon is large, clear and bright, and the foreground part is also clearly visible. The composition of the moon in the whole picture is also relatively harmonious, making the moon picture taken by the mobile phone more beautiful.

[0192] In the embodiment of the present application, under a fixed zoom ratio, the mobile phone can also perform additional partial zooming of the moon part according to the user's operation, so as to obtain a larger moon, and the moon is also clear and bright, the foreground scenery is also clearly visible, and the composition of the moon in the whole picture is also relatively harmonious, making the whole moon picture more beautiful.

[0193] The following will combine Figure 7 introduce Figure 4 , Figure 5 The implementation process of the method of photographing the moon.

[0194] Figure 7 FIG. 1 is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application. Figure 7 As shown, the method may include steps 710 to 760.

[0195] 710, determine the zoom ratio.

[0196] 720, the image of the moon acquired by the telephoto lens according to the zoom ratio is displayed in the main preview interface, and the image acquired by the wide-angle lens is displayed in the auxiliary preview interface.

[0197] It should be understood that steps 710 to 720 can refer to the relevant descriptions of steps 510 to 520 in the previous text, and will not be repeated here.

[0198] 730, determine the moon magnification.

[0199] For example, see Figure 6 In (b), the moon magnification is controlled by the moon magnification control 521, for example, the moon magnification is 2 times.

[0200] 740, the image of the moon acquired by the telephoto lens in the main preview display interface is magnified according to the moon magnification.

[0201] In step 740, the mobile phone can additionally magnify the main body of the moon according to the magnification ratio of the moon based on the image of the moon obtained by the telephoto lens with a fixed zoom ratio. At this time, the image of the moon obtained by the telephoto lens displayed in the main preview display interface of the mobile phone will become larger.

[0202] It should be understood that the moon magnification ratio can be understood as a ratio for further digitally zooming the moon body under the above zoom ratio.

[0203] In a possible implementation, when the mobile phone zooms in on the main body of the moon according to the moon magnification ratio, the moon obtained at the above zoom ratio can be interpolated to obtain the magnified main body of the moon.

[0204] In another possible implementation, when the zoom ratio is 10x and the moon magnification is 2x, the mobile phone can perform a 20x digital zoom on the moon part in a scenario where the optical zoom ratio is 10x, that is, an image is obtained by fusing the foreground with an optical zoom ratio of 10 and the moon with a 20x digital zoom.

[0205] In another possible implementation, the mobile phone may further include another telephoto lens, and when the zoom ratio is 10 times and the user selects a moon magnification ratio of 2 times, the telephoto lens can achieve a zoom ratio of 20 times, so that the main body of the moon can be magnified. It should be understood that when the zoom ratio is 10 times and the moon magnification ratio is 2 times, the size of the main body of the moon displayed in the main preview display interface of the mobile phone is the same as the size of the main body of the moon obtained when the zoom ratio is 20 times.

[0206] In this way, in the main preview display interface of the mobile phone, users can flexibly adjust the size of the moon body through the moon magnification control.

[0207] 750. When it is determined that the zoom ratio is greater than or equal to the first preset ratio, in response to a shooting operation of the user, an image of the moon is acquired with a third exposure parameter according to the zoom ratio through a telephoto lens, and an image of the foreground is acquired with a fourth exposure parameter.

[0208] It should be understood that the step 750 can refer to the relevant description of the step 530 in the previous text, and for the sake of brevity, it will not be repeated.

[0209] 760, the image of the moon obtained by the telephoto lens and magnified according to the moon magnification ratio is combined with the image of the foreground obtained by the telephoto lens to obtain a second image.

[0210] It should be understood that the image of the moon is obtained by the telephoto lens according to the zoom ratio and is magnified according to the magnification ratio of the moon, and the image of the foreground is obtained by the telephoto lens according to the zoom ratio.

[0211] The following will introduce the fusion technical solution in conjunction with specific embodiments, which will not be described in detail here.

[0212] In the embodiment of the present application, when shooting the moon, the mobile phone can display the image of the moon acquired by the telephoto lens according to the zoom ratio in the main preview display interface, and zoom in on the main body of the moon according to the moon magnification ratio, and display the image acquired by the wide-angle lens in the auxiliary preview interface, so as to facilitate the user to compose the moon. During the shooting stage, the mobile phone can, according to the user's shooting operation, obtain the image of the moon in the low-exposure frame acquired by the telephoto lens according to the moon magnification ratio and the image of the foreground in the high-exposure frame acquired by the telephoto lens, and merge the two to obtain a clear and bright picture of both the foreground and the moon.

[0213] Figure 8 FIG. 1 is an exemplary flow chart of a shooting stage provided in an embodiment of the present application. Figure 8 As shown, the shooting stage may include steps 901 to 908 .

[0214] Among them, step 901 includes steps 901a and 901b, step 902 includes steps 902a and 902b, step 903 includes steps 903a and 903b, and step 904 includes steps 904a and 904b.

[0215] 901a, multiple foreground image frames are acquired through a telephoto lens.

[0216] Exemplarily, when the electronic device detects that the user clicks the shooting control, it may start to collect multiple foreground image frames. For example, multiple foreground image frames may be collected according to different exposure parameters.

[0217] The embodiment of the present application does not limit the specific number of the foreground image frames. For example, the number of the foreground image frames can be 3, 5, etc. It should be understood that in some examples, the electronic device can also obtain a foreground image frame through a telephoto lens, which is not limited in the embodiment of the present application.

[0218] It should be understood that in the embodiment of the present application, the electronic device can determine the selection of a telephoto lens to capture multiple foreground image frames according to the zoom ratio.

[0219] In one example, when the electronic device determines that the zoom ratio is greater than or equal to the first preset ratio, the foreground image frame is obtained by the electronic device through a telephoto lens. For example, the first preset ratio may be 10 times, see Figure 5 , the zoom ratio is 10 times, the main preview display interface 325 of the camera includes the moon image obtained by the telephoto lens, and the auxiliary preview display interface 330 includes the image obtained by the wide-angle lens. When the user clicks the shooting control 323, the mobile phone can obtain multiple foreground image frames through the telephoto lens.

[0220] In step 901a, the electronic device may acquire multiple foreground image frames with a telephoto lens and high exposure parameters to make the foreground image clearer.

[0221] 901b, multiple moon image frames are acquired through a telephoto lens.

[0222] Exemplarily, when the electronic device detects that the user clicks the shooting control, it can start collecting multiple moon image frames. For example, multiple moon image frames can be collected according to different exposure parameters.

[0223] The embodiment of the present application does not limit the specific number of the moon image frames. For example, the number of the moon image frames can be 3, 5, etc. In other examples, the electronic device can also obtain a moon image frame through a telephoto lens, which is not limited in the embodiment of the present application.

[0224] It should be understood that the moon image frame may be obtained by the electronic device through a telephoto lens. Figure 5 ,When the mobile phone detects that the user clicks the shooting control, it can obtain multiple moon image frames through the telephoto lens.

[0225] In step 901b, the electronic device may obtain multiple moon image frames with a telephoto lens and low exposure parameters to make the moon image clearer, for example, by obtaining the moon image frames with a longer exposure time.

[0226] 902a, registering multiple foreground image frames.

[0227] It should be understood that when the user takes a photo of the moon, there may be slight shaking, which may cause slight differences between the multiple foreground image frames captured by the electronic device. Therefore, in step 902a, the multiple foreground image frames captured are registered, which is conducive to the subsequent fusion of the multiple foreground image frames.

[0228] Since the exposure difference between the foreground image frames is small, the registration can be performed based on the image information of the foreground image frames.

[0229] 902b, align multiple moon image frames.

[0230] Similarly, considering that there may be slight differences between the multiple moon image frames, the multiple moon image frames are registered in step 902b, so as to facilitate the subsequent fusion of the multiple moon image frames.

[0231] Exemplarily, in the embodiment of the present application, the alignment can be performed by outlining the outline of the moon area in multiple moon image frames and selecting the moon center to align.

[0232] 903a, fusing multiple foreground image frames to obtain a first foreground image.

[0233] It should be understood that in step 903a, a first foreground image is obtained by fusing multiple foreground image frames, so that the first foreground image can be clearer and include more details.

[0234] In other examples, multiple foreground image frames with the same exposure parameters may be fused into a clear foreground image.

[0235] 903b, fusing multiple moon image frames to obtain a first moon image.

[0236] It should be understood that in step 903b, a first moon image is obtained by fusing multiple moon image frames, so that the moon in the first moon image can be clearer and include more details.

[0237] In other examples, multiple moon image frames with the same exposure parameters may be fused into a clear moon image.

[0238] 904a, performing brightness processing on the first foreground image.

[0239] Exemplarily, the first foreground image obtained in step 903a may be subjected to brightness adaptive processing, for example, brightness adaptive processing may be performed using tone mapping technology.

[0240] The tone mapping technology first calculates the average brightness of the scene based on the current scene, then selects a suitable brightness domain based on the average brightness, and then maps the entire scene to this brightness domain to obtain the correct result.

[0241] It should be understood that step 904a is an optional step, and in some embodiments, step 904a may not be performed.

[0242] 904b, performing brightness processing on the first moon image.

[0243] Exemplarily, the first moon image obtained in step 903b may be subjected to brightness adaptive processing, for example, brightness adaptive processing may be performed using tone mapping technology.

[0244] It should be understood that step 904b is an optional step, and in some embodiments, step 904b may not be performed.

[0245] 905 , aligning the first foreground image with the moon included in the first moon image.

[0246] Since the user may have slight shaking when photographing the moon, there may be a slight difference between the position of the moon included in the first foreground image and the first moon image. In step 905, the first foreground image and the moon included in the first moon image may be aligned.

[0247] In a possible implementation, the moon regions in the first foreground image and the first moon image may be outlined, and the center point of the moon region may be selected to align the moon to ensure that the moon is in the same position when the two images are fused.

[0248] In some other examples, in step 905, the sizes of the moon in the first foreground image and the first moon image may be corrected.

[0249] 906 , fuse the first foreground image and the first moon image to obtain a first target image.

[0250] In step 906, the first foreground image after the moon alignment and the first moon image may be fused to obtain a target image in which both the foreground and the moon are clear.

[0251] For example, see Figure 3When the zoom ratio of the mobile phone is 10 times, it can be understood that the mobile phone is in a state of high zoom ratio. When the mobile phone detects that the user clicks the shooting control, the mobile phone can obtain the moon image through the telephoto lens with low exposure parameters, and obtain the foreground image through the telephoto lens with high exposure parameters, and fuse the foreground image with the moon image to obtain the target image.

[0252] For example, see Figure 6 In the case where the camera display interface has a zoom ratio control and a moon magnification ratio control, the first moon image is a moon image obtained by a telephoto lens that is magnified according to the moon magnification ratio. When the mobile phone detects that the user clicks the shooting control, the mobile phone can obtain the moon image with a low exposure parameter through the telephoto lens, and magnify the moon body according to the moon magnification ratio to obtain the first moon image, obtain the first foreground image with a high exposure parameter through the telephoto lens, and merge the first foreground image with the first moon image to obtain the target image.

[0253] When the first foreground image and the first moon image are fused, since the overexposed area of ​​the moon body in the foreground image frame is generally slightly larger than the area of ​​the moon body in the moon image frame, when the two images are fused, there may be some holes at the edge of the moon. In the embodiments of the present application, the following methods can be used to handle the hole phenomenon at the edge of the moon.

[0254] Method 1: Multiple-frame continuous exposure.

[0255] Exemplarily, multiple frames are continuously exposed from the first moon image frame to the first foreground image frame to reduce the image difference between two adjacent frames, thereby making the transition from the first moon image frame to the first foreground image frame natural. The multiple frames are then fused to avoid the hole phenomenon at the edge of the moon. The main body of the moon in the final picture is the same size as that in the first moon image frame.

[0256] Method 2: Enlarge the moon in the first moon image.

[0257] Exemplarily, the moon in the first moon image may be magnified by 1.1 times or 1.2 times, etc., so that the enlarged moon is the same size as the moon in the first foreground image.

[0258] Method 3: Use the sky around the moon to fill the holes at the edge of the moon.

[0259] Exemplarily, the third method can be implemented by an algorithm. For example, a smooth transition from the sky around the moon to the moon is achieved by an algorithm, so that the generated sky can fill the hole at the edge of the moon.

[0260] 907, perform halo processing on the first target image.

[0261] Since there is a strong halo around the main body of the moon, in the embodiment of the present application, the halo can be suppressed by filtering, AI algorithm, etc. to make the moon halo natural.

[0262] It should be understood that step 907 is an optional step, and in some examples, step 907 may not be performed.

[0263] 908, output the first target image.

[0264] After the processing of the above steps, a beautiful and clear first target image can be obtained, and the mobile phone can save the first target image for the user to view.

[0265] In the embodiment of the present application, when photographing the moon, the electronic device is at a high zoom ratio, and the foreground image can be obtained through the telephoto lens, and the moon image can be obtained through the telephoto lens, and the foreground image and the moon image are merged to obtain the target image. In the target image, the moon is clear and bright, the halo is natural, the foreground is also clearly visible, and the composition of the whole image is beautiful.

[0266] In some cases, when shooting the moon, the user may want to include as much of the foreground as possible in the picture because the foreground scenery is beautiful. That is, in the final picture, the zoom ratio of the foreground is lower and it occupies a larger proportion in the picture. For example, the zoom ratio of the foreground is less than 5 times, such as 1x, 2x, etc. Fig. 9 Introduce the technical solution.

[0267] Fig. 9 is a schematic diagram of another set of GUIs provided in an embodiment of the present application. Fig. 9 (a) to (c) in FIG. 6 show the process of a user using a mobile phone 600 to photograph the moon.

[0268] See also Fig. 9 In (a), the GUI is a display interface 620 of the camera of the mobile phone 600. The display interface 620 may include a main preview display interface 625, an auxiliary preview display interface 623, a shooting control 626, a function bar, a mode bar, and the like.

[0269] The main preview display interface 625 may display the moon photographed by a telephoto lens, and may also include a zoom ratio control 622 and a moon magnification ratio control 621 .

[0270] Exemplarily, the magnification in the optical zoom magnification 622 is 2 times, and the magnification in the moon magnification control 621 is 10 times.

[0271] In the auxiliary preview display interface 623, the buildings and trees in the picture are clearly visible because it is a preview display screen of a wide-angle lens, but the moon is overexposed and the details of the moon are not visible. In the case where the magnification of the moon image obtained by the telephoto lens is 2 times, it is further magnified by 10 times through the moon magnification, so the details of the moon in the main preview display interface 625 are clearly visible and more beautiful.

[0272] In some examples, the display interface 620 is a display interface of the mobile phone in moon mode.

[0273] When the mobile phone detects that the user clicks the shooting control 626, the following display may be displayed: Fig. 9 GUI shown in (b) in .

[0274] See also Fig. 9 In (b), the display control 627 in the display interface 620 can partially display the picture taken by the mobile phone 600. When the mobile phone 600 detects that the user clicks the display control 627, it can display the following Fig. 9 GUI shown in (c) in FIG.

[0275] In other examples, the user can also operate the phone to exit the camera, open the gallery, and view the taken pictures from the gallery.

[0276] See also Fig. 9 In (c), the GUI is a display interface 640 of the mobile phone. The display interface 640 can be used to display a picture 641 taken by the mobile phone 600. In the picture 641, the moon taken by the telephoto lens is clear and bright, and the foreground part taken by the wide-angle lens is also clearly visible, making the moon picture taken by the mobile phone more beautiful.

[0277] In the embodiment of the present application, for example, when the mobile phone detects that the user clicks the shooting control, the image of the moon taken by the telephoto lens and the wide-angle image taken by the wide-angle lens can be merged to obtain the final picture. Then the final picture includes both the clear foreground part taken by the wide-angle lens and the clear moon taken by the telephoto lens, so that the foreground part can account for a larger proportion in the picture, and the moon is also very clear.

[0278] It should be understood that Figures 3 to 9 The technical solutions can be used in combination with each other, and the embodiments of the present application are not limited thereto.

[0279] In one example, in Figure 5 In (b), when the mobile phone detects that the user slides the magnification in the moon magnification control 321 to 2 times, the mobile phone can display the following Figure 6 GUI shown in (b) in .

[0280] In another example, in Figure 8 In (a) of FIG. 1 , when the mobile phone detects that the user slides the zoom ratio control 622 to 10 times and slides the moon magnification control 621 to 1 times, the mobile phone may display the following Figure 5 GUI shown in (b) in .

[0281] The following will combine Fig.10 introduce Fig. 9 The implementation process of the method of photographing the moon.

[0282] Fig.10 FIG. 1 is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application. Fig.10 As shown, the method may include steps 810 to 860.

[0283] 810, determine the zoom ratio.

[0284] It should be understood that the step 810 may refer to the relevant description in step 510 .

[0285] 820, display the moon image acquired by the telephoto lens according to the zoom ratio in the main preview display interface, and display the image acquired by the wide-angle lens in the auxiliary preview display interface.

[0286] In other examples, when the zoom ratio is small, for example, when the zoom ratio is 2 times, the moon in the main preview display interface is small, resulting in no other images in the main preview display interface except the small moon. In this case, the user can display the image of the moon acquired by the telephoto lens in the auxiliary display interface and the image acquired by the wide-angle lens in the main preview display interface by clicking the auxiliary preview display interface or the switch button.

[0287] 830, determine the moon magnification.

[0288] 840, amplify the moon image acquired by the telephoto lens in the main preview display interface according to the moon magnification ratio.

[0289] It should be understood that steps 830-840 can refer to the relevant descriptions in steps 730-740, and for the sake of brevity, they will not be repeated here.

[0290] It should also be understood that the embodiment of the present application does not limit the specific execution order of step 810 to step 840. For example, step 810 and step 830 can be executed in the same step or simultaneously, or step 830 can be executed before or after step 810.

[0291] 850. When it is determined that the zoom ratio is less than the first preset ratio, in response to a shooting operation of the user, an image of the moon is acquired with a fifth exposure parameter according to the zoom ratio through the telephoto lens, and an image is acquired with a sixth exposure parameter through the wide-angle lens.

[0292] In step 850, when it is determined that the zoom ratio is less than the first preset ratio, for example, the zoom ratio is 2 times, it can be determined that the telephoto lens is at a low magnification. When the user clicks the shooting button, the mobile phone can obtain an image of the moon in a high exposure frame according to the zoom ratio through the telephoto lens, and obtain the image normally through the wide-angle lens to obtain richer foreground scenery.

[0293] The fifth exposure parameter and the sixth exposure parameter may refer to the above description.

[0294] 860, fuse the image of the moon obtained by the telephoto lens and the image obtained by the wide-angle lens magnified according to the moon magnification to obtain a third image. It should be understood that in the image fusion stage, the mobile phone can further magnify the main body of the moon in the image of the moon obtained by the telephoto lens according to the moon magnification, and fuse the magnified image with the image obtained by the wide-angle lens to obtain the final third image.

[0295] In the embodiment of the present application, in the scene of shooting the moon, when the zoom magnification of the telephoto lens of the mobile phone is at a low magnification, in response to the user's shooting operation, the mobile phone can magnify the moon image obtained by the telephoto lens according to the moon magnification, and merge the magnified moon image with the image obtained by the wide-angle lens to obtain the final picture. The final picture includes rich foreground content and a bright and clear moon.

[0296] Fig.11 yes Fig. 9 An exemplary flow chart of the shooting stage in FIG. Fig.11 As shown, the shooting stage may include steps 1010 to 1080.

[0297] Among them, step 1010 includes steps 1010a and 1010b, step 1020 includes steps 1020a and 1020b, step 1030 includes steps 1030a and 1030b, and step 1040 includes steps 1040a and 1040b.

[0298] 1010a, acquiring multiple wide-angle image frames through a wide-angle lens.

[0299] Exemplarily, when the electronic device detects that the user clicks the shooting control, multiple wide-angle image frames can be captured through the wide-angle lens. For example, multiple wide-angle image frames can be captured according to different exposure parameters or the same exposure parameters.

[0300] The embodiment of the present application does not limit the specific number of the wide-angle image frames. For example, the number of the foreground image frames may be 3, 5, or 1.

[0301] In one example, when the electronic device determines that the zoom ratio is less than the first preset ratio, the wide-angle image frame can be acquired through the wide-angle lens. Exemplarily, the first preset ratio can be 10 times, see Figure 8 When the zoom ratio is 2 times, the main preview display interface 625 of the camera includes the moon image obtained by the telephoto lens, and the auxiliary preview display interface 623 includes the wide-angle image obtained by the wide-angle lens. When the user clicks the shooting control 626, the mobile phone can obtain multiple wide-angle image frames through the wide-angle lens.

[0302] 1010b, multiple moon image frames are acquired through a telephoto lens.

[0303] Exemplarily, when the electronic device detects that the user clicks the shooting control, multiple moon image frames can be captured through the telephoto lens. For example, multiple moon image frames can be captured according to different exposure parameters or the same exposure parameters.

[0304] The embodiment of the present application does not limit the specific number of the moon image frames. For example, the number of the moon image frames can be 3, 5, or 1, etc.

[0305] It should be understood that when the user clicks the shooting control, the electronic device can synchronously execute steps 1010a and 1010b.

[0306] 1020a, registering a plurality of wide-angle image frames.

[0307] 1020b, align multiple moon image frames.

[0308] It should be understood that the image registration method can refer to the relevant description of steps 902a and 902b in the previous text, and for the sake of brevity, it will not be repeated here.

[0309] 1030a, fusing multiple wide-angle image frames to obtain a first wide-angle image.

[0310] 1030b, fusing multiple moon image frames to obtain a second moon image.

[0311] It should be understood that the fusion method can refer to the relevant description of steps 903a and 903b in the previous text, and for the sake of brevity, it will not be repeated.

[0312] 1040a, performing brightness processing on the first wide-angle image.

[0313] 1040b, performing brightness processing on the second moon image.

[0314] It should be understood that the brightness processing method can refer to the relevant description of steps 1040a and 1040b in the previous text, and for the sake of brevity, it will not be repeated here.

[0315] 1050, aligning the first wide-angle image with the moon included in the second moon image.

[0316] It should be understood that the moon alignment processing method can refer to the relevant description of step 905 in the previous text.

[0317] 1060, fusing the first wide-angle image and the second moon image to obtain a second target image.

[0318] For example, see Fig. 9 , when there are zoom ratio controls and moon magnification ratio controls in the camera display interface, the second moon image is a moon image obtained by the telephoto lens magnified according to the moon magnification ratio. When the zoom ratio of the mobile phone is 2 times, it can be understood that the mobile phone is in a state of low zoom ratio. When the mobile phone detects that the user clicks the shooting control, the mobile phone can obtain the moon image through the telephoto lens and magnify the moon body according to the moon magnification ratio to obtain the second moon image, obtain the wide-angle image through the wide-angle lens, and merge the wide-angle image with the moon image to obtain the second target image.

[0319] 1070, perform halo processing on the second target image.

[0320] 1080, output the second target picture.

[0321] It should be understood that steps 1070-1080 may refer to the relevant descriptions of steps 907-908.

[0322] In the embodiment of the present application, when photographing the moon, the electronic device is at a low zoom ratio, and a wide-angle image can be obtained through a wide-angle lens, and a moon image can be obtained through a telephoto lens, and the wide-angle image and the moon image are merged to obtain a second target image. In the second target image, the moon is clear and bright, the halo is natural, the foreground is also clearly visible, and the composition of the whole image is beautiful.

[0323] In the embodiment of the present application, at a higher zoom ratio, due to the poor clarity of the wide-angle lens, the acquired foreground image may be blurred, which is lower than the clarity of the foreground image acquired by the telephoto lens. Therefore, by fusing the foreground image acquired by the telephoto lens with the moon image acquired by the telephoto lens, a target image in which both the moon main body and the foreground are clearly visible can be obtained. When the electronic device switches the zoom ratio to a lower ratio and selects a higher moon magnification ratio, the foreground image acquired by the wide-angle lens has a larger area and a higher clarity. Fusion of the moon image acquired by the telephoto lens and the foreground image acquired by the wide-angle lens can make the foreground beautiful and the moon clear. Thus, a fusion solution at full focal length can be achieved.

[0324] Fig.12 is a schematic diagram of another set of GUIs provided in an embodiment of the present application. Fig.12 (a) to (d) in FIG. 7 show a process in which a user uses a mobile phone 700 to shoot the moon to obtain a picture including a clear moon and a silhouette of the foreground.

[0325] It should be understood that Fig.12 For (a) in Figure 3 For the sake of brevity, the relevant description of (a) will not be repeated here.

[0326] When the mobile phone 700 detects that the user clicks the camera icon 711, the following display may be displayed: Fig.12 GUI shown in (b) in .

[0327] See also Fig.12 In (b), the GUI is a display interface 720 of the camera of the mobile phone 700 with a zoom factor of 10 and a moon magnification of 1.

[0328] In the display interface 720, the moon image acquired by the telephoto lens is displayed in the main preview display interface 725, and the foreground image acquired by the wide-angle lens is displayed as a picture-in-picture in the auxiliary preview display interface 730.

[0329] See also Fig.12 (b) in Figure 5 The difference between (b) and the foreground in the preview interface is that the foreground is darker and there are only a few objects. In this case, the present application does not blindly aim to increase the foreground brightness, but displays a silhouette effect in the preview interface. Fig.12 As shown in (b), there are only a few lights in the foreground part of the auxiliary preview display interface 730, and the foreground part included in the main preview display interface 731 also has a silhouette effect.

[0330] In this way, when the foreground includes fewer objects, such as only a small number of trees, electric poles, building lights, etc., the foreground can display a silhouette effect in the preview interface of the camera to enhance the artistic beauty of the obtained picture.

[0331] In another possible implementation, the mobile phone can perform distribution statistics on the brightness values ​​of the foreground. When the statistical results determine that the foreground is darker and the signal-to-noise ratio is lower than a preset value, a silhouette effect can be displayed instead of blindly increasing the brightness.

[0332] For example, when the mobile phone displays the preview display interface, the brightness value of the foreground can be summed. When the sum result is less than the preset brightness value A, a silhouette effect can be displayed instead of blindly increasing the brightness.

[0333] When the mobile phone 700 detects that the user clicks the shooting control 723, the following display may be displayed: Fig.12 GUI shown in (c) in FIG.

[0334] See also Fig.12 In (c), the display control 724 in the display interface 725 can partially display the picture taken by the mobile phone 700. When the mobile phone 700 detects that the user clicks the display control 724, it can display the following Fig.12 GUI shown in (d).

[0335] See also Fig.12 In (d), the GUI is a display interface 740 of the mobile phone. The display interface 740 can be used to display a picture 741 taken by the mobile phone 700. In the picture 741, the moon taken by the telephoto lens is clear and bright, and the lights in the foreground are displayed as silhouette effects.

[0336] In the embodiment of the present application, when the foreground includes fewer objects, forcibly increasing the foreground brightness will result in a poor display effect. The embodiment of the present application is not intended to increase the foreground brightness, but to display the objects in the foreground as silhouettes, so that the final image has a certain artistic beauty.

[0337] In other embodiments, after entering the camera preview interface, the mobile phone can sum the brightness of the foreground part. When it is determined that the summation result is less than the preset brightness value A, a silhouette effect can be displayed for the foreground part. When it is determined that the summation result is greater than or equal to the preset brightness value A, the foreground part can be displayed normally without displaying the silhouette effect.

[0338] Fig.13 FIG. 1 is a schematic flow chart of a method for photographing the moon provided in an embodiment of the present application. Fig.13As shown, the method 1300 may be applied to an electronic device, which may include a telephoto lens and a wide lens. The method 1300 may include steps 1310 to 1340.

[0339] 1310, the electronic device displays a preview display interface of the camera, where the preview display interface includes a first zoom ratio control, where the first zoom ratio control is used to control a first zoom ratio of the telephoto lens.

[0340] Exemplarily, the electronic device may display a preview display interface of the camera according to the user's operation of turning on the camera. The preview display interface may be called a viewfinder interface, a preview interface, a camera display interface, and the like.

[0341] It should be understood that the user's operation of opening the camera may be that the user clicks on the camera application on the desktop, or that the user calls the camera in other applications, which is not limited in the embodiments of the present application.

[0342] The preview display interface may include a first zoom ratio control. Figure 3 In (b), the first zoom ratio control may be the zoom ratio control 222. It should be understood that the zoom ratio control is used to control the first zoom ratio of the telephoto lens of the electronic device, and the first zoom ratio may include an optical zoom ratio and / or a digital zoom ratio.

[0343] In some other examples, the electronic device may also automatically enter the moon mode after recognizing the moon. The following steps are performed in the moon mode.

[0344] 1320. When the electronic device determines that the captured scene is a moon scene, the main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, and the auxiliary preview display interface of the preview display interface displays the wide-angle image acquired by the wide-angle lens.

[0345] For example, see Figure 3 (b) Figure 5 In (b), the image of the moon can be displayed in the main preview display interface of the camera, and the image of the foreground can be displayed in the auxiliary preview display interface.

[0346] In this way, the image obtained by the wide-angle lens is displayed in the form of picture-in-picture in the auxiliary preview display interface of the camera, which can assist the user in composing the moon when shooting the moon.

[0347] It should be understood that the electronic device determines that the captured scene is a moon scene by automatically determining it based on the user's shooting scene, or by the user selecting a moon mode. The embodiments of the present application do not limit the specific method for determining the moon scene.

[0348] 1330. When the electronic device determines that the first zoom ratio is greater than or equal to the first preset ratio, in response to a first shooting operation by the user, the electronic device obtains a first moon image with a first exposure parameter according to the first zoom ratio through a telephoto lens, and obtains a first foreground image with a second exposure parameter.

[0349] Exemplarily, the first preset magnification is 10 times, 8 times, etc., and the embodiment of the present application does not limit the specific value of the first preset magnification. In other examples, the first zoom magnification needs to be less than the preset magnification B, for example, the preset magnification B is 20 times, 25 times, etc.

[0350] For example, see Figure 3 In (b) to (d), the user's shooting operation can be an operation of the user clicking the shooting control 223. When the mobile phone 200 detects that the user clicks the shooting control 223, the image of the moon can be obtained through the telephoto lens according to the zoom ratio selected by the user, and the image of the foreground can be obtained through the telephoto lens.

[0351] It should be understood that, since there is a large difference between the image of the moon and the image of the foreground when photographing the moon, the electronic device acquires the image of the moon with a first exposure parameter and acquires the image of the foreground with a second exposure parameter when photographing with a telephoto lens.

[0352] The exposure parameters may include exposure time, sensitivity value, exposure compensation, white balance, etc. The first exposure parameter may be a low exposure parameter, for example, a longer exposure time, such as 10s, etc. The second exposure parameter may be a high exposure parameter.

[0353] 1340, the electronic device fuses the first moon image with the first foreground image to obtain a first target image.

[0354] It should be understood that the specific manner in which the electronic device fuses the first moon image with the first foreground image can be found in the relevant description in the foregoing text and will not be repeated here.

[0355] In an embodiment of the present application, when the electronic device determines to shoot the moon, the electronic device can display the image of the moon acquired by the telephoto lens in the main preview display interface of the camera, and display the image acquired by the wide-angle lens in the form of picture-in-picture in the auxiliary preview display interface, so that when the user shoots the moon, the moon can be composed according to the foreground image, which is more conducive to the user to take a harmoniously composed moon picture. In addition, when it is determined that the zoom ratio of the electronic device is greater than or equal to the first preset ratio, during the shooting stage, the electronic device acquires the moon image with a high exposure parameter through the telephoto lens, acquires the foreground image with a low exposure parameter, and merges the moon image with the foreground image to obtain the final target image. This is conducive to the user taking a clear picture of the moon subject and the foreground scenery.

[0356] In some embodiments, the preview display interface also includes a second zoom ratio control, which is used to control a second zoom ratio for additionally magnifying the moon at the first zoom ratio, and the main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, including: the first moon image magnified according to the second zoom ratio is displayed in the main preview display interface; the electronic device merges the first moon image with the first foreground image, including: the electronic device merges the first moon image magnified according to the second zoom ratio with the first foreground image.

[0357] For example, see Figure 6 , the second zoom ratio control may be a moon magnification control 521, the second zoom ratio may be 2, and when the user adjusts the second zoom ratio from 1 to 2, the moon image in the main preview display interface 525 will be enlarged accordingly. After the user clicks the shooting control 521, the mobile phone 500 may merge the moon image enlarged according to the second zoom ratio with the foreground image to obtain a final picture.

[0358] It should be understood that the second zoom ratio may be the moon magnification ratio mentioned above. For details, please refer to the description above. For the sake of brevity, it will not be repeated here.

[0359] In the embodiment of the present application, the preview display interface of the camera may further include a second zoom ratio control for controlling the enlargement of the moon subject at the first zoom ratio, and the moon subject in the main preview display interface may be enlarged according to the second zoom ratio. During the shooting stage, the electronic device may merge the moon image enlarged according to the second zoom ratio with the foreground image to obtain the final picture. This technical solution enables the user to flexibly adjust the size of the moon subject under the same foreground, which is conducive to improving the flexibility of shooting the moon.

[0360] In some embodiments, when the electronic device detects that the user adjusts the first zoom ratio to be less than the first preset ratio, the method 1300 may further include:

[0361] In response to a second shooting operation of the user, the electronic device acquires a second moon image through the telephoto lens according to the first zoom ratio, and acquires a first wide-angle image through the wide-angle lens;

[0362] The electronic device fuses the second moon image magnified according to the second zoom ratio with the first wide-angle image to obtain a second target image.

[0363] For example, assuming that the first preset magnification is 10, see Fig. 9When the user adjusts the first zoom ratio to 2x, after the user clicks the shooting control 626, the mobile phone can obtain the second moon image according to the first zoom ratio through the telephoto lens, obtain the first wide-angle image through the wide-angle lens, and merge the second moon image magnified according to the second zoom ratio with the first wide-angle image to obtain the final second target image.

[0364] In the embodiment of the present application, at a higher zoom ratio, due to the poor clarity of the wide-angle lens, the acquired foreground image may be blurred, which is lower than the clarity of the foreground image acquired by the telephoto lens. Therefore, by fusing the foreground image acquired by the telephoto lens with the moon image acquired by the telephoto lens, a target image in which both the moon main body and the foreground are clearly visible can be obtained. When the electronic device switches the zoom ratio to a lower ratio and selects a higher moon magnification ratio, the foreground image acquired by the wide-angle lens has a larger area and a higher clarity. Fusion of the moon image acquired by the telephoto lens and the foreground image acquired by the wide-angle lens can make the foreground beautiful and the moon clear.

[0365] In some embodiments, the wide-angle image further includes a first display frame, and the first display frame is used to indicate the framing size of the first target image.

[0366] For example, see Figure 3 In (b), the wide-angle image may be displayed on the auxiliary preview display interface 230, and the first display frame may be a display interface 231, the size of the display interface 231 being the framing size of the first target image.

[0367] In the embodiment of the present application, the first display frame allows the user to determine the size of the image captured by the telephoto lens, thereby facilitating the user to compose a picture of the moon.

[0368] In some embodiments, the method 1300 may further include:

[0369] In response to the user clicking the wide-angle image or the switch button, the electronic device displays the image of the moon acquired by the telephoto lens in the auxiliary preview display interface, and displays the wide-angle image in the main preview display interface.

[0370] In some examples, the toggle button may be located in a secondary preview display interface, or in a primary preview display interface.

[0371] In an embodiment of the present application, the electronic device can support the interchange of the preview display positions of the display interface of the moon image obtained by the telephoto lens and the wide-angle image obtained by the wide-angle lens, so that the user can flexibly switch the preview display interface of the lens when using the electronic device to shoot the moon.

[0372] In some embodiments, before the electronic device fuses the first moon image with the first foreground image, the method 1300 may further include:

[0373] The electronic device acquires the center point of the moon in the first moon image and the first foreground image;

[0374] The electronic device performs moon alignment processing on the moon in the first moon image and the moon in the first foreground image according to the center point of the moon.

[0375] It should be understood that since the main body of the moon is brighter, the telephoto lens needs to use a very low exposure method to obtain the image of the moon, while the foreground image is lower than the moon, so the telephoto lens needs to use a very high exposure method to obtain the foreground image. In addition, there may be slight shaking when the user shoots, so there may be a slight difference between the main body of the moon in the image of the moon and the foreground image. Therefore, in the sum of image fusion, the moon needs to be aligned. This makes the moon area in the final image clearer.

[0376] It should be understood that the process of aligning the moon by the electronic device can be found in the relevant description in the previous text, and for the sake of brevity, it will not be repeated here.

[0377] In some embodiments, the method 1300 may further include:

[0378] After the electronic device fuses the first moon image and the first foreground image, it suppresses the halo of the moon in the fused image.

[0379] Since there is a strong halo around the moon, in the embodiment of the present application, the halo can be processed by filtering, AI algorithm, etc. to make the moon halo natural.

[0380] In some embodiments, the main preview display interface of the preview display interface displays an image of the moon acquired by a telephoto lens, and the auxiliary preview display interface of the preview display interface displays a wide-angle image acquired by a wide-angle lens, including:

[0381] The electronic device performs distribution statistics on the brightness value of the first foreground image to obtain a first brightness value;

[0382] When it is determined that the first brightness value is less than the preset brightness value, the objects in the first foreground image except the moon are displayed with a silhouette effect.

[0383] In one possible implementation, the mobile phone can perform distribution statistics on the brightness value of the foreground to obtain a first brightness value. When it is determined that the first brightness value is less than a preset brightness value, it can be determined that the foreground is darker and a silhouette effect can be displayed instead of blindly increasing the brightness.

[0384] In this way, when the foreground includes fewer objects, such as only a small number of trees, electric poles, building lights, etc., the foreground can display a silhouette effect in the preview interface of the camera to enhance the artistic beauty of the obtained picture.

[0385] In the embodiment of the present application, when the foreground includes fewer objects, forcibly increasing the foreground brightness will result in a poor display effect. The embodiment of the present application is not intended to increase the foreground brightness, but to display the objects in the foreground as silhouettes, so that the final image has a certain artistic beauty.

[0386] In some embodiments, objects other than the moon in the first target image are displayed as silhouette effects.

[0387] For example, see Fig.12 In (d), in the picture 741 finally obtained by the mobile phone, the moon is clear and bright, and the lights in the foreground appear as silhouettes.

[0388] An embodiment of the present application also provides an electronic device, comprising: one or more processors; one or more memories; the one or more memories storing one or more computer programs, the one or more computer programs including instructions, which, when executed by the one or more processors, enable the method of photographing the moon as described in any possible implementation method described above to be executed.

[0389] An embodiment of the present application also provides a device for photographing the moon, including a module for implementing a method for photographing the moon as described in any possible implementation manner described above.

[0390] An embodiment of the present application also provides a chip, which includes a processor and a communication interface, wherein the communication interface is used to receive a signal and transmit the signal to the processor, and the processor processes the signal so that the method for photographing the moon as described in any possible implementation method described above is executed.

[0391] This embodiment also provides a computer-readable storage medium, in which computer instructions are stored. When the computer instructions are executed on an electronic device, the electronic device executes the above-mentioned related method steps to implement the method of photographing the moon in the above-mentioned embodiment.

[0392] This embodiment also provides a computer program product. When the computer program product is run on a computer, the computer is caused to execute the above-mentioned related steps to implement the method for photographing the moon in the above-mentioned embodiment.

[0393] In addition, an embodiment of the present application also provides a device, which can specifically be a chip, component or module, and the device may include a connected processor and memory; wherein the memory is used to store computer-executable instructions, and when the device is running, the processor can execute the computer-executable instructions stored in the memory so that the chip executes the method of photographing the moon in the above-mentioned method embodiments.

[0394] Among them, the electronic device, computer-readable storage medium, computer program product or chip provided in this embodiment are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above and will not be repeated here.

[0395] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0396] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0397] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0398] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0399] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0400] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage media include: various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memories (ROM), random access memories (RAM), magnetic disks or optical disks.

[0401] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A method of photographing the moon, It is characterized in that The method is applied to an electronic device, the electronic device includes a wide-angle lens and a telephoto lens, and the method includes: The electronic device displays a preview display interface of the camera, the preview display interface includes a first zoom ratio control, the first zoom ratio control is used to control a first zoom ratio of the telephoto lens, and the preview display interface also includes a second zoom ratio control, the second zoom ratio control is used to control a second zoom ratio for additionally magnifying the moon under the first zoom ratio; When the electronic device determines that the captured scene is a moon scene, the main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, and the auxiliary preview display interface of the preview display interface displays the wide-angle image acquired by the wide-angle lens; When the electronic device determines that the first zoom ratio is greater than or equal to a first preset ratio, in response to a first shooting operation of the user, the electronic device acquires a first moon image with a first exposure parameter according to the first zoom ratio through the telephoto lens, and acquires a first foreground image with a second exposure parameter; The electronic device fuses the first moon image with the first foreground image to obtain a first target image; The main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, including: The main preview display interface displays the first moon image magnified according to the second zoom ratio; The electronic device fuses the first moon image with the first foreground image, including: The electronic device merges the first moon image magnified according to the second zoom ratio with the first foreground image.

2. The method according to claim 1, It is characterized in that When the electronic device detects that the user adjusts the first zoom ratio to be less than the first preset ratio, the method further includes: In response to a second shooting operation of the user, the electronic device acquires a second moon image through the telephoto lens according to the first zoom ratio, and acquires a first wide-angle image through the wide-angle lens; The electronic device fuses the second moon image magnified according to the second zoom ratio with the first wide-angle image to obtain a second target image.

3. The method according to claim 1 or 2, It is characterized in that The wide-angle image also includes a first display frame, and the first display frame is used to indicate the framing size of the first target image.

4. The method according to claim 1 or 2, It is characterized in that The method further comprises: In response to the user clicking the wide-angle image or the switch button, the electronic device displays the image of the moon acquired by the telephoto lens in the auxiliary preview display interface, and displays the wide-angle image in the main preview display interface.

5. The method according to claim 1 or 2, It is characterized in that Before the electronic device fuses the first moon image with the first foreground image, the method further includes: The electronic device acquires the center point of the moon in the first moon image and the first foreground image; The electronic device performs moon alignment processing on the moon in the first moon image and the moon in the first foreground image according to the center point of the moon.

6. The method according to claim 5, It is characterized in that The method further comprises: After the electronic device fuses the first moon image and the first foreground image, it suppresses the halo of the moon in the fused image.

7. The method according to claim 1 or 2, It is characterized in that The main preview display interface of the preview display interface displays the image of the moon acquired by the telephoto lens, and the auxiliary preview display interface of the preview display interface displays the wide-angle image acquired by the wide-angle lens, including: The electronic device performs distribution statistics on the brightness value of the first foreground image to obtain a first brightness value; When it is determined that the first brightness value is less than a preset brightness value, the objects in the first foreground image except the moon are displayed with a silhouette effect.

8. The method according to claim 7, It is characterized in that The objects other than the moon in the first target image are displayed as silhouette effects.

9. An electronic device, It is characterized in that include: one or more processors; One or more memories; the one or more memories store one or more computer programs, the one or more computer programs include instructions, when the instructions are executed by one or more processors, the method for photographing the moon as described in any one of claims 1-8 is executed.

10. A device for photographing the moon. It is characterized in that include: A module for implementing the method for photographing the moon as claimed in any one of claims 1 to 8.

11. A chip, It is characterized in that The chip includes a processor and a communication interface, wherein the communication interface is used to receive a signal and transmit the signal to the processor, and the processor processes the signal so that the method for photographing the moon as described in any one of claims 1 to 8 is executed.

12. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores computer instructions, and when the computer instructions are executed on a computer, the method for photographing the moon as described in any one of claims 1 to 8 is executed.