Video processing method and electronic device

By introducing the ‘generate moment’ function in the gallery application of the smart terminal, identifying and generating videos related to portraits in the photo, the problem of being unable to actively generate related videos in the prior art is solved, and the user experience is improved.

WO2025011078A9PCT designated stage expired Publication Date: 2025-03-20HONOR DEVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/082327
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-07-12
Filing Date
2024-03-19
Publication Date
2025-03-20

AI Technical Summary

Technical Problem

Existing smart terminals are unable to actively generate videos related to portraits in photos, resulting in poor user experience.

Method used

By adding an entry to the ‘Generate Moment’ function to the gallery application, identify portraits in photos and actively generate videos of moments related to portraits.

Benefits of technology

Improves the user experience, allowing users to quickly view historical memories moments related to portraits, and enhances the interactiveness of photo browsing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024082327_20032025_PF_FP_ABST
    Figure CN2024082327_20032025_PF_FP_ABST
Patent Text Reader

Abstract

Provided are a video processing method and an electronic device, which are applied to the technical field of terminals. According to the embodiments of the present application, an entry for the "Generate Moments" function is set in the gallery application. By means of the entry, an electronic device can actively generate the moment videos related to a target portrait for a user, so that the requirement of the user expecting to view the pictures related to the portrait is met, thereby greatly improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Video processing method and electronic device

[0001] This application claims priority to the Chinese patent application filed with the State Intellectual Property Office on July 12, 2023, with application number 202310863205.1 and application name “A Video Processing Method and Electronic Device”, the entire contents of which are incorporated by reference into this application. Technical Field

[0002] The present application relates to the field of electronic devices, and more particularly, to a video processing method and electronic device. Background Art

[0003] With the continuous development of smart terminals, the shooting functions of smart terminals are becoming increasingly powerful. Users can use smart terminals to take photos or videos to record the beautiful moments of the past. The needs and experience of users when browsing photos are also constantly improving.

[0004] In some scenarios, when a user browses a photo that includes a person, they may want to view historical memories of that person. However, on current smart devices, when a user browses a photo containing a person, they may need to click on the person's tag to view related photos. Videos related to that person cannot be automatically generated, resulting in a poor user experience.

[0005] Summary of the Invention

[0006] In view of this, the present application provides a video processing method, an electronic device, a computer-readable storage medium, and a computer program product, which can actively generate a memory video related to the object in the photo, greatly improving the user experience.

[0007] In a first aspect, a video processing method is provided, comprising:

[0008] In response to a first operation by the user, displaying a first interface, the first interface including a thumbnail of a first photo, the first photo including a first portrait;

[0009] In response to a user clicking on a thumbnail of the first photo, displaying a second interface for displaying a browsing page of the first photo;

[0010] In response to a second user operation on the second interface (e.g., sliding up the screen), displaying a third interface, where the third interface includes a first area, and the first area includes a first control;

[0011] In response to the user clicking the first control, a playback interface of the first video is displayed; the first video includes the first photo and a second photo, and the second photo includes the first portrait.

[0012] The above method can be executed by an electronic device or a chip in an electronic device. Based on the above technical solution, after the electronic device (or the chip in the electronic device) receives the second operation of the user on the second interface, if a portrait is recognized, the entrance to generate the moment video is displayed in the interface (for example, the first control in the first area), and after the user clicks the first control, the first video can be generated in response to the user clicking the first control. The first video is generated based on multiple photos including the first portrait. Compared to the user browsing through multiple photos of the portrait through the portrait tag, the embodiment of the present application sets an entrance to the "generate moment" function, through which the electronic device can actively generate a moment video related to the target portrait for the user, so as to meet the user's desire to view photos related to the portrait, thereby greatly improving the user experience.

[0013] In social settings, such as gatherings, users often share photos of family and friends, or browse through photos alone. A memory video of the person in the photo being viewed is generated, triggering memories and providing topics for discussion, helping users quickly find shared memories.

[0014] It can be understood that, in addition to the first area, the third interface may also include other information about the first photo.

[0015] In some possible implementations, the third interface also includes a partial area of ​​the first photo, a second area and / or a third area; the second area is used to display portrait tag information; and the third area is used to display the shooting location information of the first photo.

[0016] In some possible implementations, the first interface further includes a thumbnail of a second photo, and the second photo does not include a portrait; and the method further includes:

[0017] In response to a user clicking on a thumbnail of the second photo, displaying a fourth interface for displaying a browsing page of the second photo;

[0018] In response to the user's fourth operation on the fourth interface (swiping up the screen), a fifth interface is displayed, and the fifth interface does not include the first control.

[0019] That is to say, in the case where the photo does not contain a portrait, when the user browses the large picture of the photo, the electronic device responds to the user's swiping up operation of the screen and does not display the entrance to the "Generate Moment" function in the first area.

[0020] In some possible implementations, after displaying the playback interface of the first video, the method further includes:

[0021] In response to a fifth operation of the user on the playback interface of the first video (e.g., clicking a back control or sliding the screen sideways), displaying a sixth interface, wherein the sixth interface includes the first area, the first area does not include the first control, and the first area includes a thumbnail of the first video and the playback control;

[0022] In response to the user clicking the playback control, the playback interface of the first video is displayed.

[0023] Therefore, when the first video has been generated, when the user returns to the previous interface (i.e. the upward swipe page when browsing the first photo in large image), the function entrance originally displayed in the first area at the time of generation is changed to the thumbnail of the first video, making it convenient for the user to click to view the generated first video.

[0024] In some possible implementations, the first interface further includes a thumbnail of a third photo, where the third photo includes the first portrait; and the method further includes:

[0025] In response to a user clicking on a thumbnail of the third photo, a ninth interface is displayed, wherein the ninth interface is used to display a browsing page of the third photo;

[0026] In response to the user's seventh operation on the ninth interface, the tenth interface is displayed, and the fifth interface includes the first area, which includes a thumbnail of the first video and playback controls.

[0027] Therefore, when the first video has been generated, for other photos that include the same portrait as the first photo, such as the third photo, when browsing the large image of the third photo, in response to the user swiping up the screen, the electronic device will generate a thumbnail of the first video for the user's convenience.

[0028] Optionally, the first area further includes a third control; and the method further includes:

[0029] In response to a user clicking on the third control, updating the first video;

[0030] After the update is completed, the playback interface of the updated first video is displayed.

[0031] That is to say, by setting the update control, the generated moment video can also be updated to provide a corresponding entry for the user to actively update the moment video.

[0032] In some possible implementations, the method further includes:

[0033] In response to the user's eighth operation, displaying an eleventh interface, the eleventh interface is used to display a moment page of the gallery application, the eleventh interface including a second control;

[0034] In response to a user clicking on the second control, a twelfth interface is displayed, wherein the twelfth interface is used to display data of a plurality of portraits;

[0035] In response to a user selecting the first portrait, generating a third video, wherein the third video is an updated version of the first video;

[0036] Display the playback interface of the third video.

[0037] That is to say, the generated first video can be updated by actively selecting the target portrait to meet the user's demand for updating the moment video of the target portrait.

[0038] In some possible implementations, the first interface further includes a thumbnail of a fourth photo, the fourth photo includes a second number of portraits, and the second number is greater than a second threshold; and the method further includes:

[0039] In response to a user clicking on the thumbnail of the fourth photo, a thirteenth interface is displayed, wherein the thirteenth interface is used to display a browsing page of the fourth photo;

[0040] In response to a fourth operation of the user on the thirteenth interface, displaying a fourteenth interface, wherein the fourteenth interface includes the first area, and the first area includes the first control;

[0041] In response to the user clicking the first control, a fifteenth interface is displayed, wherein the fifteenth interface includes a first window, and the first window is used to prompt the user that the video cannot be generated.

[0042] Therefore, in the case where the number of portraits in the photo exceeds the upper limit, a pop-up window can be used to prompt the user so that the user is informed that the moment video cannot be generated.

[0043] In some possible implementations, the method further includes:

[0044] In response to the user clicking the first control, the sixteenth interface is displayed, and the sixteenth interface includes a second window, and the second window is used to prompt the user that the video cannot be generated, wherein the number of photos including the first portrait is less than a first threshold.

[0045] Therefore, in the case where the number of photos including the target person's portrait is too small, a pop-up window may be used to prompt the user so that the user is informed that the moment video cannot be generated.

[0046] In some possible implementations, during the process of generating the first video, the method further includes:

[0047] A dynamic icon is displayed in the first area, and the dynamic icon indicates that the first video is being generated. Therefore, during the process of generating the moment video, a dynamic icon can be displayed to let the user know that the moment video is currently being generated.

[0048] The embodiment of the present application also provides another entry for the function of generating moments. The entry for the function of generating moments is located on the moment page of the gallery application.

[0049] In some possible implementations, the method further includes:

[0050] In response to a sixth operation by the user, displaying a seventh interface, the seventh interface being used to display a moment page of the gallery application, the seventh interface including a second control;

[0051] In response to a user clicking on the second control, an eighth interface is displayed, wherein the eighth interface is used to display data of a plurality of portraits;

[0052] In response to the user selecting the second portrait, a second video is generated, where the second video includes a photo of the second portrait.

[0053] Display the playback interface of the second video.

[0054] Therefore, after clicking the function entrance of generating moment video on the moment page, the user is provided with the option to select a target person to generate a moment video related to the target object desired by the user, which is more targeted.

[0055] In some possible implementations, the method further includes:

[0056] In response to a user selecting a third person portrait, generating a third video, wherein the third video is generated based on a single-person photo of the third person portrait;

[0057] Display the playback interface of the third video.

[0058] Similarly, in the scenario where the user selects a target person portrait to generate a video at the moment, there may be a situation where the video cannot be generated.

[0059] In some possible implementations, the method further includes:

[0060] In response to the user selecting the third portrait, the seventeenth interface is displayed, and the seventeenth interface includes a third window, and the third window is used to prompt the user that the video cannot be generated; wherein, the number of photos including the third portrait is less than a third threshold.

[0061] In some possible implementations, after displaying the eighth interface, the method further includes:

[0062] In response to the user selecting the third number of portraits, an eighteenth interface is displayed, the eighteenth interface including a fourth window, the fourth window being used to prompt the user that the video cannot be generated; wherein the third number is greater than a fourth threshold.

[0063] In some possible implementations, before generating the first video, the method further includes:

[0064] Based on the first portrait, acquiring a plurality of second photos, each second photo including the first portrait;

[0065] Selecting a first number of second photos from the plurality of second photos according to a principle of uniform time distribution;

[0066] Selecting a second number of second photos from the first number of second photos according to the timeline from oldest to most recent;

[0067] The generating of the first video includes:

[0068] The first video is generated based on the second number of second photos and the first photos.

[0069] Therefore, through the above-mentioned mechanism of selecting photos and generating videos, moment videos generated from photos under different timelines can be obtained, which provides a better user experience.

[0070] In a second aspect, a video processing method is provided, comprising:

[0071] In response to a sixth operation by the user, displaying a seventh interface, the seventh interface being used to display a moment page of the gallery application, the seventh interface including a second control;

[0072] In response to a user clicking on the second control, an eighth interface is displayed, wherein the eighth interface is used to display data of a plurality of portraits;

[0073] In response to the user selecting the second portrait, a second video is generated, where the second video includes a photo of the second portrait.

[0074] Display the playback interface of the second video.

[0075] The above method can be executed by an electronic device or a chip in an electronic device. Based on the above technical solution, the electronic device (or the chip in the electronic device) provides an entry to the "Generate Moment" function located on the Moments page of the gallery application. Through this entry, the user can actively select a target portrait. The electronic device then actively generates a moment video related to the target object based on the target portrait selected by the user, which is more targeted and greatly improves the user experience.

[0076] Regarding the entry of the "Generate Moment" function in the Moment page of the gallery application, some possible implementation methods and technical effects of the implementation methods can be referred to the description in the first aspect. For the sake of brevity, they will not be repeated here.

[0077] In a third aspect, an electronic device is provided, comprising a unit for executing the method of any one of the implementations of the first or second aspects. The electronic device may be a terminal device or a chip within the terminal device. The electronic device includes an input unit, a display unit, and a processing unit.

[0078] When the electronic device is a terminal device, the processing unit may be a processor, the input unit may be a communication interface, and the display unit may be a graphics processing module and a screen; the terminal device may also include a memory for storing computer program code, and when the processor executes the computer program code stored in the memory, the terminal device executes the method in any one of the implementation modes of the first aspect or the second aspect.

[0079] When the electronic device is a chip in a terminal device, the processing unit may be a logic processing unit inside the chip, the input unit may be an input interface, pin or circuit, etc., and the display unit may be a graphics processing unit inside the chip; the chip may also include a memory, which may be a memory inside the chip (for example, a register, a cache, etc.) or a memory located outside the chip (for example, a read-only memory, a random access memory, etc.); the memory is used to store computer program code, and when the processor executes the computer program code stored in the memory, the chip executes the method in any one of the implementations of the first aspect or the second aspect.

[0080] In a fourth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program code. When the computer program code is executed by an electronic device, the electronic device executes the method in any one of the implementations of the first aspect or the second aspect.

[0081] In a fifth aspect, a computer program product is provided, comprising: a computer program code, which, when executed by an electronic device, enables the electronic device to execute the method in any one of the implementations of the first aspect or the second aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0082] FIG1 is a schematic diagram of a hardware system of an electronic device applicable to the present application;

[0083] FIG2 is a schematic diagram of an interface for entering a gallery application provided by this application;

[0084] FIG3A is a schematic diagram of an interface for generating a moment video provided by the present application;

[0085] FIG3B is a schematic diagram of another example of an interface for generating a moment video provided by the present application;

[0086] FIG4 is a schematic diagram of an interface provided by the present application when a moment video cannot be generated;

[0087] FIG5 is another example provided by the present application of the interface diagram when the moment video cannot be generated;

[0088] FIG6 is a schematic diagram of another example of an interface for generating a moment video provided by the present application;

[0089] FIG7 is a schematic diagram of another example of an interface for generating a moment video provided by the present application;

[0090] FIG8 is a schematic diagram of an interface provided by the present application when a moment video cannot be generated;

[0091] FIG9 is a schematic diagram of another example of an interface for editing a moment video provided by the present application;

[0092] FIG10 is a schematic diagram of an interface for displaying a video of a display area at a specific moment provided by the present application;

[0093] FIG11 is a flowchart illustrating a method for generating a moment video provided by the present application;

[0094] FIG12 is a schematic diagram of a software system of an electronic device applicable to the present application. DETAILED DESCRIPTION

[0095] The technical solutions in the embodiments of the present application will be described below with reference to the accompanying drawings.

[0096] In the embodiments of the present application, unless otherwise specified, “a plurality of” may mean two or more.

[0097] The embodiment of the present application can be applied to an electronic device, wherein a gallery application is installed in the electronic device.

[0098] In some embodiments of the present application, the electronic device may be a mobile phone, a smart screen, a tablet computer, a wearable electronic device, an in-vehicle electronic device, an augmented reality (AR) device, a virtual reality (VR) device, a laptop computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), a projector, and the like.

[0099] In the following, a mobile phone is used as an example of an electronic device, and FIG1 shows a schematic diagram of the structure of an electronic device 100 provided in an embodiment of the present application. FIG1 shows a hardware system of an electronic device applicable to the present application.

[0100] 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, etc. 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.

[0101] It should be noted that the structure shown in FIG1 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 those shown in FIG1, or the electronic device 100 may include a combination of some of the components shown in FIG1, or the electronic device 100 may include sub-components of some of the components shown in FIG1. ​​The components shown in FIG1 may be implemented in hardware, software, or a combination of software and hardware.

[0102] The processor 110 may include one or more processing units. For example, the processor 110 may include at least one of the following processing units: an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and a neural-network processing unit (NPU). The different processing units may be independent devices or integrated devices.

[0103] The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of instruction fetching and execution.

[0104] Processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in processor 110 is a cache memory. This memory can store instructions or data that have just been used or are being recycled by processor 110. If processor 110 needs to use the same instruction or data again, it can directly access the memory. This avoids duplicate accesses, reduces processor 110 latency, and thus improves system efficiency.

[0105] In some embodiments, the processor 110 may include one or more interfaces. For example, the processor 110 may include at least one of the following interfaces: 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 SIM interface, and a USB interface. The connection relationship between the modules shown in Figure 1 is only a schematic illustration and does not constitute a limitation on the connection relationship between the modules of the electronic device 100. Optionally, the modules of the electronic device 100 may also adopt a combination of the multiple connection methods in the above embodiments.

[0106] Electronic device 100 can implement display functionality through a GPU, display screen 194, and an application processor. A GPU is a microprocessor for image processing that connects display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 110 may include one or more GPUs that execute program instructions to generate or modify display information.

[0107] The display screen 194 can be used to display images or videos. The display screen 194 includes a display panel. The display panel can use a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a mini light-emitting diode (Mini LED), a micro light-emitting diode (Micro LED), a micro OLED, or a quantum dot light-emitting diode (QLED). In some embodiments, the electronic device 100 may include one or N display screens 194, where N is a positive integer greater than one.

[0108] The electronic device 100 can implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, and an application processor.

[0109] The ISP processes data fed back by camera 193. For example, when taking a photo, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, which is then passed to the ISP for processing and converted into a visible image. The ISP can perform algorithmic optimization on image noise, brightness, and color. It can also optimize parameters such as exposure and color temperature of the captured scene. In some embodiments, the ISP can be located within camera 193.

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

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

[0112] Video codecs are used to compress or decompress digital video. Electronic device 100 may support one or more video codecs. This allows electronic device 100 to play or record videos in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, and MPEG4.

[0113] The NPU is a processor that draws inspiration from biological neural network architecture, such as the transmission patterns between neurons in the human brain, to rapidly process input information and continuously learn. The NPU enables intelligent cognitive functions in electronic device 100, such as image recognition, face recognition, voice recognition, and text comprehension.

[0114] The external memory interface 120 may be used to connect an external memory card, such as a secure digital (SD) card, to expand the storage capacity of the electronic device 100 .

[0115] The internal memory 121 can be used to store computer executable program codes, which include instructions. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, and applications required for at least one function (for example, a sound playback function and an image playback function). The data storage area may store data created during the use of the electronic device 100 (for example, audio data and a phone book). In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as: at least one disk storage device, a flash memory device, and a universal flash storage (UFS). The processor 110 executes various processing methods of the electronic device 100 by running instructions stored in the internal memory 121 and / or instructions stored in a memory provided in the processor.

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

[0117] The touch sensor 180K is also referred to as a touch-sensitive device. The touch sensor 180K can be disposed on the display screen 194. The touch sensor 180K and the display screen 194 form a touch screen, also referred to as a touch screen. The touch sensor 180K is used to detect touch operations applied thereto or in the vicinity thereof. The touch sensor 180K can transmit the detected touch operations to an application processor to determine the type of touch event. Visual output related to the touch operations can be provided via the display screen 194. In other embodiments, the touch sensor 180K can also be disposed on the surface of the electronic device 100 and at a different location from the display screen 194.

[0118] The buttons 190 include a power button and a volume button. The buttons 190 may be mechanical buttons or touch buttons. The electronic device 100 may receive button input signals and implement functions related to the button input signals.

[0119] The technical solutions involved in the following embodiments can all be implemented in the electronic device 100 having the above hardware architecture.

[0120] For ease of understanding, the following embodiments of the present application will take an electronic device having the structure shown in FIG1 as an example, and combine the figure and application scenarios to specifically illustrate the recording method provided in the embodiments of the present application.

[0121] This application will take a mobile phone as an electronic device, with a camera application and a gallery application installed in the mobile phone as an example, to introduce in detail the video processing method provided by this application.

[0122] The following describes an application scenario of an embodiment of the present application in conjunction with Figure 2. Referring to Figure 2, Figure 2 is a schematic diagram of a graphical user interface (GUI) provided by an embodiment of the present application.

[0123] For example, as shown in FIG2 (1), the screen display system of the mobile phone displays the currently output interface content, which displays multiple applications (applications, Apps). The user can click on the "Gallery" application icon 201 on the mobile phone desktop; in response to the user's operation of clicking on the "Gallery" application icon 201, the mobile phone opens the Gallery application, and the mobile phone displays the interface of the Gallery application as shown in FIG2 (2).

[0124] For another example, the user may also input a voice command through voice control; in response to the voice command input by the user, based on the content recognized by the voice command, the mobile phone opens the gallery application and may also display the interface shown in (2) in Figure 2.

[0125] For another example, when the phone is running other applications and the gallery application is running in the background, the user can also enter the gallery application through the multitasking interface. The embodiment of the present application does not specifically limit the method of entering the gallery application.

[0126] As shown in (2) of Figure 2, the gallery application interface includes different types of tabs, namely: photo page, album page, moment page and creation page (or named discovery page). The gallery application interface displays the photo page by default. The photo page is used to display all photos taken or saved by the user. The album page is used to display the albums corresponding to the classified and saved photos. The moment page is used to display the generated moment video. The creation page is used to freely create or assemble puzzles based on the photos selected by the user.

[0127] Figure 2 (2) shows the interface of the photo page, which includes thumbnails of multiple photos. For example, the thumbnail of photo 202, the thumbnail of photo 203, and the thumbnail of photo 204. Among them, photos 202 and 203 include portraits, and photo 204 is a landscape photo and does not include a portrait. For any photo thumbnail in the interface, in response to the user clicking on the photo thumbnail, the mobile phone displays the full image of the photo.

[0128] When the user clicks on the photo 202 shown in (2) of Figure 2, the photo 202 can be viewed in a large image, and the interface of the mobile phone is displayed as shown in (3) of Figure 2. The photo 202 contains two portraits. The interface shown in (3) of Figure 2 includes options such as share, favorite, edit, delete, and more. If the user clicks share, the photo 202 can be shared; if the user clicks favorite, the photo 202 can be favorited in a folder; if the user clicks edit, the photo 202 can be edited; if the user clicks delete, the photo 202 can be deleted; if the user clicks more, other operation functions for the photo 202 can be entered (such as move, copy, add notes, hide, rename, etc.). The interface shown in (3) of Figure 2 also includes time information and a return control. The time information is used to display the shooting time of the photo 202. If the user clicks the return control, it will return to the interface shown in (2) of Figure 2.

[0129] It should be understood that the description here is based on the example of the photo shown in (3) in Figure 2 containing two portraits, and the embodiments of the present application are not limited to this. In fact, the photo can contain one portrait or more than two portraits.

[0130] When a user browses a photo containing a person's portrait (e.g., photo 202), the user desires to view historical photos related to the person. However, in the related art, the user cannot view these photos, or needs to return to the main interface of the gallery application, enter the album page or other pages, find the person's tag information, and then find the related person from the person's tag before viewing the photos related to the person, which is inconvenient.

[0131] This application provides an interactive method. In order to recommend photos related to a person's portrait to the user and generate a moment video, the embodiment of the application adds a "Generate Moment" function entry to the gallery application. Through this entry, the mobile phone can actively generate a moment video of the target portrait for the user, which is convenient to operate.

[0132] The embodiment of the present application provides multiple entrances to the "generate time" function.

[0133] In one possible implementation, when a user is browsing a large image in a gallery, and the large image contains a portrait, in response to the user swiping up on the image, the phone displays a "Create Moment" function entry below the image. The first "Create Moment" function entry is described below with reference to Figures 3A to 5.

[0134] Figure 3A shows an example diagram of a GUI for generating a moment video according to an embodiment of the present application. The interface shown in (1) in Figure 3A is the interface of the gallery application, which includes a large picture of a certain photo (for example, it can be photo 202). The photo contains two portraits. The user swipes up on the interface, and the mobile phone responds to the user's swipe up operation and can display the interface shown in (2) in Figure 3A, and can enter the entrance of the "Generate Moment" function. For example, the user swipes the screen upward in the dotted arrow area shown in (1) in Figure 3A, and the interface displays the interface shown in (2) in Figure 3A. The interface shown in (2) in Figure 3A can be understood as a swipe up page for the large picture of the photo.

[0135] As shown in FIG3A (2), the interface includes a portion of the content or area of ​​photo 202, card 301, card 302, and card 304. Card 301 is used to display the portrait or character label image contained in the photo. If the user clicks on a character label image, the phone will display photos related to the character label image (or display a cluster of the character label image).

[0136] For example, card 301 displays the portraits labeled "A" and "B," respectively. Card 302 displays the entry to control 303 for the "Generate Moments" function. Card 302 may also contain other prompts to inform the user of the "Generate Moments" function, such as "Intelligent analysis generates portrait moments." Card 304 displays the location of the photo via a map, for example, the geographic location at the time the photo was taken.

[0137] It should be noted that the name of the portrait can be pre-added by the user. For a portrait without a name, when the thumbnail of the portrait is displayed in the card 301, the corresponding content displayed below the thumbnail of the portrait can be "unnamed" or "no name added" or the like.

[0138] Furthermore, for portraits without names, the phone can add a name to them in response to a user clicking on the portrait in card 301. For example, in response to a user clicking on "Portrait without a name" in card 301, the phone displays a pop-up window in the interface, which includes an input field. In response to the user entering a name in the input field, the portrait is named.

[0139] Control 303 can be understood as a button. When the user clicks control 303, the mobile phone responds to the user's operation of clicking control 303 by analyzing the data in the gallery, searching for multiple photos containing both portraits A and B (or photos of portraits A and B together), and generating a moment video using the multiple photos containing both portraits A and B.

[0140] For example, the interface display of the generated moment video is shown in (4) in FIG3A . As shown in (4) in FIG3A , the cover of the generated moment video, or the moment playback page, is immersively displayed. Immersive display refers to the display method in which the picture fills the mobile phone screen. The cover of the generated video includes text information and time information. The text information can be generated based on the photo. For example, the text of the photo can be the name corresponding to the portrait, or the name of the shooting location, etc. Alternatively, the text information is intelligently matched or intelligently generated text based on the content of the photo (or the picture information). The time information refers to the time of the generated moment. In some embodiments, the text information and time information are only displayed in the first frame of the generated moment video, that is, when the "A and B moment video" is dynamically played, the other frames no longer display the text information and the time information. Dynamic playback of the "A and B moment video" can be understood as playing the photos used to generate the video in chronological order (for example, from the oldest to the most recent time order).

[0141] It should be noted that for a portrait without a name, after generating its moment video, the text information of the moment video can be captioned with other texts, such as: "figure", "this person's moment", etc.

[0142] It is understood that the interface shown in (4) in FIG3A is only the display of the first frame of the generated moment video of portrait A and portrait B, and will not remain on this interface. Moreover, during the subsequent playback process, other frames will not display the accompanying text information and the time information.

[0143] It should also be noted that (1) in FIG3A is described using the example of a photo containing a portrait. That is, when a portrait is detected, the interface (2) in FIG3A displayed by the mobile phone in response to the user's upward swipe operation will include a moment card and further include an entry or button (e.g., control 303) for the "Generate Moment" function. However, if no portrait is detected, the entry for the "Generate Moment" function will not be displayed to the user.

[0144] The following describes the situation where the photo viewed by the user does not include a portrait, in conjunction with Figure 3B. Figure 3B shows an example diagram of another GUI for generating a moment video according to an embodiment of the present application. The interface shown in (1) in Figure 3B includes a thumbnail of photo 204, which is a landscape photo. Photo 204 does not include a portrait. If the user clicks on the thumbnail of photo 204 in (1) in Figure 3B, in response to the user clicking on the thumbnail of photo 204, the mobile phone displays a large image of photo 204, as shown in the interface shown in (2) in Figure 3B. In response to the user swiping up on the display interface of the large image of photo 204, the mobile phone displays the interface shown in (3) in Figure 3B. As shown in (3) in Figure 3B, the interface includes a card 306, which is used to display the shooting location information of photo 204. In addition, the interface shown in (3) in Figure 3B does not include a moment card, nor does it include an entry or button (such as control 303) for the "generate moment" function, but may include the shooting location information of the photo.

[0145] In addition, the above is explained using the example of a moment video corresponding to the photo shown in (1) in FIG3A not yet generated. If the photo shown in (1) in FIG3A has been actively clustered by other photos to generate a moment video, then after performing the swipe up operation, the interface will be displayed as shown in (1) in FIG9 .

[0146] In some embodiments, if the time required to generate the moment video is short, or the generation speed is relatively fast, then after the user clicks the "Generate Moment" function, they can directly jump to the above-mentioned "immersive display of the generated moment video cover". If the time required to generate the moment video is long, or the generation speed is relatively slow, then while the user is waiting, the loading status can be displayed in the card 302. For example, in the interface shown in (3) of Figure 3A, the dynamic icon 305 displayed in the control 303 is used to indicate that it is currently loading.

[0147] It is understood that the loading pattern shown in the dynamic icon 305 is only an example description. While waiting for the generation of the moment video, the dynamic icon 305 can change dynamically (such as by dynamically changing in a circle). Through the dynamic icon 305, the user can know that the moment video is currently being generated.

[0148] That is, after the user clicks control 303, the interface shown in (4) in FIG. 3A may be directly jumped to; or the interface shown in (3) in FIG. 3A may be displayed first, and after the moment video is generated, the interface automatically jumps to the interface shown in (4) in FIG. 3A.

[0149] In addition, after the moment video is generated, the content contained in the card 302 of the large picture page of the photo will be updated accordingly. Optionally, when the user performs a side-sliding operation in the side-sliding area shown in (4) of Figure 3A, he can return to the large picture page. At this time, the content contained in the card 302 in the large picture page has been updated accordingly, that is, the generated moment video is synchronized to the large picture page of the corresponding photo and displayed in the form of a thumbnail. For example, as shown in (3) of Figure 9, the card 302 will contain a thumbnail 901 of the generated moment video.

[0150] It should be understood that the side sliding area shown in (4) in FIG3A is located at the right edge area of ​​the screen. This side sliding area is only an example description and the embodiments of the present application are not limited thereto. For example, the side sliding area may also be located at the left edge area of ​​the screen.

[0151] In some embodiments, during the process of generating a moment video, when the user exits the application and enters other applications, assuming that the process of the gallery application is interrupted (for example, the process of the gallery application is cleared or closed, or in other words, in response to the user closing the gallery application process, the mobile phone stops running the gallery application process), then the process of generating the moment video is interrupted, that is, the photo analysis process is no longer performed; assuming that the process of the gallery application is not cleared, then when the user enters the gallery application again, in response to the user opening the gallery application again, the content displayed on the interface of the mobile phone depends on whether the moment video has been completed, specifically including: if the moment video has been completed, then the playback page of the moment video is displayed (for example, the interface shown in (4) in Figure 3A); if the moment video is still in the loading process, then the loading status of the moment video is displayed (for example, the interface shown in (3) in Figure 3A).

[0152] It should be noted that during the process of generating the moment video, the process of generating the moment video cannot be interrupted. For example, when the interface shown in (3) in Figure 3A is displayed, the user cannot exit from the loading interface to view other photos. However, the gallery application can be retreated to the background. After the gallery application is retreated to the background, the gallery application is still executing the process of generating the moment. In this way, when the user enters the gallery application again, if the moment video has been generated, in response to the user clicking the gallery application again, the mobile phone displays the playback page of the moment video (for example, the interface shown in (4) in Figure 3A).

[0153] When generating a moment video based on the currently viewed photo, in some cases, it may be impossible to generate a moment video. The inability to generate a moment video may be due to the following reasons: due to the limited number of photos contained in the gallery, the number of relevant portrait photos is small or even non-existent, or the number of portraits contained in the currently viewed photo exceeds a preset threshold, which exceeds the analysis capability of the gallery application, or the photo 202 mentioned above is a photo that the user has just taken, for example, after taking photo 202 in the camera application, the user directly enters the interface shown in (3) of Figure 2 from the gallery entrance of the camera interface. Regardless of the reason, a prompt message can be sent to the user.

[0154] For example, FIG4 shows an example of a prompt window when a moment video cannot be generated. When the user clicks the control 303 shown in FIG3A (2), assuming that no other photos containing both portrait A and portrait B are found in the gallery application except for the photo 202 currently browsed by the user, the mobile phone responds to the user's operation of clicking the control 303 and displays the interface shown in FIG4, which includes a window 401. The user is prompted through window 401 that no relevant photos are found. The text prompt included in window 401 is "No relevant portrait photos are found. It is recommended to take more relevant portrait photos and charge the screen to increase the generation rate." Optionally, window 401 also includes an "OK" option. When the user clicks the "OK" option in window 401, the mobile phone responds to the user's operation of clicking the "OK" option and no longer displays window 401, that is, window 401 displayed in the interface disappears. Alternatively, the user does not perform any operation after seeing window 401. After a preset time period, the mobile phone no longer displays window 401, that is, window 401 displayed in the interface automatically disappears.

[0155] In some embodiments, if a user's viewed photo contains too many people, exceeding the gallery application's analysis capabilities, and the gallery application is unable to generate a moment video containing more than the preset number of people in response to the user clicking the Generate Moment function, a prompt message will be displayed to the user. For example, if the user's viewed photo is a group photo, that is, multiple people appear in the photo.

[0156] FIG5 shows another example of a prompt window for a moment video that cannot be generated. As shown in the interface of FIG5 (1), the user browses 10 portraits in the photos. When the user slides the screen upward, the interface is displayed as shown in FIG5 (2). In the interface shown in FIG5 (2), the 10 recognized portraits are displayed in sequence in card 301 (due to size limitations, only some of the portraits are shown in the figure). The embodiment of the present application does not specifically limit the display method of the 10 portraits in card 301. For example, the thumbnails of the 10 portraits only display thumbnails of 3 portraits in card 301. In response to the user's sliding screen operation in card 301 (sliding the screen to the left or sliding the screen to the right), the mobile phone displays thumbnails of other portraits in card 301. For another example, all the thumbnails of the 10 portraits can be displayed in card 301.

[0157] The functions of card 302 and card 304 can be referred to the description in FIG3A and will not be repeated here. When the user clicks the control 303 in card 302 shown in FIG5 (2), the interface is displayed as shown in FIG5 (3).

[0158] Assuming that the upper limit of the number of portraits is 10, since the number of portraits in the photo shown in (1) of FIG5 is 10, the upper limit has been reached, and the mobile phone displays the interface shown in (3) of FIG5. The interface includes a window 402, which is used to prompt the user why the moment video cannot be generated. For example, the content of window 402 is "The number of portraits exceeds the upper limit; there are too many portraits in this photo, please select other portraits to generate."

[0159] It should be understood that the above upper limit is only an example description, and the present embodiment does not impose a specific upper limit on the number of portraits. The upper limit can be a reasonable value set based on actual needs.

[0160] Optionally, the window 402 further includes an "I know" option. The disappearance mechanism of the window 402 can refer to the description of the window 401 above, which will not be repeated here.

[0161] In some embodiments, for multiple photos that have just been taken, if the mobile phone screen has not been turned off from the time the shooting is completed to the time the user clicks to view the photos that have just been taken, in response to the user clicking on one of the multiple photos, the mobile phone displays a large picture of the photo; in response to the user sliding up on the large picture interface (refer to the interface shown in (1) in Figure 3A), the mobile phone displays the entrance to the generated moment (refer to the interface shown in (2) in Figure 3A); in response to the user clicking on the entrance to the generated moment, a moment video of the portrait is generated.

[0162] That is, in response to the user's photo-taking operation, the mobile phone continuously takes multiple portrait photos (such as portrait Z) within a period of time. For a certain photo that the user is viewing in large image, in response to the user's upward sliding operation on the large image interface of the photo (refer to the interface shown in (1) in Figure 3A), the mobile phone displays the entrance to generate the moment (refer to the interface shown in (2) in Figure 3A); in response to the user clicking on the entrance to generate the moment, a moment video of portrait Z is generated. Moreover, since the screen is not turned off, the gallery application does not perform an analysis operation on these continuously taken photos, so when the mobile phone generates a moment video, it can use the photo of portrait Z in the gallery application to generate a moment video. However, other photos of the above-mentioned multiple continuously taken portrait photos, excluding the photo currently being viewed, even the photo of portrait Z, cannot be used to generate a moment video.

[0163] 3A to 5, the first entry to the "Generate Moment" function is introduced. This embodiment of the present application also provides another entry to the "Generate Moment" function. The entry to the "Generate Moment" function is located on the Moment page in the Gallery application.

[0164] In some embodiments, a feature for generating a moment video is added to the Moment page of the gallery application. This differs from the feature for generating a moment video while browsing photos in that after clicking the Generate Moment Video feature on the Moment page, users must further select a person to associate with the moment video. However, when generating a moment video while browsing photos, the gallery application automatically identifies a person based on the photos the user is browsing and generates a related moment video based on the identified person.

[0165] The following will describe an embodiment of adding a function entry for generating moment videos in the moment page of the gallery application with reference to FIG. 6 to FIG. 8 .

[0166] FIG6 (1) shows the moment page of the gallery application. For example, the user switches from the photo page to the moment page by clicking the "Moment" control in FIG2 (2), and the interface shown in FIG6 (1) is displayed. As shown in FIG6 (1), the interface includes a control 501, a first display area, a second display area and a search bar. Control 501 is the functional entry for generating moment videos. The first display area is used to display the card of the latest generated moment video, for example, card 502 is a moment video generated on January 14, 2023; the second display area is used to display the card of the moment video generated at another time (for example, a time later than January 14, 2023). The card of the moment video generated in the embodiment of the present application can be displayed in the first display area or the second display area, and the specific display area depends on the time when the moment video is generated; if it is the latest generated moment video, it can be displayed in the first display area; if it is not the latest generated moment video, it is not displayed in the first display area. The search bar is used for the user to enter the search content (including but not limited to photos, people, places, etc.) so as to find the desired photo or video based on the search content.

[0167] For example, the control 501 may be located in the upper right corner of the moment page. It should be understood that the position of the control 501 on the moment page shown in FIG6 (1) is only an example description, and the embodiments of the present application are not limited thereto.

[0168] When the user clicks on control 501, in response to the user's operation of clicking on control 501, the mobile phone displays an interface for selecting a portrait, so that the user can select the desired portrait to generate a memory video. As shown in the interface (2) in Figure 6, the interface displays the data of all portraits analyzed by the gallery application. The data of each portrait includes the number of photos corresponding to the portrait. For portraits to which the user has added a name, the portrait data also includes the name or title corresponding to the portrait; for portraits to which the user has not added a name, the portrait data does not include the name or title, but a prompt text "Add name" can be displayed in the portrait card to guide the user to name the portrait. Taking portrait 503 as an example, portrait 503 includes: portrait name (A), the number of photos related to portrait A (90), and check box 504. Photos related to A can be understood as: photos in which portrait A appears, such as photos of portrait A with others, personal photos of portrait A, etc. Check box 504 is used to display whether the portrait has been selected by the user. When the user clicks the check mark option 504 , it indicates that the portrait 503 is selected.

[0169] Optionally, as shown in (2) in FIG6 , the plurality of portrait data may be sorted in descending order according to the number. Alternatively, the plurality of portrait data may be sorted based on other factors, such as the close relationship with the camera owner, the frequency of appearance, etc., which are not specifically limited.

[0170] For example, after the user selects portrait 503 and portrait 505, the mobile phone responds to the user clicking on checkbox 504 and checkbox 506, and displays the interface as shown in Figure 6 (3). As shown in Figure 6 (3), checkbox 504 in portrait 503 and checkbox 506 in portrait 505 are selected, and the interface also displays a prompt "2 items selected". When the user completes the portrait selection, the mobile phone responds to the user clicking on icon 507, and the gallery application starts analyzing the photo data to generate a moment video.

[0171] Similarly, in the case where the user generates a moment video by selecting a portrait, if the time required to generate the moment video is short, or the generation speed is relatively fast, then after the user clicks icon 507, the mobile phone can directly jump to the above-mentioned "immersive display of the generated moment video cover" in response to the user's operation of clicking icon 507, such as the interface shown in (5) in Figure 6. If the time required to generate the moment video is long, or the generation speed is relatively slow, then while the user is waiting, the loading status can be displayed through the window. For example, in the interface shown in (4) in Figure 6, the dynamic icon 508 displayed in window 509 is used to indicate that it is currently loading. The text "Generating a portrait moment..." can also be displayed in window 509 to prompt the user that it is currently loading. It can be understood that the dynamic icon 508 is similar to the aforementioned dynamic icon 305, and the meaning of the dynamic icon 508 will not be repeated here. The interface shown in (5) in Figure 6 is similar to the interface shown in (4) in Figure 3A, and the content in the interface will not be repeated.

[0172] Optionally, in response to the user performing a side-slide operation (slide to the left or slide to the right) on the interface shown in FIG6 (5), the user can return to the interface of the moment page, for example, the interface shown in FIG6 (1). In addition, if the moment video generated in FIG6 (5) is the latest generated, then in the interface shown in FIG6 (1), the moment video is displayed in the top display area (the first display area); if the moment video generated in FIG6 (5) is a video obtained by updating the generated moment video, then in the interface shown in FIG6 (1), the moment video is displayed in the corresponding display area (i.e., the display area where the generated moment video was originally located).

[0173] The embodiment of the present application does not specifically limit the way in which the user generates the moment video through which function entrance. It should be noted that if the user selects a portrait and the selected portrait has already generated a related moment video, the moment video can be updated based on the portrait selected this time.

[0174] For example, after a moment video of "A and B" has been generated through the portrait selection method shown in Figure 6, after a period of time (for example, one day, one month, three months, etc.), the user enters the portrait selection interface shown in Figure 6 again and selects the portraits "A" and "B" again. In response to the user's operation of selecting the portraits "A" and "B" again after a period of time, the mobile phone analyzes the generated moment video of "A and B" again based on the gallery data, and obtains the updated moment video of "A and B".

[0175] For another example, when using the method of generating moment videos shown in FIG3A (i.e., triggering the generation of moment videos when browsing portraits), a moment video of "A and B" has been generated, and the user selects portraits "A" and "B" through the method of selecting portraits shown in FIG6 , then at this time, analysis can also be performed based on the gallery data to update the generated moment video of "A and B" to obtain an updated moment video of "A and B".

[0176] Of course, if the user selects a different portrait from the one previously selected when generating a moment video, or if a moment video for the selected portrait has not been generated before, then a corresponding moment video will be generated based on the portrait selected by the user. For example, in the interface shown in (1) of FIG7 , after the user selects portrait 601, portrait 602, and portrait 603, the user clicks icon 507. In response to the user clicking icon 507, the mobile phone generates moment videos for portraits 601, 602, and 603. The moment videos for portraits 601, 602, and 603 are generated, and the interface shown in (2) of FIG7 is displayed. As shown in (2) of FIG7 , the cover of the moment video generated by the mobile phone based on portraits 601, 602, and 603 includes the characters corresponding to portraits 601, 602, and 603. Similarly, in the process of generating a moment video by selecting a portrait, there may be a situation where a moment video cannot be generated. At this time, a prompt window may also be used to prompt the user.

[0177] In some embodiments, when the number of portraits selected by the user is insufficient, the gallery application cannot generate the corresponding moment video. For example, in response to the user selecting portrait A and portrait B, the mobile phone displays the interface shown in (1) of Figure 8. The interface includes window 801, which prompts the user. The content of window 801 is similar to the content of window 401 mentioned above, and for the sake of brevity, it is not repeated here.

[0178] In some embodiments, when the number of portraits selected by the user exceeds a preset threshold, the gallery application cannot generate the corresponding moment video. For example, when the number of portraits selected by the user is 10, in response to the user selecting 10 portraits, the mobile phone displays the interface shown in (2) of Figure 8. The interface includes window 802, which prompts the user. The content of window 802 is similar to the content of window 402 mentioned above, and for the sake of brevity, it is not repeated here.

[0179] The above provides two entrances for generating moment videos. After generating a moment video, when a user opens a large image page of a photo included in the moment video, in response to the user's upward sliding operation on the large image page, the displayed interface includes the moment video.

[0180] FIG9 is another example diagram of a GUI interface provided by an embodiment of the present application. As shown in FIG9 (1), the interface includes a thumbnail of photo 203. Among them, photo 203 and photo 202 contain the same portrait, for example, photo 203 and photo 202 are both group photos of portrait A and portrait B. In response to the user clicking on photo 203 shown in FIG9 (1), the mobile phone displays an interface as shown in FIG9 (2), which includes a large image of photo 203. It can be understood that the interface shown in FIG9 (2) may also include other controls, such as sharing, collecting, editing, deleting and more, etc. The relevant explanations of each control have been described above and will not be repeated here.

[0181] For example, after the video corresponding to the portraits A and B in photo 202 has been generated based on the interface of FIG3A, the user slides the screen upward according to the dotted arrow area in the interface shown in FIG9 (2). The mobile phone responds to the user's upward swipe operation on the large image browsing page of photo 203, and the interface is displayed as shown in FIG9 (3). As shown in FIG9 (3), the interface includes card 302. Card 302 displays thumbnail 901, that is, the moment video card of "A and B".

[0182] Thumbnail 901 includes a play control 902. When the user clicks on the play control 902, the mobile phone displays the play interface of the video at the moment of "A and B" in response to the user's operation of clicking on the play control 902, allowing the user to enter the immersive card playback. Immersive card playback is a playback method in which the picture fills the entire screen. As can be seen, in the interface shown in (5) in Figure 9, the picture fills the entire mobile phone screen.

[0183] Optionally, in some embodiments, in response to the user sliding up the screen in (2) of FIG9 , the mobile phone displays the interface shown in (4) of FIG9 . As shown in (4) of FIG9 , the interface includes a card 302. The card 302 includes not only a thumbnail 901 and a play control 902, but also an update control 907. In response to the user clicking the update control 907, the mobile phone updates the generated moment video of "A and B".

[0184] As shown in the interface (5) of Figure 9, the interface includes controls 903, 904, 905, 906, a playback progress bar, and the like. Control 903 is a return control. When the user clicks on control 903, the mobile phone responds to the user's operation of clicking on control 903, and the mobile phone interface returns to the interface shown in (3) of Figure 9 or the interface shown in (4) of Figure 9. Control 904 is used to provide editing operations to the user. Control 905 is a sharing control; when the user clicks on control 905, the mobile phone responds to the user's operation of clicking on control 905 and displays the sharing interface. Control 906 is a more information control; when the user clicks on control 906, the mobile phone responds to the user's operation of clicking on control 906 and displays the detailed information interface of the video at that moment for the user to view. The playback progress bar can also be called a slider bar. The user can adjust the playback progress by dragging the slider bar. For example, the video is currently playing to the 12th second, and the total length is 56 seconds.

[0185] Optionally, the progress bar also includes a pause control and a speaker control. If the user clicks the pause control, the mobile phone pauses the video in response to the user clicking the pause control. If the user clicks the speaker control, the mobile phone plays the video in silence in response to the user clicking the speaker control.

[0186] In addition, the interface shown in (5) in FIG9 may also include other controls for video editing at the bottom of the screen, such as template, music, filter, album, etc. If the user can click on the music control, the mobile phone will respond to the user's operation of clicking on the music control and display music options in the interface, so that the user can select music for the video at that moment, such as soothing, romantic, warm, cozy, tranquil, etc. If the user clicks on the template control, the mobile phone will respond to the user's operation of clicking on the template control and display template options in the interface, so that the user can process the video at that moment by applying the template. The template can be a template with a certain style or theme generated based on the theme, music, filter, etc. If the user clicks on the filter control, the mobile phone will respond to the user's operation of clicking on the filter control and display filter options in the interface, so that the user can select a filter to adjust the color of the video. Filters are a type of video special effects used to achieve various special effects in videos. If the user clicks on the album control, the mobile phone will respond to the user's operation of clicking on the album control and jump to the interface, which displays all the photos used to generate the video. These photos can be presented to the user in a grid format.

[0187] Optionally, the number of photos used in the moment video generated based on the portrait may be less than or equal to a preset number.

[0188] It is understandable that the embodiment of the present application does not limit the duration of the generated moment video. For example, the generated moment video can be a 20-second wonderful short video generated based on a portrait, or it can be a 1-minute wonderful short video.

[0189] Figure 10 shows an example interface for the Moment page in the Gallery app. As shown in Figure 10, the moment videos displayed in the first display area and the moment videos displayed in the second display area were generated at different times. The moment video displayed in the first display area is the most recently generated moment video. It should be understood that the moment videos displayed in the display area are all cards corresponding to the moment videos, and the cover of each card can be the photo with the highest aesthetic score in the moment video.

[0190] It should be noted that for a moment video that has already been generated, when the moment video that has already been generated is updated, the updated moment video will still be displayed according to the position of the moment video before the update in the display area. That is to say, even if the moment video that has already been generated is updated, its display position in the display area will not change.

[0191] It can be understood that the examples in Figures 2 to 10 are only for the convenience of understanding by those skilled in the art and do not limit the scope of protection of the embodiments of the present application.

[0192] Please refer to Figure 11, which is a schematic flow chart of the video processing method provided in an embodiment of the present application. As shown in Figure 11, the method includes:

[0193] Step 701: In response to a first operation by a user, a first interface is displayed, where the first interface includes a thumbnail of a first photo, and the first photo includes a first portrait.

[0194] The first operation is an operation for opening the gallery application. For example, in the interface shown in (1) of FIG2 , the first operation is an operation in which the user clicks on the icon 201 .

[0195] It should be understood that step 701 is described based on the example of recognizing that the first photo contains one portrait, and the embodiments of the present application are not limited thereto. The first photo may contain two or more portraits. For example, assuming that the first photo contains two portraits, the first interface is the interface shown in (2) in Figure 2, and the first photo is photo 202.

[0196] Step 702: In response to the user clicking on the thumbnail of the first photo, a second interface is displayed, where the second interface is used to display a browsing page of the first photo.

[0197] The second interface is a large picture interface showing the first photo. For example, the second interface may be the interface shown in (3) in FIG2 .

[0198] Step 703: In response to a second operation of the user on the second interface, a third interface is displayed, where the third interface includes a first area, and the first area includes a first control.

[0199] The second operation may be an operation of sliding the screen upward. For example, in the interface shown in (1) of FIG3A , the second operation is an operation of the user sliding the screen upward along the dotted arrow. The third interface may be the interface shown in (2) of FIG3A ; the first area may be the area corresponding to the card 302 shown in (2) of FIG3A ; and the first control may be control 303.

[0200] It is understandable that other information about the first photo can also be displayed in the third interface.

[0201] Optionally, the third interface further includes a partial area of ​​the first photo, a second area and / or a third area; the second area is used to display portrait tag information; and the third area is used to display shooting location information of the first photo.

[0202] Step 704: In response to the user's operation on the first control, a playback interface of the first video is displayed, where the first video includes a first photo and a second photo, and the second photo includes the first portrait.

[0203] Of course, when the number of portraits contained in the photo does not exceed the processing upper limit of the gallery application (for example, 10), the gallery application can generate a moment video related to the portraits.

[0204] Optionally, in some embodiments, the user's operation on the first control refers to: the user clicking the first control. For example, the first control is the control 303 shown in (2) in FIG3A .

[0205] The first video refers to the portrait moment video corresponding to the first photo, which can also be referred to as the moment video. For example, (4) in Figure 3A shows the cover of the first video.

[0206] Optionally, when playing the generated first video, the photos used to generate the first video (i.e., the first photo and a preset number of second photos) can be played in sequence according to the time information. For example, the photos used to generate the first video can be played in order of the older the photo, the earlier it is played.

[0207] In an embodiment of the present application, an entrance to the "Generate Moments" function is added to the gallery application. Through this entrance, the electronic device can generate moment videos related to the target portrait for the user to meet the user's desire to view historical memory moments related to the portrait, thereby greatly improving the user experience.

[0208] When a large number of group photos of the first and second persons are identified or computing power is affected, the process of generating the first video requires a certain waiting time. While waiting for the first video to load, a dynamic icon can be displayed to the user to indicate that the video is currently loading.

[0209] Optionally, in some embodiments, during the process of generating the first video, the method further includes:

[0210] A dynamic icon is displayed in the first area, where the dynamic icon indicates that the first video is being generated.

[0211] Exemplarily, the dynamic icon may be the icon 305 in the interface shown in (3) in FIG. 3A .

[0212] The above description is about the case where the first photo contains a portrait. However, for photos that do not contain a portrait, such as landscape photos, after swiping up on the large photo browsing page, the electronic device will not display the function entrance at the time of creation.

[0213] Optionally, in some embodiments, the first interface further includes a thumbnail of a second photo, and the second photo does not include a portrait; the method further includes:

[0214] In response to a user clicking on a thumbnail of the second photo, displaying a fourth interface for displaying a browsing page of the second photo;

[0215] In response to a fourth operation of the user on the fourth interface, a fifth interface is displayed, where the fifth interface does not include the first control.

[0216] For example, the second photo is the photo 204 shown in (2) in Figure 2. The fourth interface is the interface shown in (2) in Figure 3B. The fifth interface is the interface shown in (3) in Figure 3B.

[0217] Optionally, in some embodiments, after displaying the playback interface of the first video, the method further includes:

[0218] In response to a fifth operation of the user on the playback interface of the first video, displaying a sixth interface, wherein the sixth interface includes the first area, the first area does not include the first control, and the first area includes a thumbnail of the first video and a playback control;

[0219] In response to the user clicking the playback control, the playback interface of the first video is displayed.

[0220] That is, after the first video is generated, in response to the user's return operation (for example, clicking the return control 903 shown in (5) of Figure 9, or performing a side-slide operation in the side-slide area of ​​the screen), the mobile phone displays the upward sliding interface of the first photo, and the function entry (first control) in the first area of ​​the interface originally used to display the generation time is replaced by a thumbnail of the first video and a play control. For example, the sixth interface can be the interface shown in (3) of Figure 9.

[0221] Optionally, in some embodiments, the first interface further includes a thumbnail of a third photo, where the third photo includes the first portrait; and the method further includes:

[0222] In response to a user clicking on a thumbnail of the third photo, a ninth interface is displayed, wherein the ninth interface is used to display a browsing page of the third photo;

[0223] In response to the user's seventh operation on the ninth interface, the tenth interface is displayed, and the tenth interface includes the first area, and the first area includes a thumbnail of the first video and a playback control.

[0224] For example, assuming that the third photo includes two portraits, the third photo is photo 203 shown in (2) of Figure 2. The ninth interface is the interface shown in (2) of Figure 9. The seventh operation is an operation of sliding upward according to the dotted arrow shown in (1) of Figure 9. The tenth interface is the interface shown in (3) of Figure 9 or the interface shown in (4) of Figure 9.

[0225] After the first video is generated, you can also update the first video. The following two methods are provided:

[0226] Method 1

[0227] Optionally, in some embodiments, the first area further includes a third control; and the method further includes:

[0228] In response to a user clicking on the third control, updating the first video;

[0229] After the update is completed, the playback interface of the updated first video is displayed.

[0230] The third control can be understood as an update control. Exemplarily, the third control is the update control 907 shown in (4) in FIG9 .

[0231] Method 2

[0232] Optionally, in some embodiments, the method further comprises:

[0233] In response to the user's eighth operation, displaying an eleventh interface, the eleventh interface is used to display a moment page of the gallery application, the eleventh interface including a second control;

[0234] In response to a user clicking on the second control, a twelfth interface is displayed, wherein the twelfth interface is used to display data of a plurality of portraits;

[0235] In response to a user selecting the first portrait, generating a third video, wherein the third video is an updated version of the first video;

[0236] Display the playback interface of the third video.

[0237] That is to say, after the first video is generated in response to the user clicking the first control, if the user enters the portrait selection interface at the Generate Moment function entrance on the Moment page of the Gallery application and selects the target portrait as the first portrait to regenerate the corresponding moment video, then the mobile phone updates the first video in response to the user selecting the first portrait and obtains the third video.

[0238] When the first video cannot be generated, a pop-up window may be displayed to the user to remind the user. The following describes situations where the first video cannot be generated under different scenarios.

[0239] Optionally, in some embodiments, the first interface further includes a thumbnail of a fourth photo, the fourth photo includes a second number of portraits, and the second number is greater than a second threshold; the method further includes:

[0240] In response to a user clicking on the thumbnail of the fourth photo, a thirteenth interface is displayed, wherein the thirteenth interface is used to display a browsing page of the fourth photo;

[0241] In response to a fourth operation of the user on the thirteenth interface (for example, an operation of sliding the screen upward), displaying a fourteenth interface, the fourteenth interface including the first area, and the first area including the first control;

[0242] In response to the user clicking the first control, a fifteenth interface is displayed, wherein the fifteenth interface includes a first window, and the first window is used to prompt the user that the video cannot be generated.

[0243] That is, when the number of portraits in the identified photo is greater than the second threshold, the first video cannot be generated. For example, the thirteenth interface is the interface shown in (1) in FIG5 . The fourteenth interface is the interface shown in (2) in FIG5 . The fifteenth interface is the interface shown in (3) in FIG5 , and the first window is the window 402 shown in (3) in FIG5 .

[0244] Optionally, in some embodiments, the method further comprises:

[0245] In response to the user clicking the first control, the sixteenth interface is displayed, and the sixteenth interface includes a second window, and the second window is used to prompt the user that the video cannot be generated, wherein the number of photos including the first portrait is less than a first threshold.

[0246] Exemplarily, the sixteenth interface may be the interface shown in FIG. 4 .

[0247] In addition to triggering the generation of the first video when browsing photos in the large image, the embodiment of the present application also provides another entry for generating the first video, that is, a new function entry for generating moments is added to the moment page of the gallery application to trigger the generation of the first video. It should be noted that the function entry for generating moments set on the moment page of the gallery application and the function entry set by sliding the page on the large image mentioned above can be implemented independently or in combination, and there is no specific limitation on this.

[0248] Optionally, in some embodiments, the method further comprises:

[0249] In response to the user's sixth operation, displaying a seventh interface, the seventh interface being used to display a moment page (also referred to as a memory page) of the gallery application, the seventh interface including a second control;

[0250] In response to a user clicking on the second control, an eighth interface is displayed, wherein the eighth interface is used to display data of a plurality of portraits;

[0251] In response to the user selecting the second portrait, a second video is generated, where the second video includes a photo of the second portrait.

[0252] Display the playback interface of the second video.

[0253] In response to a third operation by the user, displaying a third interface, the third interface being used to display a moment page (also referred to as a moment page) of the gallery application, the third interface including a third control;

[0254] In response to a user operation on the third control, displaying a fourth interface for displaying data of a plurality of portraits;

[0255] In response to the user selecting the first portrait and the second portrait, the second video is generated, and the second video is used to update the first video.

[0256] Display the playback interface of the second video.

[0257] For example, the seventh interface is the interface shown in (1) in Figure 6, and the second control is the control 501 in (1) in Figure 6. The eighth interface is the interface shown in (2) in Figure 6.

[0258] Of course, the user can select multiple portraits to generate corresponding videos. For example, in Figure 6 (3), the user selected portrait A and portrait B.

[0259] Similarly, in some embodiments, when a user actively selects a target person portrait to generate a video, it may be possible that the video cannot be generated. In this case, a prompt may be given to the user through a window.

[0260] Optionally, in some embodiments, the method further comprises:

[0261] In response to the user selecting the third portrait, the seventeenth interface is displayed, and the seventeenth interface includes a third window, and the third window is used to prompt the user that the video cannot be generated; wherein, the number of photos including the third portrait is less than a third threshold.

[0262] For example, the seventeenth interface may be the interface shown in (1) in FIG8 , and the third window may be window 801 .

[0263] Optionally, in some embodiments, the method further comprises:

[0264] After displaying the eighth interface, the method further includes:

[0265] In response to the user selecting the third number of portraits, an eighteenth interface is displayed, the eighteenth interface including a fourth window, the fourth window being used to prompt the user that the video cannot be generated; wherein the third number is greater than a fourth threshold.

[0266] For another example, the eighteenth interface may be the interface shown in (2) in FIG. 8 , and the fourth window may be window 802 .

[0267] Optionally, in some embodiments, before generating the first video, the method further includes:

[0268] Based on the first portrait, obtaining a plurality of second photos;

[0269] Selecting a first number of second photos from the plurality of second photos according to a principle of uniform time distribution;

[0270] From the first number of second photos, a second number of second photos is selected according to a timeline order from oldest to most recent, the preset number being the second number;

[0271] The generating of the first video includes:

[0272] The first video is generated based on the second number of second photos and the first photos.

[0273] That is to say, before generating the first video, you need to preliminarily select photos that meet the requirements in the gallery. Photos that meet the requirements refer to photos that meet the portrait requirements, or in other words, photos that contain the target portrait. For example, if you want to generate a moment video of the first person's portrait, then the photos that meet the requirements are photos of the first person alone. For another example, if you want to generate a moment video of the first and second portraits, then the photos that meet the requirements are photos of the first and second portraits, and the photo does not include other portraits besides the first and second portraits. Of course, optionally, you can also set other requirements for preliminary screening, such as the clarity of the photos, etc.

[0274] For multiple photos that meet the requirements, a first number of photos can be selected according to the principle of uniform distribution over time; then a second number of photos can be selected from the first number of photos according to the principle of timeline from oldest to most recent, and a first video can be generated based on the second number of photos.

[0275] For example, the photos taken by users in a certain time period are relatively dense. In order to avoid selecting too many photos in a certain period of time, the photos of the first data can be selected according to the principle of uniform distribution over time.

[0276] Optionally, in some embodiments, selecting a first number of second photos from the plurality of second photos according to a principle of uniform temporal distribution includes any of the following situations:

[0277] When the number of the plurality of second photos is less than or equal to a first threshold, selecting all of the plurality of second photos;

[0278] When the number of the plurality of second photos is greater than the first threshold, and the number of months corresponding to the second photos in the plurality of second photos is less than the first threshold, selecting the preset number of second photos based on a first strategy, wherein the first strategy comprises: performing multiple rounds of photo selection based on month information until the first number of second photos is obtained;

[0279] When the number of months corresponding to the second photos of the plurality of second photos is greater than the first threshold, the first number of second photos are selected based on a second strategy, where the second strategy is to select photos based on month information and photo rating information.

[0280] Taking the need to generate a video of the first person and the second person as an example, when the generation of the first video is triggered, photos containing the first person and the second person can be filtered out from all the photos in the gallery application. Assuming that the first threshold is 100, if the number of the multiple second photos is less than 100, then all are selected. If the number of the multiple second photos is greater than or equal to 100, and the number of months corresponding to the first number of second photos is less than 100 months, then multiple rounds of photo selection can be performed until 100 photos are selected, and each round of photo selection means selecting a second photo from each month according to the month. If the number of the multiple second photos is greater than 100, and the number of months corresponding to the number of the multiple second photos is greater than or equal to 100 months, the second photo with the highest aesthetic score is selected from each month to obtain 100 second photos.

[0281] Optionally, in some embodiments, a second number of second photos is selected from the first number of second photos according to a timeline order from oldest to most recent, and the preset number is the second number, including:

[0282] When the first number is less than or equal to a second threshold, selecting all of the plurality of second photos;

[0283] When the first number is greater than the second threshold, a second number of second photos are selected from far to near according to the timeline.

[0284] For example, the second threshold is 50 photos. If the second photo selected in the previous article is 100 photos, then 50 photos can be selected in order of the month from the most recent to the most recent.

[0285] Optionally, the first threshold and the second threshold may be different values ​​or the same value, which is not specifically limited.

[0286] It should be noted that the moment video can be updated later using new photos (i.e., photos that did not exist when the moment video was generated, which can be photos newly taken by the user). When updating the moment video, the aforementioned photo screening logic and moment video generation logic can be re-executed, and the photos used when updating the moment video need to be selected.

[0287] It should be noted that the photo selection logic described above is based on the example of ensuring that the first photo is included. That is, if the user swipes from the large image of the first photo to trigger the first video, the generated first video will definitely include the first photo. However, this restriction does not apply when the first video is generated from the entry on the Moments page of the Gallery app.

[0288] For example, suppose a user generates a first video from the Moments page of a gallery app. After the user selects a first and second person portrait, photos are selected based on the following logic: N photos (including both the first and second person portraits) that meet the requirements are initially selected from the gallery app. Assuming a first threshold of 100, if N is less than 100, then N photos are selected. If N is greater than 100 and the number of months corresponding to the N photos is less than 100, multiple rounds of photo selection are performed until 100 photos are selected, with each round of photo selection selecting one photo from each month. If N is greater than 100 and the number of months corresponding to the N photos is greater than or equal to 100, the photo with the highest aesthetic score is selected from each month, resulting in 100 photos. After selecting photos based on the above logic, assuming M photos are obtained, a video of the first and second person portraits can be generated based on the M photos according to the following logic: if M is less than or equal to 50, then M photos are selected to generate the video. If M is greater than 50, then 50 photos are selected in descending order of months to generate the video. For example, when N is less than 100 photos, if new photos are added to the database, the user can reselect the first portrait and the second portrait to generate the first video, thereby updating the first video.

[0289] It can be understood that the quantity thresholds involved in each of the above implementation methods can be set to reasonable values ​​based on actual needs, and the embodiments of the present application do not make specific limitations on this.

[0290] Figure 12 is a schematic diagram of the software structure of the electronic device 100 according to an embodiment of the present application. The layered architecture divides the software into several layers, each with a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system can be divided into five layers: the application (APP) layer, the application framework layer (FWK), the system library, and the kernel layer.

[0291] The application layer can include a series of application packages. For example, as shown in Figure 12, the application layer includes a camera application and a gallery application.

[0292] It is understandable that the application layer may also include other applications, such as calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, browser, WeChat, Alipay, Taobao and other applications.

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

[0294] It is understandable that the application framework layer may also include other contents, such as a window manager, a content provider, a view system, a phone manager, a resource manager, and a notification manager.

[0295] The window manager is used to manage window programs. The window manager can obtain the display size, determine whether there is a status bar, lock the screen, and take screenshots.

[0296] 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, and phone books.

[0297] The view system includes visual controls, such as those for displaying text and images. The view system can be used to build applications. A display interface can consist of one or more views. For example, a display interface that includes a text notification icon can include a view for displaying text and a view for displaying images. The application layer and the application framework layer run in a virtual machine. The virtual machine executes the Java files in the application layer and application framework layer as binary files. The virtual machine is responsible for performing functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.

[0298] As shown in FIG12 , the system library may include camera service functions.

[0299] The system library can also include multiple functional modules, such as: surface manager, media library, 3D graphics processing library (such as open graphics library for embedded systems (OpenGL ES)) and 2D graphics engine (such as skia graphics library (SGL)).

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

[0301] The media library supports playback and recording of multiple audio and video formats, as well as still image files. It supports a variety of audio and video codecs, such as MPEG4, H.264, Moving Picture Experts Group Audio Layer III (MP3), Advanced Audio Coding (AAC), Adaptive Multi-Rate (AMR), Joint Photographic Experts Group (JPG), and Portable Network Graphics (PNG).

[0302] The 3D graphics processing library can be used to implement 3D graphics drawing, image rendering, compositing and layer processing.

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

[0304] The kernel layer is the layer between hardware and software. As shown in Figure 12, the kernel layer can include driver modules such as the power management module, display driver, and camera driver. The camera driver is the driver layer for camera devices and is primarily responsible for interacting with the hardware. Optionally, the power management module can report charging events to the application layer, such as the gallery application, so that the gallery application can perform photo analysis while the electronic device is charging, helping to save power.

[0305] For example, the gallery app in the application layer can be displayed as an icon on the electronic device's screen. When the gallery app icon is triggered, the electronic device launches the camera app. The gallery app runs on the electronic device, and the electronic device can send corresponding touch events to the driver layer based on user actions. When the touchscreen receives the touch event, it launches the gallery app, which then calls the driver layer's display startup to display the gallery page on the screen.

[0306] For example, the gallery application in the application layer receives a user-triggered viewing operation for viewing pushed photos or videos, and displays the pushed photos or videos on a display screen by calling a display driver.

[0307] From the above, it can be seen that the video processing method provided by this application adds an entry for the "Generate Moments" function in the gallery application to generate moment videos related to portraits, so as to meet the user's desire to view historical memory moments related to the portrait, thereby intuitively perceiving the changes brought about to the object over the years, greatly improving the user experience.

[0308] The present application also provides a computer program product, which, when executed by a processor, implements the method described in any method embodiment of the present application.

[0309] The computer program product can be stored in a memory and finally converted into an executable target file that can be executed by a processor through preprocessing, compilation, assembly and linking.

[0310] The present application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a computer, implements the method described in any method embodiment of the present application. The computer program can be a high-level language program or an executable target program.

[0311] The computer-readable storage medium may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. The non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct rambus RAM (DR RAM).

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

[0313] In the several embodiments provided in this application, the disclosed systems, devices and methods can be implemented in other ways. For example, some features of the method embodiments described above can be ignored or not executed. The device embodiments described above are merely schematic, and the division of units is only a logical function division. There may be other division methods in actual implementation, and multiple units or components may be combined or integrated into another system. In addition, the coupling between the units or the coupling between the components may be direct coupling or indirect coupling, and the above coupling includes electrical, mechanical or other forms of connection.

[0314] It should be understood that in the various embodiments of the present application, the size of the serial number of each process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0315] Additionally, the terms "system" and "network" are often used interchangeably. The term "and / or" in this document simply describes a relationship between related objects, indicating that three possible relationships exist. For example, "A and / or B" can mean: A exists alone, A and B exist simultaneously, or B exists alone. Furthermore, the character " / " in this document generally indicates an "or" relationship between the related objects.

[0316] In short, the above description is only a preferred embodiment of the technical solution of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of this application shall be included in the scope of protection of this application.

Claims

1. A video processing method, characterized in that: include: In response to a first operation of the user, displaying a first interface, wherein the first interface includes a thumbnail of a first photo, and the first photo includes a first portrait; In response to a user clicking on a thumbnail of the first photo, displaying a second interface for displaying a browsing page of the first photo; In response to a second operation of the user on the second interface, displaying a third interface, wherein the third interface includes a first area, and the first area includes a first control; In response to a user clicking on the first control, a playback interface of a first video is displayed; the first video includes the first photo and a second photo, and the second photo includes the first portrait.

2. The method according to claim 1, characterized in that The first interface also includes a thumbnail of a second photo, and the second photo does not include a portrait; and the method further includes: In response to a user clicking on a thumbnail of the second photo, displaying a fourth interface for displaying a browsing page of the second photo; In response to a fourth operation of the user on the fourth interface, a fifth interface is displayed, and the fifth interface does not include the first control.

3. The method according to claim 1 or 2, characterized in that: After displaying the playback interface of the first video, the method further includes: In response to a fifth operation of the user on the playback interface of the first video, a sixth interface is displayed, wherein the sixth interface includes the first area, the first area does not include the first control, and the first area includes a thumbnail of the first video and a playback control; In response to the user clicking the playback control, the playback interface of the first video is displayed.

4. The method according to any one of claims 1 to 3, characterized in that The method further comprises: In response to a sixth operation of the user, displaying a seventh interface, the seventh interface being used to display a moment page of the gallery application, the seventh interface including a second control; In response to the user clicking the second control, an eighth interface is displayed, where the eighth interface is used to display data of a plurality of portraits; In response to a user selecting a second portrait, generating a second video, wherein the second video includes a photo of the second portrait; Display the playback interface of the second video.

5. The method according to any one of claims 1 to 4, characterized in that The first interface also includes a thumbnail of a third photo, and the third photo includes the first portrait; and the method further includes: In response to a user clicking on a thumbnail of the third photo, a ninth interface is displayed, wherein the ninth interface is used to display a browsing page of the third photo; In response to the user's seventh operation on the ninth interface, the tenth interface is displayed, and the fifth interface includes the first area, and the first area includes a thumbnail of the first video and a playback control.

6. The method according to claim 5, characterized in that The first area also includes a third control; the method further includes: In response to a user clicking on the third control, updating the first video; After the update is completed, the playback interface of the updated first video is displayed.

7. The method according to claim 5, characterized in that The method further comprises: In response to the eighth operation of the user, an eleventh interface is displayed, the eleventh interface is used to display the time page of the gallery application, and the eleventh interface includes a second control; In response to the user clicking the second control, a twelfth interface is displayed, wherein the twelfth interface is used to display data of a plurality of portraits; In response to a user selecting the first portrait, generating a third video, wherein the third video is a video that updates the first video; The playback interface of the third video is displayed.

8. The method according to any one of claims 1 to 7, characterized in that The third interface also includes a partial area of ​​the first photo, a second area and / or a third area; the second area is used to display portrait tag information; and the third area is used to display shooting location information of the first photo.

9. The method according to any one of claims 1 to 7, characterized in that The first interface further includes a thumbnail of a fourth photo, the fourth photo includes a second number of portraits, and the second number is greater than a second threshold; the method further includes: In response to a user clicking on a thumbnail of the fourth photo, a thirteenth interface is displayed, wherein the thirteenth interface is used to display a browsing page of the fourth photo; In response to a fourth operation of the user on the thirteenth interface, displaying a fourteenth interface, wherein the fourteenth interface includes the first area, and the first area includes the first control; In response to the user clicking the first control, a fifteenth interface is displayed, the fifteenth interface includes a first window, and the first window is used to prompt the user that the video cannot be generated.

10. The method according to any one of claims 1 to 9, characterized in that The method further comprises: In response to the user clicking the first control, a sixteenth interface is displayed, wherein the sixteenth interface includes a second window, and the second window is used to prompt the user that a video cannot be generated, wherein the number of photos including the first portrait is less than a first threshold.

11. The method according to claim 4, characterized in that The method further comprises: In response to the user selecting the third portrait, the seventeenth interface is displayed, the seventeenth interface includes a third window, and the third window is used to prompt the user that the video cannot be generated; wherein the number of photos including the third portrait is less than a third threshold.

12. The method according to claim 4, characterized in that After displaying the eighth interface, the method further includes: In response to the user selecting a third number of portraits, an eighteenth interface is displayed, the eighteenth interface including a fourth window, the fourth window being used to prompt the user that a video cannot be generated; wherein the third number is greater than a fourth threshold.

13. The method according to any one of claims 1 to 12, characterized in that In the process of generating the first video, the method further includes: A dynamic icon is displayed in the first area, and the dynamic icon indicates that the first video is being generated.

14. The method according to any one of claims 1 to 13, characterized in that Before generating the first video, the method further includes: Based on the first portrait, acquiring a plurality of second photos, each of the second photos including the first portrait; Selecting a first number of second photos from the plurality of second photos according to a principle of uniform time distribution; Selecting a second number of second photos from the first number of second photos according to the timeline from oldest to most recent; The generating the first video comprises: The first video is generated based on the second number of second photos and the first photos.

15. An electronic device, characterized in that: The electronic device comprises a processor and a memory, wherein the processor and the memory are coupled, and the memory is used to store a computer program. When the computer program is executed by the processor, the electronic device executes the method according to any one of claims 1 to 14.

16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the electronic device executes the method according to any one of claims 1 to 14.

17. A chip system, characterized in that: The chip system is applied to an electronic device, and the chip system includes one or more processors, and the processor is used to call computer instructions so that the electronic device executes the method as described in any one of claims 1 to 14.