Wallpaper editing method, electronic device, storage medium, and program product
By providing a wallpaper editing interface and multiple editing mode switching functions in electronic devices, the problem of limited wallpaper changing methods is solved, realizing the flexibility and convenience of wallpaper editing, simplifying user operation and improving editing efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HONOR DEVICE CO LTD
- Filing Date
- 2024-12-23
- Publication Date
- 2026-06-26
AI Technical Summary
In existing technologies, the methods for changing wallpapers on electronic devices are limited, making it difficult for users to freely select and edit the wallpaper's editing state, resulting in insufficient flexibility.
This paper provides a wallpaper editing method that displays a wallpaper editing interface, supports multiple target processing and editing mode switching, including layer type selection and editing, supports various layer editing operations such as image expansion and stylization, and manages editing data through cache area and storage area to achieve flexible wallpaper editing and fast rollback.
It improves the flexibility and convenience of wallpaper editing, allowing users to freely switch and select wallpapers in edit mode, simplifying the wallpaper editing process, saving processing resources, and increasing editing speed.
Smart Images

Figure CN122284885A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of terminal technology, and in particular to a wallpaper editing method, electronic device, storage medium, and program product. Background Technology
[0002] With the continuous development of terminal technology, electronic devices such as mobile phones and tablets are becoming increasingly popular, bringing great convenience to people's daily lives. Users can set wallpapers for the lock screen of their electronic devices to enhance their aesthetics. However, currently, changing the wallpaper on an electronic device often requires users to select an image from the device's preset pictures or their gallery, resulting in a limited wallpaper setting method. Summary of the Invention
[0003] This application provides a wallpaper editing method, electronic device, storage medium, and program product, which can improve the flexibility of wallpaper editing. The technical solution is as follows:
[0004] Firstly, a wallpaper editing method is provided, in which an electronic device displays a wallpaper editing interface, which includes a lock screen wallpaper page. In response to a user operation received at the wallpaper editing interface, multiple target processes are performed on the wallpaper of the lock screen wallpaper page, each target process corresponding to a different editing state; wherein, for each pair of wallpapers on the lock screen wallpaper page, one target process is performed, and the wallpaper obtained after that target process is displayed on the lock screen wallpaper page, the wallpaper obtained after that target process being the wallpaper of the editing state corresponding to that target process. In response to a user operation received at the wallpaper editing interface, the lock screen wallpaper page is reverted from the current editing state wallpaper to displaying the wallpaper of the previous editing state.
[0005] In this application, the electronic device can perform various target processing on the lock screen wallpaper page based on user operations during the wallpaper editing process to obtain and display wallpapers in multiple editing states. Furthermore, the electronic device can, based on user operations during the wallpaper editing process, revert the lock screen wallpaper page from the current editing state to display the wallpaper from the previous editing state. This allows users to freely switch between different editing states of the lock screen wallpaper page and select their desired wallpaper, thus improving the flexibility of wallpaper editing.
[0006] As another example, the operation of displaying the wallpaper editing interface on an electronic device can be as follows: receiving a first gesture operation on the lock screen, and displaying the wallpaper editing interface in response to the first gesture operation.
[0007] In this application, users can quickly enter the wallpaper editing interface from the lock screen using a first gesture to edit the wallpaper, thereby improving the convenience of wallpaper editing.
[0008] As an example, the operation of displaying a wallpaper editing interface on an electronic device can be as follows: receiving a second gesture on the desktop; in response to the second gesture, displaying a desktop editing interface, which includes a third control; and in response to an operation performed on the third control, displaying the wallpaper editing interface.
[0009] In this application, users can quickly access the wallpaper editing interface from the desktop to edit the wallpaper, thereby improving the convenience of wallpaper editing.
[0010] In some possible implementations, in response to an operation on a first control in the wallpaper editing interface, the electronic device displays multiple wallpaper template options, including a first wallpaper template option; in response to an operation on the first wallpaper template option, the wallpaper template corresponding to the first wallpaper template option is displayed on the lock screen wallpaper page.
[0011] The first wallpaper template option can be any one of the multiple wallpaper template options. The wallpaper template corresponding to the first wallpaper template option includes multiple layers, which include various types of layers.
[0012] Optionally, the multiple layers include an original layer, and the multiple layers also include one or more of a decoration layer, a color background layer, a clock layer, and a cutout layer; the image of the original layer is the main image, the image of the decoration layer is used to create a decorative effect on the main image, the image of the color background layer is a solid color image or a gradient color image, the clock layer is used to display the time, and the image of the cutout layer contains the foreground object in the main image. The layer types of the original layer, decoration layer, color background layer, clock layer, and cutout layer are all different.
[0013] Optionally, the wallpaper template file of the wallpaper template includes layer set information, which includes the basic layer information of each of the multiple layers, and the basic layer information of the multiple layers is organized in hierarchical order in the layer set information.
[0014] Optionally, the wallpaper template file may also include one or more of the following: offset information, scaling information, blur information, and depth-of-field effect on / off status information.
[0015] In some possible implementations, in response to an operation performed on the first wallpaper template option, the electronic device may also save the wallpaper template file corresponding to the first wallpaper template option as a lock screen wallpaper file in memory.
[0016] In some possible implementations, in response to a basic operation on any one of the multiple layers of the wallpaper on the lock screen wallpaper page, the electronic device can update the lock screen wallpaper file being edited in the current editing state.
[0017] This basic operation can be a selection of color options, a selection of shape options, an on / off switch for the depth-of-field effect, a trigger operation for a control to adjust blur, or a zoom or move operation on the lock screen wallpaper page.
[0018] This application provides wallpaper templates with multiple layers. Users can select from these templates via the wallpaper editing interface and edit them to create lock screen wallpapers that meet their individual needs, thus improving the flexibility of wallpaper editing.
[0019] Optionally, the multiple target processing may include at least two of the following: initial processing, engineered image expansion processing, AI image expansion processing, and AI stylization processing.
[0020] In one scenario, the initial processing can be any other processing performed on the lock screen wallpaper before it has undergone engineering image expansion, AI image expansion, or AI stylization. For example, the initial processing could be basic operations or image replacement operations performed on the lock screen wallpaper before these processes. In another scenario, the initial processing can be basic operations performed after the lock screen wallpaper has been replaced.
[0021] The editing state corresponding to initial processing is the initial editing state, the editing state corresponding to engineering-based image expansion processing is the engineering-based image expansion editing state, the editing state corresponding to AI image expansion processing is the AI-based image expansion editing state, and the editing state corresponding to AI stylization processing is the AI-style editing state.
[0022] In some possible implementations, the electronic device performs a target processing on each pair of wallpapers on the lock screen wallpaper page. The operation of displaying the wallpaper obtained after the target processing on the lock screen wallpaper page can be as follows: While currently in a first editing state, a first user operation is received in the wallpaper editing interface. The first user operation instructs the execution of target processing corresponding to a second editing state. In response to the first user operation, the lock screen wallpaper data of the first editing state is stored in a first cache area. The lock screen wallpaper data of the first editing state includes state data and image data. The state data includes a wallpaper editing record and the lock screen wallpaper file edited in the first editing state. The wallpaper editing record indicates the editing state generated during this editing process. The image data includes the main image generated in the first editing state. The main image corresponding to the lock screen wallpaper data of the first editing state is obtained. The main image corresponding to the lock screen wallpaper data of the first editing state is subjected to target processing corresponding to the second editing state to obtain the main image of the second editing state. A target operation record is generated to record the main image of the second editing state. Based on the target operation record and the lock screen wallpaper file, the wallpaper is displayed on the lock screen wallpaper page.
[0023] The first user action can be used to instruct on engineering-based map expansion, AI-based map expansion, or AI-based stylization.
[0024] For example, the first editing state can be any one of the following: initial editing state, engineered map expansion editing state, AI map expansion editing state, and AI style editing state; the second editing state can be any other editing state besides the first editing state.
[0025] In this application, when switching from the first editing state to the second editing state, the lock screen wallpaper data of the first editing state can be stored in the first cache area so that the editing state can be rolled back or forward in the future.
[0026] Optionally, the operation of the electronic device storing the lock screen wallpaper data in the first edit state to the first cache area can be: storing the lock screen wallpaper data in the first edit state to the first cache area and the second cache area, where the first cache area is a cache area in memory and the second cache area is a cache area in the target memory.
[0027] In this case, in response to the operation of the second control in the wallpaper editing interface, the electronic device can store the lock screen wallpaper data of the current editing state into the target storage area in the target memory, and move the lock screen wallpaper data of each editing state before the current editing state from the second cache area to the target storage area.
[0028] Since both the second cache area and the target storage area are located in the target memory, the lock screen wallpaper data of each editing state before the current editing state can be moved from the second cache area in the target memory to the target storage area. Compared with the operation of storing data in memory to the target storage area, the operation of moving data from the second cache area to the target storage area can save processing resources and improve processing speed.
[0029] In this application, after the wallpaper is edited, the target storage area stores lock screen wallpaper data of various edit states generated during the editing process. Subsequently, based on the lock screen wallpaper data stored in the target storage area, the wallpaper can be rolled back or forwarded in the next editing process.
[0030] In some possible implementations, the first user operation is used to instruct the engineering expansion processing. In this case, the electronic device performs a target processing on the wallpaper of the lock screen wallpaper page for each pair of wallpapers. The operation of displaying the wallpaper obtained after the target processing on the lock screen wallpaper page can be as follows: receiving a third gesture operation on the lock screen wallpaper page while currently in the initial editing state; responding to the third gesture operation, storing the lock screen wallpaper data of the initial editing state in a first cache area, the lock screen wallpaper data of the initial editing state including initial state data and initial image data; the initial state data including wallpaper editing records and the lock screen wallpaper file edited in the initial editing state; the wallpaper editing records are used to indicate that the editing states generated in this editing process are, in sequence: initial editing state; obtaining a first target image, the first target image being the main image corresponding to the lock screen wallpaper data of the initial editing state; performing engineering expansion processing on the first target image to obtain a first expanded image; generating a second operation record, the second operation record being used to record the main image of the engineering expansion editing state, the main image of the engineering expansion editing state being the first expanded image; and displaying the wallpaper on the lock screen wallpaper page according to the second operation record and the lock screen wallpaper file.
[0031] Optionally, after displaying the wallpaper on the lock screen wallpaper page based on the second operation record and the lock screen wallpaper file, the electronic device can also display an AI image expansion control in the wallpaper editing interface, with the AI image expansion control in an unselected state.
[0032] In some possible implementations, the first user operation is used to instruct the AI image expansion processing. In this case, the electronic device performs a target processing on each pair of wallpapers on the lock screen wallpaper page, and the operation of displaying the wallpaper obtained after the target processing on the lock screen wallpaper page can be: receiving a click operation on the AI image expansion control in the wallpaper editing interface; in response to the click operation on the AI image expansion control, storing the lock screen wallpaper data in the engineered image expansion editing state in the first cache area, the engineered image expansion editing state lock screen wallpaper data including engineered image expansion state data and engineered image expansion image data; the engineered image expansion state data includes wallpaper editing records and the lock screen wallpaper file edited in the engineered image expansion editing state; the wallpaper editing... The editing record indicates the editing states generated during this editing process in the following order: initial editing state, engineering expansion editing state; the engineering expansion image data includes the main image in the second operation record; the second target image is obtained, which is the main image in the engineering expansion image data; AI expansion processing is performed on the second target image to obtain the second expansion image; a third operation record is generated, which records the main image of the AI expansion editing state, which is the second expansion image; based on the third operation record and the lock screen wallpaper file, the wallpaper is displayed on the lock screen wallpaper page.
[0033] Optionally, based on the third operation record and the lock screen wallpaper file, after displaying the wallpaper on the lock screen wallpaper page, the electronic device can also display the AI expansion control as selected.
[0034] In some possible implementations, the first user action is used to instruct the AI stylization process to be performed. In this case, the electronic device performs a target processing on each pair of wallpapers on the lock screen wallpaper page. The operation of displaying the wallpaper obtained after the target processing on the lock screen wallpaper page can be: receiving a click operation on the AI style control in the wallpaper editing interface; in response to the click operation on the AI style control, displaying a sixth pop-up window, the sixth pop-up window including one or more style options and a confirmation generation control; in response to the received selection operation on a style option and the click operation on the confirmation generation control, storing the lock screen wallpaper data in the AI expansion editing state in a first cache area, the lock screen wallpaper data in the AI expansion editing state including AI expansion status data and AI expansion image data; the AI expansion status data includes wallpaper editing records and AI... The lock screen wallpaper file edited in the expanded image editing state; this wallpaper editing record indicates the editing states generated during this editing process in sequence: initial editing state, engineered expanded image editing state, and AI expanded image editing state; the AI expanded image data includes the main image in the third operation record; obtain the third target image, which is the main image in the AI expanded image data; perform AI stylization processing on the third target image according to the selected style option to obtain an AI style image; generate the fourth operation record, which is used to record the main image of the AI style editing state, which is the AI style image; display the wallpaper on the lock screen wallpaper page according to the fourth operation record and the lock screen wallpaper file.
[0035] In some possible implementations, the operation of reverting the lock screen wallpaper page from the current editing state to displaying the wallpaper of the previous editing state in response to a user operation received in the wallpaper editing interface can be as follows: receiving a second user operation in the wallpaper editing interface, the second user operation being used to indicate cancellation of the target processing corresponding to the third editing state; in response to the second user operation, determining a fourth editing state based on the wallpaper editing record, the fourth editing state being the previous editing state of the third editing state; obtaining the lock screen wallpaper data of the fourth editing state from a first cache area; and displaying the wallpaper on the lock screen wallpaper page based on the lock screen wallpaper data of the fourth editing state.
[0036] For example, the third editing state can be any one of the engineering-based map expansion editing state, AI map expansion editing state, or AI-style editing state, and the fourth editing state can be any other editing state besides the third editing state.
[0037] For example, the second user action can be used to instruct the cancellation of engineered map expansion processing, AI map expansion processing, or AI stylization processing.
[0038] In this application, the lock screen wallpaper page can be rolled back from the third editing state wallpaper to the fourth editing state wallpaper based on the wallpaper editing record and the lock screen wallpaper data of each editing state stored in the first cache area. The processing time is short and the flexibility of wallpaper editing can be improved.
[0039] In some possible implementations, after displaying the wallpaper on the lock screen wallpaper page based on the lock screen wallpaper data of the fourth editing state, the electronic device can also receive a third user operation on the wallpaper editing interface while currently in the fourth editing state. The third user operation is used to instruct the target processing corresponding to the third editing state. In response to the third user operation, if it is determined from the wallpaper editing record that the third editing state is the next editing state after the fourth editing state, the lock screen wallpaper data of the third editing state is obtained from the first cache area. Based on the lock screen wallpaper data of the third editing state, the wallpaper is displayed on the lock screen wallpaper page.
[0040] In this application, the lock screen wallpaper page can be moved from the fourth editing state to the third editing state based on the wallpaper editing record and the lock screen wallpaper data of each editing state stored in the first cache area. The processing time is short and the flexibility of wallpaper editing can be improved.
[0041] In some possible implementations, in response to an operation performed on a second control in the wallpaper editing interface, the electronic device can set the wallpaper currently displayed on the lock screen wallpaper page as the lock screen wallpaper.
[0042] As an example, in response to an operation on a second control in the wallpaper editing interface, an electronic device can store the lock screen wallpaper file being edited in the current editing state to the file system, and store the lock screen wallpaper data of each editing state generated during the current editing process to the target storage area, so that the wallpaper can be rolled back or forwarded the next time the wallpaper is edited.
[0043] In some possible implementations, in response to a fourth user operation, the electronic device retrieves a lock screen wallpaper file from the file system; displays the wallpaper on the lock screen wallpaper page in the wallpaper editing interface based on the lock screen wallpaper file; retrieves a target wallpaper editing record from a target storage area, the target wallpaper editing record being the wallpaper editing record of the previous editing process; receives a fifth user operation in the wallpaper editing interface, the fifth user operation being used to indicate cancellation of the target processing corresponding to the fifth editing state; in response to the fifth user operation, determines a sixth editing state based on the target wallpaper editing record, the sixth editing state being the previous editing state of the fifth editing state; retrieves the lock screen wallpaper data of the sixth editing state from the target storage area; and displays the wallpaper on the lock screen wallpaper page based on the lock screen wallpaper data of the sixth editing state.
[0044] The fourth user action can be a predefined action used to instruct the display of the wallpaper editing interface. For example, the fourth user action could be the first gesture received on the lock screen, or it could be an action performed on a third control in the desktop editing interface.
[0045] For example, the fifth editing state can be any one of the following: engineering-based map expansion editing state, AI-based map expansion editing state, or AI-style editing state; the sixth editing state can be any other editing state besides the fifth editing state.
[0046] This application can realize the function of reverting the wallpaper on the lock screen wallpaper page to the wallpaper generated in the last editing process after re-entering the wallpaper editing interface, based on the target wallpaper editing record and the lock screen wallpaper data of each editing state stored in the target storage area, thereby improving the flexibility of wallpaper editing.
[0047] In some possible implementations, after displaying the wallpaper on the lock screen wallpaper page based on the lock screen wallpaper data of the sixth editing state, the electronic device, while currently in the sixth editing state, receives a sixth user operation on the wallpaper editing interface. The sixth user operation is used to instruct the target processing corresponding to the fifth editing state. In response to the sixth user operation, if the fifth editing state is determined to be the next editing state after the sixth editing state based on the target wallpaper editing record, the lock screen wallpaper data of the fifth editing state is retrieved from the target storage area. Based on the lock screen wallpaper data of the fifth editing state, the wallpaper is displayed on the lock screen wallpaper page.
[0048] This application can realize the function of reverting the wallpaper of the lock screen wallpaper page to the wallpaper generated in the previous editing process after re-entering the wallpaper editing interface, based on the target wallpaper editing record and the lock screen wallpaper data of each editing state stored in the target storage area. Furthermore, after reverting, the wallpaper of the lock screen wallpaper page can be advanced to another wallpaper generated in the previous editing process, thereby improving the flexibility of wallpaper editing.
[0049] Secondly, a wallpaper editing apparatus is provided, which has the function of implementing the wallpaper editing method described in the first aspect. The wallpaper editing apparatus includes at least one module for implementing the wallpaper editing method provided in the first aspect.
[0050] Thirdly, an electronic device is provided, comprising: one or more processors, and a memory; the memory is coupled to the one or more processors, the memory being used to store computer program code, the computer program code including computer instructions, wherein the one or more processors invoke the computer instructions to cause the electronic device to perform the wallpaper editing method provided in the first aspect.
[0051] Fourthly, a chip system is provided for use in an electronic device, the chip system including one or more processors for invoking computer instructions to cause the electronic device to execute the wallpaper editing method provided in the first aspect.
[0052] Fifthly, a computer-readable storage medium is provided, the computer-readable storage medium including instructions that, when executed on an electronic device, cause the electronic device to perform the wallpaper editing method provided in the first aspect.
[0053] In a sixth aspect, a computer program product is provided that, when the computer program product is run on an electronic device, causes the electronic device to execute the wallpaper editing method provided in the first aspect.
[0054] The technical effects achieved by the second, third, fourth, fifth, and sixth aspects mentioned above are similar to those achieved by the corresponding technical means in the first aspect mentioned above, and will not be repeated here. Attached Figure Description
[0055] Figure 1 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application;
[0056] Figure 2 This is a schematic diagram of a multi-layer structure provided in an embodiment of this application;
[0057] Figure 3 This is a schematic diagram of a different type of layer provided in an embodiment of this application;
[0058] Figure 4 This is a schematic diagram of a lock screen wallpaper provided in an embodiment of this application;
[0059] Figure 5 This is a schematic diagram of a wallpaper provided in an embodiment of this application;
[0060] Figure 6 This is a layer hierarchy diagram provided in an embodiment of this application;
[0061] Figure 7 This is a schematic diagram of a wallpaper editing interface provided in an embodiment of this application;
[0062] Figure 8 This is a schematic diagram illustrating the process of entering a wallpaper editing interface according to an embodiment of this application;
[0063] Figure 9 This is a schematic diagram illustrating another process for entering the wallpaper editing interface provided in an embodiment of this application;
[0064] Figure 10This is a schematic diagram illustrating a process for selecting a wallpaper template according to an embodiment of this application;
[0065] Figure 11 This is a schematic diagram illustrating a process for setting a clock according to an embodiment of this application;
[0066] Figure 12 This is a schematic diagram illustrating a process of setting a decorative element according to an embodiment of this application;
[0067] Figure 13 This is a schematic diagram illustrating a process for setting a depth-of-field effect according to an embodiment of this application;
[0068] Figure 14 This is a schematic diagram illustrating a process of changing an image according to an embodiment of this application;
[0069] Figure 15 This is a schematic diagram illustrating an image scaling and movement process provided in an embodiment of this application;
[0070] Figure 16 This is a schematic diagram illustrating an engineering-based map expansion and AI-based map expansion process provided in an embodiment of this application;
[0071] Figure 17 This is a schematic diagram illustrating an AI stylization process provided in an embodiment of this application;
[0072] Figure 18 This is a schematic diagram illustrating an engineering-based image expansion, AI-based image expansion, and the process of canceling AI stylization, as provided in an embodiment of this application.
[0073] Figure 19 This is a schematic diagram illustrating a scenario of processing the main image of a lock screen wallpaper page according to an embodiment of this application;
[0074] Figure 20 This is a schematic diagram illustrating a process for setting a lock screen wallpaper according to an embodiment of this application;
[0075] Figure 21 This is a schematic diagram illustrating a process of re-entering the wallpaper editing interface provided in an embodiment of this application;
[0076] Figure 22 This is a block diagram of a software system for an electronic device provided in an embodiment of this application;
[0077] Figure 23 This is a flowchart of a wallpaper editing method provided in an embodiment of this application;
[0078] Figure 24 This is a schematic diagram of a display area provided in an embodiment of this application;
[0079] Figure 25This is a schematic diagram of a target area provided in an embodiment of this application;
[0080] Figure 26 This is a flowchart of another wallpaper editing method provided in an embodiment of this application;
[0081] Figure 27 This is a schematic diagram of a JSON file provided in an embodiment of this application;
[0082] Figure 28 This is a flowchart illustrating how to obtain display information of a layer, as provided in an embodiment of this application.
[0083] Figure 29 This is a flowchart illustrating how to obtain the view identifier, layer, clock setting information, or full-screen image of a layer, as provided in an embodiment of this application.
[0084] Figure 30 This is a schematic diagram of another target area provided in an embodiment of this application;
[0085] Figure 31 This is a flowchart of another wallpaper editing method provided in an embodiment of this application;
[0086] Figure 32 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0087] Figure 33 This is a flowchart of another wallpaper editing method provided in an embodiment of this application;
[0088] Figure 34 This is a flowchart of another wallpaper editing method provided in an embodiment of this application;
[0089] Figure 35 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0090] Figure 36 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0091] Figure 37 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0092] Figure 38 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0093] Figure 39 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0094] Figure 40 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0095] Figure 41 This is a schematic diagram illustrating various editing states involved in the wallpaper editing process provided in an embodiment of this application;
[0096] Figure 42 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0097] Figure 43 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0098] Figure 44 This is a schematic diagram of another display area provided in an embodiment of this application;
[0099] Figure 45 This is a flowchart of another wallpaper editing method provided in the embodiments of this application;
[0100] Figure 46 This is a flowchart of another wallpaper editing method provided in the embodiments of this application. Detailed Implementation
[0101] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details.
[0102] It should be understood that, when used in this specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements, and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components, and / or collections thereof. The terms "comprising," "including," "having," and variations thereof all mean "including but not limited to," unless otherwise specifically emphasized.
[0103] It should be understood that "one or more" as mentioned in this application refers to one, two, or more, and "multiple" as mentioned in this application refers to two or more. In the description of this application, unless otherwise stated, " / " means "or," for example, A / B can mean A or B. The "and / or" in this document is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone.
[0104] To facilitate a clear description of the technical solutions of this application, the terms "first" and "second" are used to distinguish identical or similar items with essentially the same function and effect. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order, and that the terms "first" and "second" do not necessarily imply that they are different.
[0105] The terms "one embodiment" or "some embodiments" used in this application mean that one or more embodiments of this application include the specific features, structures, or characteristics described in that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this application do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized.
[0106] The wallpaper editing method provided in this application can be applied to electronic devices. For example, the electronic device may be a mobile phone, tablet computer, wearable device, digital camera, in-vehicle device, augmented reality (AR) device, virtual reality (VR) device, laptop computer, ultra-mobile personal computer (UMPC), netbook, personal digital assistant (PDA), laptop, etc., but this application does not limit the scope of the application.
[0107] Figure 1 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. See also... Figure 1The 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, a headphone jack 170D, a sensor module 180, buttons 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, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer 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.
[0108] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0109] Processor 110 may include one or more processing units, such as application processors (APs), modem processors, graphics processing units (GPUs), image signal processors (ISPs), controllers, memory, video codecs, digital signal processors (DSPs), baseband processors, and / or neural network processing units (NPUs). These different processing units may be independent devices or integrated into one or more processors.
[0110] The controller can be the nerve center and command center of the electronic device 100. The controller can generate operation control signals according to the instruction opcode and timing signals to complete the control of fetching and executing instructions.
[0111] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from this memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves system efficiency.
[0112] The external storage interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external storage interface 120 to perform data storage functions, such as saving music, video, and other files on the external memory card.
[0113] Internal memory 121 can be used to store computer-executable program code, which includes instructions. Processor 110 executes various functional applications and data processing of electronic device 100 by running the instructions stored in internal memory 121. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created by electronic device 100 during use (such as audio data, phonebook, etc.). Furthermore, internal memory 121 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.
[0114] The wireless communication function of electronic device 100 can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor, and baseband processor.
[0115] Electronic device 100 can implement audio functions, such as music playback and recording, through audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D and application processor.
[0116] Electronic device 100 can perform shooting functions through ISP, camera 193, video codec, GPU, display screen 194 and application processor.
[0117] Electronic device 100 can realize display function through GPU, display screen 194 and application processor.
[0118] The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU performs mathematical and geometric calculations and is used for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information. The display screen 194 is used to display images, videos, etc.
[0119] Touch sensor 180K, also known as a "touch panel," can be located on display screen 194. The touch sensor 180K and display screen 194 together form a touchscreen, also known as a "touch display." Touch sensor 180K detects touch operations applied to or near it. Touch sensor 180K can transmit the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through display screen 194. In other embodiments, touch sensor 180K may also be located on the surface of electronic device 100, in a different position than display screen 194.
[0120] This application does not specifically limit the structure of the execution subject of the wallpaper editing method. As long as the code containing the wallpaper editing method provided in this application is run, the wallpaper editing method can be processed according to the wallpaper editing method provided in this application. For example, the execution subject of the wallpaper editing method provided in this application can be a functional module in an electronic device that can call and execute a program, or it can be a processing device applied in an electronic device, such as a chip.
[0121] The wallpapers involved in the wallpaper editing method provided in the embodiments of this application will be described next.
[0122] The wallpaper in this embodiment may include multiple layers. The layers described in this embodiment may be views obtained by drawing layer content (including but not limited to images, time, etc.) in a blank view.
[0123] These multiple layers have a hierarchical relationship, which refers to their position on the top or bottom layer when displayed. That is, when one layer is at a higher level than another, it is positioned above the first layer. Generally, a higher-level layer will partially or completely obscure the lower-level layer when displayed.
[0124] Figure 2 This is a schematic diagram of multiple layers provided in an embodiment of this application. These multiple layers can be divided into various types.
[0125] For example, such as Figure 2 As shown, these multiple layers can include five types of layers: original layer, color background layer, decoration layer, clock layer, and cutout layer.
[0126] Generally, the original layer is at the bottom. The color background layer is below the decoration layer, clock layer, and cutout layer. The decoration layer's layer level can be below the clock layer and cutout layer in some cases, and above them in others. The clock layer's layer level can be below the cutout layer in some cases, and above it in others.
[0127] The image in the original layer can be called the main image. For example, the main image could be an image selected by the user, such as one chosen from the user's gallery, one selected from preset images on the user's electronic device, or an image from the original layer included in one of several preset wallpaper templates. Alternatively, the main image could be an image obtained by specifically processing the user-selected image, such as an image obtained by enlarging or stylizing the user-selected image using artificial intelligence (AI). For example, the original layer could be... Figure 3 The layer shown in (a) is shown in the image.
[0128] The image with a color background layer is an image that has a certain color overall. For example, the color of this image can be a solid color or a gradient. For example, this color background layer can be... Figure 3 The layer shown in (b) has a solid color background.
[0129] The decorative layer image is an image that can decorate the main image. For example, the image can be an image with a frame effect, an image containing text, an image with a certain texture, or an image with a mask effect, etc., and this application embodiment does not limit this. For example, the decorative layer can be... Figure 3 The layer shown in (c) or (d) is shown in the image. Figure 3 The decorative layer shown in (c) is... Figure 3 When the decorative layer shown in (d) is overlaid, it can create a picture frame effect.
[0130] The clock layer is a layer used to display the time, which can be the system time of an electronic device. For example, this clock layer could be... Figure 3 The layer shown in (e) is a clock layer that displays the time.
[0131] The image to be cut out can be obtained from the image of the original layer. For example, the image to be cut out can be an image of the foreground object in the image of the original layer. In some embodiments, the foreground object can be extracted from the image of the original layer based on object information and edge information. For example, in the original layer... Figure 3 In the case of layer (a) shown in the figure, the cutout layer can be Figure 3 The layer shown in (f) contains the foreground object from the original layer.
[0132] In practical applications, Figure 2 The layer hierarchy shown is not unique and can be changed according to the actual situation, or the layers can be deployed according to the wallpaper editing function of the electronic device. Furthermore, in practical applications, the layer types are not limited to... Figure 2 The five types shown can be customized to other types as needed.
[0133] The wallpaper in this embodiment may include one or more types of layers. Furthermore, in some cases, the wallpaper in this embodiment may include one or more layers of the same type; for example, it may include one or more original layers, and / or one or more color background layers, and / or one or more decorative layers, and / or one or more clock layers, and / or one or more cutout layers.
[0134] For example, desktop wallpaper and lock screen wallpaper can be set on electronic devices.
[0135] Desktop wallpaper is the wallpaper displayed on the desktop of an electronic device. For example, such as... Figure 9 As shown in (a), the desktop 900 of the electronic device can display a desktop wallpaper.
[0136] A lock screen wallpaper is the wallpaper displayed on the lock screen of an electronic device. The lock screen is the interface displayed when the electronic device is locked. For example, as shown... Figure 8 As shown in (a), the lock screen interface 800 of the electronic device can display a lock screen wallpaper.
[0137] In some situations, users need to unlock their electronic devices when the screen is locked before the device can display the home screen. For example, when a user... Figure 8 After the lock screen interface 800 shown in (a) performs the unlock operation, the electronic device can display... Figure 9 Desktop 900 is shown in (a) of the image.
[0138] For example, desktop wallpapers may include the original layer.
[0139] For example, the lock screen wallpaper, from bottom to top, can include: the original layer, the clock layer, etc. For instance, the lock screen wallpaper could be... Figure 4 The wallpaper shown in (a) includes... Figure 3 The original layer shown in (a) and Figure 3 The clock layer is shown in (e).
[0140] Alternatively, the lock screen wallpaper can include, from bottom to top, the following layers: the original layer, the color background layer, the clock layer, and the cutout layer. For example, the lock screen wallpaper could be... Figure 4 The wallpaper shown in (b) includes Figure 3 The original layer shown in (a) is... Figure 3 The color background layer shown in (b) is... Figure 3 The clock layer shown in (e) is... Figure 3 The cutout layer is shown in (f) in the image.
[0141] Alternatively, the lock screen wallpaper can include, from bottom to top, the following layers: original layer, decoration layer 1, clock layer, and decoration layer 2. For example, the lock screen wallpaper could be... Figure 4 The wallpaper shown in (c) includes... Figure 3 The original layer shown in (a) is... Figure 3 The decorative layer shown in (c) is Figure 3 The clock layer shown in (e) is... Figure 3 The decorative layer shown in (d) is shown in the image.
[0142] Alternatively, the lock screen wallpaper can include, from bottom to top, the following layers: original layer, decoration layer 1, clock layer, cutout layer, and decoration layer 2. For example, the lock screen wallpaper could be... Figure 4 The wallpaper shown in (d) includes... Figure 3 The original layer shown in (a) is... Figure 3 The decorative layer shown in (c) is Figure 3 The clock layer shown in (e) is... Figure 3 The cutout layer shown in (f) is... Figure 3 The decorative layer shown in (d) is shown in the image.
[0143] Compared to Figure 4 The wallpaper shown in (c) is... Figure 4 The wallpaper shown in (d) can create a sense of depth through the interaction of the original layer, the decorative layer, the clock layer, and the cutout layer. In this embodiment, this effect is referred to as the depth-of-field effect.
[0144] Of course, in addition to the examples above, various types of layers can be flexibly combined in other ways to obtain lock screen wallpapers with better visual effects. This application embodiment does not limit this.
[0145] It should be noted that the above text Figure 3 and Figure 4 This is merely an illustrative description of layers and wallpapers and does not constitute a limitation on the embodiments of this application.
[0146] As can be seen from the above, the wallpaper in this embodiment can be obtained by overlaying multiple layers according to their hierarchical relationship. For example, by... Figure 5 By processing the main image shown in (a), we can obtain... Figure 5 The wallpaper shown in (b) can include Figure 6 The seven layers shown in (a) are: original layer, decoration layer 1, decoration layer 2, clock layer, cutout layer, decoration layer 3, and decoration layer 4, with their layer levels from lowest to highest being: 1, 2, 3, 4, 5, 6, and 7. This wallpaper features rich visual elements and can meet the personalized needs of users.
[0147] In some embodiments, such as Figure 6 As shown in (b), the layer has positional information, which can be represented by coordinates (x, y, z). Here, (x, y) represents the center position of the layer. And (z) indicates the layer's hierarchy within all layers of the wallpaper. It can be seen that in... Figure 6 In the seven layers shown, the z-values of the layers increase sequentially from the leftmost layer to the rightmost layer.
[0148] The wallpaper editing function provided in this application embodiment can edit various types of layers included in the wallpaper to achieve wallpaper editing. For example, it can perform operations such as scaling, moving, blurring, font adjustment, shape adjustment, color adjustment, depth of field effect setting, image expansion, and AI stylization on the wallpaper.
[0149] For example, for the original layer, you can scale, move, blur, enlarge, and stylize it with AI; for the color background layer, you can adjust its color; for the decoration layer, you can adjust its shape and color; for the clock layer, you can adjust its font and color; and for the cutout layer, you can set its depth of field effect.
[0150] The wallpaper editing function provided in this application embodiment can be implemented based on the wallpaper editing interface, which will be described below.
[0151] Figure 7 This is a schematic diagram of a wallpaper editing interface provided in an embodiment of this application. See also... Figure 7 The wallpaper editing interface 700 may include function controls, a lock screen wallpaper page 702, and a desktop wallpaper page 703.
[0152] Functional controls may include one or more main functional controls, such as the return control 70, the completion control 71, etc. Functional controls may also include controls for editing wallpapers, which provide various editing functions.
[0153] Lock screen wallpaper page 702 is a page used to preview the edited lock screen wallpaper.
[0154] Desktop wallpaper page 703 is a page used to preview the edited desktop wallpaper. Optionally, desktop wallpaper page 703 can also display thumbnails of the desktop content on top of the desktop wallpaper, thus providing a better preview of the desktop wallpaper's display effect.
[0155] Lock screen wallpaper page 702 and desktop wallpaper page 703 can exist in a paginated format, and the two can be switched by swiping. For example, in Figure 7 The wallpaper editing interface 700 shown in (a) displays a lock screen wallpaper page 702. After the user swipes left in the wallpaper editing interface 700, as shown... Figure 7 As shown in (b) above, the wallpaper editing interface 700 can display the desktop wallpaper page 703. Afterwards, the user... Figure 7 In the wallpaper editing interface shown in (b), after swiping to the right, as shown in (b), the wallpaper appears as follows: Figure 7 As shown in (a), the wallpaper editing interface 700 can display the lock screen wallpaper page 702.
[0156] In some embodiments, Figure 7 When the lock screen wallpaper page 702 is displayed in the wallpaper editing interface 700 shown in (a), the wallpaper editing interface 700 may also display part or all of the desktop wallpaper page 703.
[0157] In some embodiments, Figure 7 When the desktop wallpaper page 703 is displayed in the wallpaper editing interface 700 shown in (b), the wallpaper editing interface 700 can also display part or all of the lock screen wallpaper page 702.
[0158] For example, such as Figure 7 As shown in (a), when the wallpaper editing interface 700 displays the lock screen wallpaper page 702, the wallpaper editing interface 700 can also display one or more of the following related function controls for editing the lock screen wallpaper: clock frame 710, image change control 720, lock screen style control 72, AI style control 73, personalized decoration control 74, depth of field effect control 75, etc. This application embodiment does not limit this.
[0159] For example, such as Figure 7 As shown in (b), when the wallpaper editing interface 700 displays the desktop wallpaper page 703, the wallpaper editing interface 700 can also display one or more of the following functional controls for editing the desktop wallpaper, such as the follow lock screen control 76, color control 77, wallpaper selection control 78, fuzz control 79, etc. This application embodiment does not limit this.
[0160] In some embodiments, such as Figure 7As shown, the wallpaper editing interface 700 may also include a mask 704. For example, the mask 704 may be a blurred mask, which is a mask obtained through blurring. In this case, the function controls, the lock screen wallpaper page 702, and the desktop wallpaper page 703 can all be displayed on top of the mask 704.
[0161] For example, the mask 704 can be obtained by blurring the main image of the lock screen wallpaper displayed on the lock screen wallpaper page 702. Alternatively, the mask 704 can be obtained by blurring the desktop wallpaper displayed on the desktop wallpaper page 703. Of course, the mask 704 can also be obtained in other ways, such as by blurring a preset image, and this embodiment of the application does not limit this.
[0162] In some embodiments, the wallpaper editing interface 700 can be accessed from the lock screen or desktop of the electronic device.
[0163] As an example, such as Figure 8 As shown in (a), when the electronic device displays the lock screen interface 800, the user can perform a first gesture operation on the lock screen interface 800. Figure 8 (Taking the two-finger pinch gesture as an example). In response to the first gesture, the electronic device can display... Figure 8 The wallpaper editing interface 700 shown in (b) displays a lock screen wallpaper page 702 and related functional controls for editing the lock screen wallpaper. In this case, the user can... Figure 8 Use the wallpaper editing interface 700 shown in (b) to edit the lock screen wallpaper.
[0164] If users want to edit their desktop wallpaper, they can do so in [the following settings]. Figure 8 In the wallpaper editing interface 700 shown in (b), swipe left, and then... Figure 8 As shown in (c), the wallpaper editing interface 700 can display the desktop wallpaper page 703 and related functional controls for editing the desktop wallpaper. In this case, the user can... Figure 8 Use the wallpaper editing interface 700 shown in (c) to edit your desktop wallpaper.
[0165] As another example, such as Figure 9 As shown in (a), when the electronic device displays desktop 900, the user can perform a second gesture operation on desktop 900. Figure 9 (Taking the two-finger pinch gesture as an example). In response to the second gesture, the electronic device displays... Figure 9The desktop editing interface shown in (b) displays controls for editing the desktop, such as wallpaper controls, card controls, effect switching controls, and desktop settings controls. The user then clicks on the wallpaper control within this interface. In response to this click, the electronic device can display... Figure 9 The wallpaper editing interface 700 shown in (c) displays a desktop wallpaper page 703 and related functional controls for editing the desktop wallpaper. In this case, the user can... Figure 9 Use the wallpaper editing interface 700 shown in (c) to edit your desktop wallpaper.
[0166] If users want to edit the lock screen wallpaper, they can do so in... Figure 9 In the wallpaper editing interface 700 shown in (c), slide to the right, and then... Figure 9 As shown in (d), the wallpaper editing interface 700 can display the lock screen wallpaper page 702 and related function controls for editing the lock screen wallpaper. In this case, the user can... Figure 9 Use the wallpaper editing interface 700 shown in (d) to edit the lock screen wallpaper.
[0167] The following section explains the specific process of editing lock screen wallpapers using the wallpaper editing interface 700.
[0168] This application provides lock screen wallpapers with capabilities such as wallpaper templates, custom clocks, decorative settings, depth-of-field settings, image replacement, image scaling and movement, image enlargement, and AI stylization. These capabilities allow users to create personalized and unique wallpapers.
[0169] As an example, electronic devices display such as Figure 10 After the wallpaper editing interface 700 shown in (a) is completed, the user can click the lock screen style control 72. In response to this click, as shown... Figure 10 As shown in (b), the electronic device can display a pop-up window 7011 on the wallpaper editing interface 700. For example, the electronic device can pop up the pop-up window 7011 from the bottom of the wallpaper editing interface 700. The pop-up window 7011 displays multiple wallpaper template options, and may further display image options from the gallery and some wallpaper image options preset by the electronic device. Assuming the user selects a wallpaper template from these multiple wallpaper templates, in response to the selection of this wallpaper template, as shown... Figure 10 As shown in (c), the electronic device can close the pop-up 7011 and display the wallpaper template on the lock screen wallpaper page 702.
[0170] As an example, electronic devices display such as Figure 11After accessing the wallpaper editing interface 700 shown in (a), the user can click the clock frame 710 in the lock screen wallpaper page 702. In response to this click, as shown... Figure 11 As shown in (b), the electronic device can display a pop-up window 7012 on the wallpaper editing interface 700. For example, the electronic device can pop up the pop-up window 7012 from the bottom of the wallpaper editing interface 700, displaying multiple clock font options and multiple clock color options. Users can adjust the font of the clock in the wallpaper of the lock screen wallpaper page 702 using these clock font options, and adjust the color of the clock in the wallpaper of the lock screen wallpaper page 702 using these clock color options. Assuming the user selects a clock color, in response to the selection of this clock color, as shown... Figure 11 As shown in (c), the electronic device can set the color of the clock in the wallpaper of lock screen wallpaper page 702 to this clock color, so that the user can view the clock display effect. Afterwards, if the user confirms that the clock settings are complete, then as shown... Figure 11 As shown in (c), the user can click the collapse control 712. In response to this click, as... Figure 11 As shown in (d), electronic devices can close pop-up 7012.
[0171] As an example, electronic devices display such as Figure 12 After the wallpaper editing interface 700 shown in (a) is completed, the user can click the personalization control 74. In response to this click, such as... Figure 12 As shown in (b), the electronic device can display a pop-up window 7014 on the wallpaper editing interface 700. For example, the electronic device can pop up the pop-up window 7014 from the bottom of the wallpaper editing interface 700, which displays multiple shape options and multiple color options. Users can use these shape options to adjust the shape of the decorative elements in the wallpaper of the lock screen wallpaper page 702, and use these color options to adjust the color of the decorative elements in the wallpaper of the lock screen wallpaper page 702. Assuming the user selects a color, in response to the selection of that color, as shown... Figure 12 As shown in (c), the electronic device can set the color of the decorative elements in the wallpaper of the lock screen wallpaper page 702 to this color, so that the user can view the display effect of the decorative elements. Afterwards, if the user confirms that the setting of the decorative elements is complete, then as shown... Figure 12 As shown in (c), the user can click the collapse control 714. In response to this click, as... Figure 12 As shown in (d), electronic devices can close pop-up 7014.
[0172] As an example, electronic devices display such as Figure 13 After the wallpaper editing interface 700 shown in (a) is completed, the user can click the depth-of-field effect control 75. In response to this click, as shown... Figure 13 As shown in (b), the electronic device can display a pop-up window 7015 on the wallpaper editing interface 700. For example, the electronic device can pop up the pop-up window 7015 from the bottom of the wallpaper editing interface 700. The pop-up window 7015 displays a depth-of-field effect switch 7151, and may further display a background blur control 7152. Figure 13 (Taking a slider-type control as an example). Users can turn the depth-of-field effect of the lock screen wallpaper page 702 on or off using the depth-of-field effect switch 7151, and adjust the blur of the background portion of the wallpaper on the lock screen wallpaper page 702 using the background blur control 7152. Assuming the user turns off the depth-of-field effect switch 7151, the response to turning off the depth-of-field effect switch 7151 is as follows: Figure 13 As shown in (c), the electronic device can turn off the depth-of-field effect of the wallpaper on lock screen wallpaper page 702. Afterwards, if the user confirms that the depth-of-field setting is complete, then as shown... Figure 13 As shown in (c), the user can click the collapse control 7153. In response to this click, as... Figure 13 As shown in (d), electronic devices can close pop-up 7015.
[0173] It should be noted that, as Figure 13 As shown in (a), with the depth-of-field effect enabled, the cutout layer is placed above the clock layer, so it doesn't obscure the main subject. And as... Figure 13 As shown in (d), with the depth of field effect turned off, the cutout layer is located below the clock layer, which can occlude the main subject.
[0174] As an example, electronic devices display such as Figure 14 After the wallpaper editing interface 700 shown in (a) is completed, the user can click the image change control 720. In response to this click, as shown... Figure 14 As shown in (b), the electronic device can display a pop-up window 7201 on the wallpaper editing interface 700. For example, the electronic device can pop up the pop-up window 7201 from the bottom of the wallpaper editing interface 700, displaying image options from the gallery. Assuming the user selects an image from these images, in response to the selection, as shown... Figure 14 As shown in (c), the electronic device can close the pop-up 7201 and change the main image of the wallpaper on the lock screen wallpaper page 702 to this image.
[0175] As an example, users can zoom in or out on the main image of the wallpaper on lock screen wallpaper page 702, and can also move the position of that main image. For example, as Figure 15 As shown in (a), assuming the user performs a two-finger zoom operation on the lock screen wallpaper page 702, the response to this two-finger zoom operation is as follows: Figure 15As shown in (b), the electronic device can zoom in on the main image of the wallpaper on the lock screen wallpaper page 702. For example, as... Figure 15 As shown in (c), assuming the user performs a two-finger pinch-to-zoom operation on the lock screen wallpaper page 702, the response to this pinch-to-zoom operation is as follows: Figure 15 As shown in (d), electronic devices can reduce the size of the main image of the wallpaper on lock screen wallpaper page 702. For example, as... Figure 15 As shown in (e), assuming the user performs a scroll-down operation on the lock screen wallpaper page 702, the response to this scroll-down operation is as follows: Figure 15 As shown in (f), the electronic device can move the main image of the wallpaper on lock screen wallpaper page 702 downwards. For example, if the user moves the wallpaper upwards on lock screen wallpaper page 702, the electronic device can move the main image of the wallpaper on lock screen wallpaper page 702 upwards in response to the upward movement. Similarly, if the user moves the wallpaper left on lock screen wallpaper page 702, the electronic device can move the main image of the wallpaper on lock screen wallpaper page 702 to the left in response to the left movement. And if the user moves the wallpaper right on lock screen wallpaper page 702, the electronic device can move the main image of the wallpaper on lock screen wallpaper page 702 to the right in response to the right movement. Understandably, the electronic device can move the main image of the wallpaper on lock screen wallpaper page 702 in the corresponding direction based on the direction of the user's movement operation on lock screen wallpaper page 702.
[0176] It should be noted that the two-finger zoom-in operation described above can also be called the two-finger spread operation, and the two-finger zoom-out operation described above can also be called the two-finger pinch operation. The movement operations described above can also be called swipe operations; for example, moving up can also be called swiping up, moving down can also be called swiping down, moving left can also be called swiping left, and moving right can also be called swiping right.
[0177] In some embodiments, if a user shrinks the main image of the wallpaper on the lock screen wallpaper page 702 to its smallest size and then tries to continue shrinking the main image, the image enlargement function will be triggered.
[0178] For example, if the top edge of the main image of the wallpaper on lock screen wallpaper page 702 is at the top edge of lock screen wallpaper page 702 and the bottom edge of the main image is at the bottom edge of lock screen wallpaper page 702, and the user performs a two-finger zoom-out operation on lock screen wallpaper page 702, although the electronic device can no longer zoom out the main image, it can enlarge the main image.
[0179] In some embodiments, if a user moves the main image of the wallpaper on the lock screen wallpaper page 702 to the edge of the main image being at the edge of the lock screen wallpaper page 702, and then attempts to continue moving the main image, the image expansion function will be triggered.
[0180] For example, if the top edge of the main image of the wallpaper on lock screen wallpaper page 702 is at the top edge of lock screen wallpaper page 702, and the user performs a downward operation on lock screen wallpaper page 702, although the electronic device can no longer move the main image down, it can enlarge the main image.
[0181] This image expansion feature is used to extend the content of the main image. It can expand upon the original image while preserving its original content, creating additional content that blends seamlessly with it, thus enhancing the overall image effect.
[0182] For example, the map expansion function may include one or more of the following: engineered map expansion function, AI map expansion function, etc.
[0183] The engineering-based image expansion function and the AI-based image expansion function use different image expansion algorithms. For example, the algorithm used in the engineering-based image expansion function can be set within the electronic device itself, meaning the electronic device can perform the engineering-based image expansion processing. The algorithm used in the AI-based image expansion function can be set within the server, meaning the electronic device and server can work together to perform the AI-based image expansion processing. Generally, the engineering-based image expansion function takes less time, while the AI-based image expansion function produces better image expansion results.
[0184] In some embodiments, if the electronic device has not yet triggered the image expansion function during the current editing process, the AI image expansion control may not be displayed in the wallpaper editing interface 700 initially. In this case, the user can trigger the engineered image expansion processing of the main image of the wallpaper on the lock screen wallpaper page 702 by performing a two-finger zoom-out or movement operation. Afterwards, while the electronic device displays the engineered image expansion processing of the main image on the lock screen wallpaper page 702, it can also display the AI image expansion control in the wallpaper editing interface 700. The user can trigger the AI image expansion processing of the main image through this AI image expansion control. Optionally, the user can also undo the AI image expansion processing of the main image through this AI image expansion control.
[0185] In some embodiments, the electronic device can directly display an AI image enlargement control in the wallpaper editing interface 700. In this case, the user can trigger the engineered image enlargement processing of the main image of the wallpaper on the lock screen wallpaper page 702 by performing a two-finger zoom-out or movement operation on the lock screen wallpaper page 702. The user can also trigger the AI image enlargement processing of the main image of the wallpaper on the lock screen wallpaper page 702 through the AI image enlargement control. Optionally, the user can also undo the AI image enlargement processing of the main image through the AI image enlargement control.
[0186] As an example, electronic devices display such as Figure 16The wallpaper editing interface 700 is shown in (a) above. If the main image of the wallpaper on the lock screen wallpaper page 702 can no longer be reduced in size, and the user performs a two-finger zoom-out operation on the lock screen wallpaper page 702, the electronic device can perform engineered enlargement processing on the main image in response to this two-finger zoom-out operation, such as... Figure 16 As shown in (b), after the electronic device completes the engineering image expansion process, it can display the main image that has undergone the engineering image expansion process on the lock screen wallpaper page 702. Optionally, a first notification message 1001 can also be displayed. The first notification message 1001 is used to indicate that the image expansion process has been completed. For example, the content of the first notification message 1001 can be "Image has been expanded". For example, the first notification message 1001 can be a toast message. Of course, the first notification message 1001 can also be other types of notification messages. This application embodiment does not limit this.
[0187] In some embodiments, if the main image of the wallpaper on the lock screen wallpaper page 702 is an image obtained through engineering enlargement processing, the engineering enlargement function will not be triggered if the user performs a two-finger zoom-out or a move operation on the lock screen wallpaper page 702.
[0188] For example, if the main image of the wallpaper on lock screen wallpaper page 702 is an image obtained through engineering enlargement processing, and the user performs a two-finger zoom-out operation on lock screen wallpaper page 702, the electronic device will not shrink the main image nor trigger the engineering enlargement function. Optionally, the electronic device can display a zoom-out animation corresponding to the main image during the execution of the two-finger zoom-out operation, and when the two-finger zoom-out operation ends, i.e., when the user releases their fingers, the electronic device can display a bounce animation corresponding to the zoom-out animation, so that the user knows that it is no longer possible to perform engineering enlargement on the main image. Here, the zoom-out animation refers to the animation effect that makes the main image smaller, and the bounce animation corresponding to the zoom-out animation refers to the animation effect that restores the main image to its original size. It should be understood that the electronic device only displays the zoom-out animation and the bounce animation here, and does not actually scale the main image.
[0189] For example, if the main image of the wallpaper on lock screen wallpaper page 702 is an image obtained through engineering enlargement processing, and this main image can no longer be moved in a certain direction (hereinafter, moving downwards is taken as an example), if the user performs a downward movement operation on lock screen wallpaper page 702, the electronic device will not move the main image downwards nor trigger the engineering enlargement function. Optionally, the electronic device can display the downward movement effect corresponding to the main image during the execution of the downward movement operation, and when the downward movement operation ends, that is, when the user releases their hand, the electronic device can display the bounce effect corresponding to the downward movement effect, so that the user knows that it is no longer possible to perform engineering enlargement on the main image. Here, the downward movement effect refers to the animation effect that displays the downward movement of the main image, and the bounce effect corresponding to the downward movement effect refers to the animation effect that displays the restoration of the main image to its original position. It should be understood that here the electronic device only displays the downward movement effect and the bounce effect, and does not actually move the main image.
[0190] As an example, electronic devices display such as Figure 16 The wallpaper editing interface 700 shown in (b) displays an AI image expansion control 730. Optionally, the AI image expansion control 730 can be displayed as unselected to indicate to the user that the current main image has not undergone AI image expansion processing. If the user clicks the AI image expansion control 730, in response to the click operation, the electronic device can perform AI image expansion processing on the main image of the wallpaper on the lock screen wallpaper page 702, such as... Figure 16 As shown in (c), during the AI image expansion process, the electronic device can display an AI image expansion animation. This animation shows the position of the original subject image after the AI image expansion and the expanded area, which indicates the position of the expanded image content. Optionally, while displaying the AI image expansion animation, the electronic device can also display a second notification message 1002, which indicates the processing progress of the AI image expansion. For example, the second notification message 1002 can be a toast message; however, it can also be other types of notification messages, which are not limited in this embodiment.
[0191] Optionally, when determining the processing progress of the current AI mapping process, the electronic device can periodically determine the current processing time, divide the current processing time by a first preset duration, obtain the processing progress, and display it in the second prompt message 1002. The first preset duration is the estimated duration required for the AI mapping process. The first preset duration can be set in advance, for example, it can be 15 seconds, 16 seconds, etc., and this embodiment of the application does not limit it.
[0192] In some cases, if the electronic device completes the AI mapping process within the first preset time after starting the AI mapping process, the electronic device can quickly jump the processing progress in the second prompt message 1002 to 100% to prompt the user that the AI mapping process has been completed.
[0193] In other cases, if the electronic device has not completed the AI mapping process after the first preset time period following the start of the current AI mapping process, the electronic device can maintain the processing progress in the second prompt message 1002 at 99% to wait for the AI mapping process to complete. Subsequently, if the electronic device completes the AI mapping process within the second preset time period following the start of the current AI mapping process, the electronic device can jump the processing progress in the second prompt message 1002 to 100% to notify the user that the AI mapping process has been completed. The second preset time period can be preset and can be longer than the first preset time period, such as 20 seconds, 21 seconds, etc. This embodiment of the application does not limit this. If the electronic device fails to complete the AI image expansion process within the second preset time period after starting the current AI image expansion process, the electronic device can interrupt the current AI image expansion process, confirming that the current AI image expansion process has failed. Afterwards, the electronic device may no longer display the second prompt message 1002, but instead display a third prompt message. The third prompt message is used to inform the user that the current AI image expansion process has failed. For example, the content of the third prompt message could be "Generation failed, please click to retry". For instance, the third prompt message could be a toast message; of course, the third prompt message could also be other types of prompt messages, and this embodiment of the application does not limit this.
[0194] As an example, after completing this AI image augmentation process, the electronic device, such as Figure 16 As shown in (d), the main image that has undergone AI image enlargement processing can be displayed on the lock screen wallpaper page 702. Optionally, the electronic device can also display the AI image enlargement control 730 as selected to prompt the user that the current main image has undergone AI image enlargement processing.
[0195] In some embodiments, if the main image of the wallpaper on the lock screen wallpaper page 702 is an image obtained through AI image enlargement processing, the AI image enlargement function will not be triggered if the user performs a two-finger zoom-out or a move operation on the lock screen wallpaper page 702.
[0196] For example, if the main image of the wallpaper on the lock screen wallpaper page 702 is an image obtained through AI image enlargement processing, and the user performs a two-finger zoom-out operation on the lock screen wallpaper page 702, the electronic device will not zoom out the main image or trigger the engineered image enlargement function. Optionally, the electronic device can display the zoom-out animation corresponding to the main image during the execution of the two-finger zoom-out operation, and when the two-finger zoom-out operation ends, that is, when the user releases their fingers, the electronic device can display the bounce animation corresponding to the zoom-out animation.
[0197] For example, if the main image of the wallpaper on the lock screen wallpaper page 702 is an image obtained through AI image expansion processing, and the main image can no longer be moved in a certain direction (hereinafter, moving downwards is taken as an example), if the user performs a downward movement operation on the lock screen wallpaper page 702, the electronic device will not move the main image downwards nor trigger the engineered image expansion function. Optionally, the electronic device can display the downward movement effect corresponding to the main image during the execution of the downward movement operation, and when the downward movement operation ends, that is, when the user releases their hand, the electronic device can display the bounce effect corresponding to the downward movement effect.
[0198] As an example, users can apply AI stylization to the main image of the wallpaper on lock screen wallpaper page 702. AI stylization refers to using AI technology to transform the style of an image, such as converting it into various art styles like anime, three-dimensional (3D), photography, and hand-drawn art, to create a unique visual effect.
[0199] For example, electronic devices display such as Figure 17 After viewing the wallpaper editing interface 700 shown in (a), the user can click the AI style control 73. In response to this click, as shown... Figure 17 As shown in (b), the electronic device can display a pop-up window 7013 on the wallpaper editing interface 700. For example, the electronic device can pop up the pop-up window 7013 from the bottom of the wallpaper editing interface 700. The pop-up window 7013 displays multiple style options and a confirmation control 731. Users can use these style options to change the style of the main image of the wallpaper on the lock screen wallpaper page 702. Figure 17 As shown in (c), assuming the user selects a style option and then clicks the confirmation to generate control 731, in response to the selection and click operations, the electronic device can perform AI stylization processing on the main image according to the style corresponding to this style option. Figure 17As shown in (d), during the AI stylization process, the electronic device can display AI stylization animation (such as the snowflake animation in the figure) to prompt the user that AI stylization is in progress. Optionally, while displaying the AI stylization animation, the electronic device can also display a fourth prompt message 1004, which is used to indicate the processing progress of the current AI stylization process. For example, the fourth prompt message 1004 can be a toast message; however, it can also be other types of prompt messages, and this embodiment does not limit this.
[0200] Optionally, when determining the processing progress of the current AI stylization process, the electronic device can periodically determine the current processing time, divide the current processing time by a third preset duration, obtain the processing progress, and display it in the fourth prompt message 1004. The third preset duration is the estimated duration required for the AI stylization process. The third preset duration can be set in advance, for example, it can be 16 seconds, 17 seconds, etc., and this embodiment does not limit it.
[0201] In some cases, if the electronic device completes the AI stylization process within the third preset time after it begins, the electronic device can quickly jump the processing progress in the fourth prompt message 1004 to 100% to notify the user that the AI stylization process has been completed.
[0202] In other cases, if the electronic device has not completed the AI stylization process after the third preset time period following the start of the current AI stylization process, the electronic device can maintain the processing progress in the fourth prompt message 1004 at 99% to wait for the AI stylization process to complete. Subsequently, if the electronic device completes the AI stylization process within the fourth preset time period following the start of the current AI stylization process, the electronic device can jump the processing progress in the fourth prompt message 1004 to 100% to notify the user that the AI stylization process has been completed. The fourth preset time period can be preset and can be longer than the third preset time period, such as 20 seconds, 21 seconds, etc. This embodiment of the application does not limit this. If the electronic device fails to complete the AI stylization process within the fourth preset time period after initiating the current AI stylization process, the electronic device can interrupt the current AI stylization process, confirming its failure. Afterward, the electronic device can stop displaying the fourth prompt message 1004 and instead display a fifth prompt message. The fifth prompt message is used to inform the user that the AI stylization process has failed. For example, the content of the fifth prompt message could be "Generation failed, please click to retry." For instance, the fifth prompt message could be a toast message; however, it could also be other types of prompt messages, and this embodiment does not limit this.
[0203] As an example, after this AI stylization process, the electronic device, such as Figure 17 As shown in (e), the main image with AI stylization can be displayed on the lock screen wallpaper page 702. Optionally, a regeneration control 733 can also be displayed in the pop-up window 7013. In this case, if the user determines that the generated main image does not meet their needs, they can click the regeneration control 733 to regenerate an image with the selected style. If the user determines that the generated main image meets their needs, they can click the collapse control 735. In response to this click operation, as shown... Figure 17 As shown in (f), the electronic device can close pop-up 7013.
[0204] In some embodiments, the electronic device may perform one or more of the following processing on the main image of the wallpaper on the lock screen wallpaper page 702: engineered image expansion processing, AI image expansion processing, and AI stylization processing.
[0205] For example, such as Figure 16 As shown, the electronic device can first perform engineering-based image enlargement processing on the main image of the wallpaper on lock screen wallpaper page 702, and then perform AI image enlargement processing on it. Afterwards, as... Figure 17 As shown, the main image obtained through AI image enlargement can then undergo AI stylization processing. Afterwards, as... Figure 18As shown, the main image obtained through AI stylization can then undergo engineering-based image enlargement processing, followed by AI image enlargement processing.
[0206] In some embodiments, after the electronic device performs one or more of the following processing on the main image of the wallpaper on the lock screen wallpaper page 702: engineering image expansion processing, AI image expansion processing, and AI stylization processing, it can also adjust one or more of the clock, decorative elements, and depth-of-field effects in the wallpaper on the lock screen wallpaper page 702, and / or perform one or more of the following processing on the main image of the wallpaper on the lock screen wallpaper page 702: scaling, moving, and blurring. The specific process is the same as described above. Figures 11 to 13 Examples and Figure 15 The process described in the embodiments is the same, and will not be repeated in this application. For ease of description, the operations of adjusting the clock, decorations, and depth-of-field effects in the wallpaper, as well as the operations of scaling, moving, and blurring the main image in the wallpaper, will be collectively referred to as basic operations.
[0207] For example, Figure 19 The present invention provides some possible processing scenarios for the main image of the wallpaper on the lock screen wallpaper page 702. Of course, it is not limited to these scenarios. Other possible processing scenarios may exist in actual applications. This application embodiment does not limit these scenarios.
[0208] For example, such as Figure 19 As shown in (a), the main image can be sequentially processed through engineering image expansion, AI image expansion, and AI stylization. For example, as... Figure 19 As shown in (b), the main image can be processed sequentially with engineering image expansion, AI stylization, and AI image expansion. For example, as... Figure 19 As shown in (c), the main image can be processed sequentially with AI image enlargement and AI stylization. For example, as... Figure 19 As shown in (d), the main image can be sequentially processed with AI stylization and AI image enlargement. For example, as... Figure 19 As shown in (e), the main image can be processed sequentially using AI stylization, engineering image expansion, and AI image expansion.
[0209] Optionally, in this embodiment of the application, the main image that has not undergone engineering image expansion processing, AI image expansion processing, or AI stylization processing can be referred to as the source image (OriginBitmap), the main image obtained after engineering image expansion processing can be referred to as the source expanded image (OriginExpandBitmap), the main image obtained after AI image expansion processing can be referred to as the source AI expanded image (OriginAIExpandBitmap), and the main image obtained after AI stylization processing can be referred to as the source AI style image (OriginAIStyleBitmap).
[0210] In this embodiment, one or more editing states exist during wallpaper editing. After entering the wallpaper editing interface 700, if the engineering image expansion function, AI image expansion function, and AI stylization function are not triggered, the user is in the initial editing state. If the engineering image expansion function is triggered, the user enters the engineering image expansion editing state. If the AI image expansion function is triggered, the user enters the AI image expansion editing state. If the AI stylization function is triggered, the user enters the AI style editing state.
[0211] It should be noted that basic operations performed in the initial editing state remain within the initial editing state. Basic operations performed in the engineering-style expansion editing state remain within the engineering-style expansion editing state. Basic operations performed in the AI-style expansion editing state remain within the AI-style expansion editing state.
[0212] During wallpaper editing, basic operations can be performed, as well as one or more of the following: engineered image expansion, AI image expansion, and AI stylization. In other words, one or more editing states can be superimposed during wallpaper editing. In this embodiment, when multiple editing states are superimposed, it supports rewinding and forwarding editing states; that is, the current editing state can be rewound to the previous editing state, or the current editing state can be forwarded to the next editing state. This allows users to freely switch between different editing states, improving the flexibility of wallpaper editing.
[0213] In this embodiment of the application, if the wallpaper of edit state A is generated based on the wallpaper of edit state B, then edit state B can be called the previous edit state of edit state A, and edit state A can be called the next edit state of edit state B.
[0214] For example, suppose the wallpaper on lock screen wallpaper page 702 is wallpaper 1, and wallpaper 1 is in the initial editing state. The electronic device first performs engineering image expansion processing on wallpaper 1 on lock screen wallpaper page 702 to obtain wallpaper 2, and wallpaper 2 is in the engineering image expansion editing state. Then, the electronic device performs AI image expansion processing on wallpaper 2 on lock screen wallpaper page 702 to obtain wallpaper 3, and wallpaper 3 is in the AI image expansion editing state. After that, the electronic device performs AI stylization processing on wallpaper 3 on lock screen wallpaper page 702 to obtain wallpaper 4, and wallpaper 4 is in the AI style editing state.
[0215] In this scenario, the user can revert from wallpaper 4 on lock screen wallpaper page 702 to wallpaper 3, then revert from wallpaper 3 to wallpaper 2, and finally revert from wallpaper 2 to wallpaper 1. Of course, after reverting from wallpaper 4 to wallpaper 3, the user can also choose to move forward from wallpaper 3 to wallpaper 4. Similarly, after reverting from wallpaper 3 to wallpaper 2, the user can choose to move forward from wallpaper 2 to wallpaper 3; and after reverting from wallpaper 2 to wallpaper 1, the user can choose to move forward from wallpaper 1 to wallpaper 2.
[0216] It should be noted that if basic operations are performed in a certain editing state, the wallpaper generated after the latest basic operation in that editing state will be used when going back and forward.
[0217] For example, suppose the wallpaper on lock screen wallpaper page 702 is wallpaper a, and wallpaper a is in the initial editing state. The electronic device first performs AI image expansion processing on wallpaper a on lock screen wallpaper page 702 to obtain wallpaper b, and then adjusts the color of the clock in wallpaper b on lock screen wallpaper page 702 to obtain wallpaper c. Both wallpaper b and wallpaper c are in the engineering expansion editing state. Then the electronic device performs AI stylization processing on wallpaper c on lock screen wallpaper page 702 to obtain wallpaper d, and wallpaper d is in the AI style editing state.
[0218] In this situation, the user can revert from wallpaper d on lock screen wallpaper page 702 to wallpaper c, and then revert from wallpaper c to wallpaper a (instead of reverting to wallpaper b). Of course, after reverting from wallpaper d to wallpaper c, the user can also choose to move forward from wallpaper c to wallpaper d again. Similarly, after reverting from wallpaper c to wallpaper a, the user can also choose to move forward from wallpaper a to wallpaper c again (instead of moving forward to wallpaper b).
[0219] The following is based on Figures 16 to 18Taking the wallpaper editing process shown as an example, the rollback and forward scenarios of the editing state provided in this application embodiment are illustrated by way of example:
[0220] As an example, after a user selects a wallpaper template, the electronic device displays something like this: Figure 16 The wallpaper editing interface 700 shown in (a) is described below. Assuming the wallpaper on the lock screen wallpaper page 702 in the wallpaper editing interface 700 is wallpaper 1, then when the user... Figure 16 In the lock screen wallpaper page 702 shown in (a), after the two-finger zoom-out operation triggers the engineering image expansion function, the electronic device performs engineering image expansion processing on wallpaper 1 to obtain wallpaper 2, and then displays it as shown in the image. Figure 16 The wallpaper editing interface 700 shown in (b) is currently displaying wallpaper 2 on the lock screen wallpaper page 702 in the wallpaper editing interface 700.
[0221] In this case, if the user is Figure 16 When the lock screen wallpaper page 702 shown in (b) is zoomed in with two fingers, the wallpaper on the lock screen wallpaper page 702 can be swung back from wallpaper 2 to wallpaper 1. That is, in response to the two-finger zoom operation, the electronic device will redisplay the wallpaper. Figure 16 Wallpaper 1 is shown in lock screen wallpaper page 702 as shown in (a). In this case, if the user is... Figure 16 If the lock screen wallpaper page 702 shown in (a) performs a two-finger zoom-out operation, the wallpaper on the lock screen wallpaper page 702 can be moved from wallpaper 1 to wallpaper 2. That is, in response to the two-finger zoom-out operation, the electronic device will redisplay the wallpaper. Figure 16 The wallpaper 2 shown in lock screen wallpaper page 702 (b) should be noted that after the electronic device receives the two-finger zoom-out operation, it does not need to repeat the engineering enlargement process for wallpaper 1 and can directly display the previously generated wallpaper 2.
[0222] In some embodiments, the electronic device displays, for example Figure 16 In the wallpaper editing interface 700 shown in (b), the AI image expansion control 730 in the wallpaper editing interface 700 is currently unselected. If the user clicks the AI image expansion control 730, the electronic device can perform AI image expansion processing on wallpaper 2 of the lock screen wallpaper page 702, and, as shown... Figure 16 As shown in (c), the electronic device can display AI map expansion animation during the AI map expansion process. In this case, if the user clicks... Figure 16 If the cancel control 1021 in the second prompt message 1002 shown in (c) is clicked, the electronic device will interrupt the current AI image expansion process and then redisplay the image. Figure 16Wallpaper 2 on the lock screen wallpaper page 702 shown in (b) is displayed. If the user does not click the cancel control 1021 in the second prompt message 1002, then after the electronic device completes this AI image expansion process to obtain wallpaper 3, it can be displayed. Figure 16 The wallpaper editing interface 700 shown in (d) is currently displaying wallpaper 3 on the lock screen wallpaper page 702 in the wallpaper editing interface 700, and the AI image expansion control 730 is selected.
[0223] In this case, if the user is Figure 16 Clicking the AI image expansion control 730 in the wallpaper editing interface 700 shown in (d) will revert the wallpaper on the lock screen wallpaper page 702 from wallpaper 3 to wallpaper 2. In other words, in response to this click operation, the electronic device will redisplay the wallpaper. Figure 16 In the lock screen wallpaper page 702 shown in (b), wallpaper 2 is displayed, and the AI image expansion control 730 is shown as unselected. In this case, if the user clicks again... Figure 16 The AI image expansion control 730 shown in (b) can advance the wallpaper of the lock screen wallpaper page 702 from wallpaper 2 to wallpaper 3. That is, in response to this click operation, the electronic device will redisplay the wallpaper. Figure 16 As shown in (d) of the lock screen wallpaper page 702, wallpaper 3, it should be noted that after the electronic device receives this click operation, it does not need to repeat the AI image enlargement processing of wallpaper 2; it can directly display the previously generated wallpaper 3. That is, the electronic device can directly display wallpaper 3 from the lock screen wallpaper page 702. Figure 16 The wallpaper editing interface shown in (b) 700 switches to display. Figure 16 The wallpaper editing interface 700 shown in (d) is displayed without needing to show... Figure 16 The AI-generated image expansion animation shown in (c) is an example.
[0224] In some embodiments, the electronic device displays, for example Figure 16 The wallpaper editing interface 700 shown in (d) is as follows: Figure 17 As shown in (a) to (c), if the user clicks the AI style control 73, and then clicks a style option in the displayed pop-up window 7013 and confirms the generation of control 731, then the electronic device can perform AI stylization processing on the wallpaper 3 of the lock screen wallpaper page 702, and, as shown in (a) to (c), if the user clicks the AI style control 73, and then clicks a style option in the displayed pop-up window 7013 and clicks the confirmation to generate ... Figure 17 As shown in (d), electronic devices can display AI-stylized animation effects during AI image expansion processing. In this case, if the user clicks... Figure 17 As shown in (d) above, the cancel generation control 732 will, in response to the click operation, interrupt the current AI stylization process on the electronic device and then redisplay it. Figure 17 Wallpaper 3 is shown in lock screen wallpaper page 702 as shown in (c). If the user does not click... Figure 17The cancellation control 732 shown in (d) can be displayed after the electronic device completes this AI stylization process and obtains wallpaper 4. Figure 17 The wallpaper editing interface 700 shown in (e) is currently displaying wallpaper 4 on the lock screen wallpaper page 702.
[0225] In this case, if the user is Figure 17 Clicking the style cancellation control 734 in the pop-up window 7013 shown in (e) will revert the wallpaper of the lock screen wallpaper page 702 from wallpaper 4 to wallpaper 3. In other words, in response to this click operation, the electronic device will redisplay the wallpaper. Figure 17 Wallpaper 3 of the lock screen wallpaper page 702 is shown in (b) above. In this case, if the user clicks the same style option again and clicks the confirmation generation control 731, the wallpaper of the lock screen wallpaper page 702 can be moved from wallpaper 3 to wallpaper 4. That is, in response to the click operation, the electronic device will redisplay the wallpaper. Figure 17 As shown in (e) of the lock screen wallpaper page 702, wallpaper 4, it should be noted that after the electronic device receives this click operation, there is no need to repeat the AI stylization processing of wallpaper 3; it can directly display the previously generated wallpaper 4. That is, the electronic device can directly display wallpaper 4 from the lock screen wallpaper page 702. Figure 17 The wallpaper editing interface shown in (c) 700 switches to display. Figure 17 The wallpaper editing interface 700 shown in (e) is displayed without needing to show... Figure 17 The AI-stylized animation shown in (d) is an example.
[0226] In some embodiments, the electronic device displays, for example Figure 17 The wallpaper editing interface 700 shown in (f) is as follows: Figure 18 As shown in (a), if the user performs a scroll-down operation on the lock screen wallpaper page 702 in the wallpaper editing interface 700, then in response to the scroll-down operation, as follows: Figure 18 As shown in (b), the electronic device performs engineering enlargement processing on wallpaper 4 of lock screen wallpaper page 702 to obtain wallpaper 5. At this time, the AI enlargement control 730 is displayed as unselected. Afterwards, if the user clicks the AI enlargement control 730, in response to the click operation, the electronic device can perform AI enlargement processing on wallpaper 5 of lock screen wallpaper page 702, such as... Figure 18 As shown in (c), the electronic device can display AI image expansion animation during the AI image expansion process. After the electronic device performs AI image expansion on wallpaper 5 to obtain wallpaper 6, as shown... Figure 18 As shown in (d) in the figure, it can display Figure 18 The wallpaper editing interface 700 shown in (d) is currently displaying wallpaper 6 on the lock screen wallpaper page 702.
[0227] In this case, if the user clicks Figure 18 The AI-style control 73 shown in (d) responds to the click operation, such as Figure 18 As shown in (e), the electronic device can display pop-up 7013. Then, if the user clicks the style cancellation control 734 in pop-up 7013, the wallpaper on the lock screen wallpaper page 702 can be reverted from wallpaper 6 to the wallpaper before AI stylization, i.e., reverted to... Figure 18 Wallpaper 3, shown in (f), is the option to revert to... Figure 17 Wallpaper 3 shown in (a) is shown in the image. Figure 17 Wallpaper 3 shown in (a) has not yet been stylized using AI.
[0228] After editing the lock screen wallpaper using one or more of the methods described above, if the user determines that the wallpaper on the current lock screen wallpaper page 702 meets their needs, then... Figure 20 As shown in (a), the user can click the completion control 71 in the wallpaper editing interface 700. In response to this click, the electronic device can close the wallpaper editing interface 700, and, as... Figure 20 As shown in (b), the electronic device can set the wallpaper of the lock screen wallpaper page 702 as the lock screen wallpaper of the lock screen interface 800.
[0229] Later, if the user wants to edit the wallpaper again while using the electronic device, then... Figure 21 As shown in (a), the user can perform a first gesture operation on the lock screen 800. Figure 17 (Taking the two-finger pinch gesture as an example). In response to the first gesture, the electronic device can display... Figure 21 The wallpaper editing interface 700 shown in (b) displays a lock screen wallpaper page 702 and related function controls for editing the lock screen wallpaper. At this time, the lock screen wallpaper page 702 displays the lock screen wallpaper that the user previously edited. In this case, the user can continue editing the previously edited lock screen wallpaper.
[0230] For example, it can be done in a similar way Figure 10 You can change the wallpaper template using the lock screen style control 72, or you can do it in a similar way. Figure 11 This method uses the clock frame 710 to reset the clock in the previously edited lock screen wallpaper, or you can follow a similar... Figure 12 The shape and color of the decorative elements in the previously edited lock screen wallpaper can be reset using the personalized decoration control 74, or similarly... Figure 13 This method uses the depth-of-field effect control 75 to change the depth-of-field effect and background blur in the previously edited lock screen wallpaper, or it can be done in a similar way. Figure 14 This method uses the image control 720 to change the main image in the previously edited lock screen wallpaper, or you can follow a similar approach. Figure 15 This can be done by scaling and / or moving the main image in the lock screen wallpaper that was last edited, or you can follow a similar method. Figures 16 to 18 This method involves performing one or more of the following processing techniques on the previously edited lock screen wallpaper: engineering image expansion, AI image expansion, and AI stylization.
[0231] In some embodiments, if the previously edited lock screen wallpaper was obtained through one or more of the following processes: engineered image expansion, AI image expansion, and AI stylization, then multiple editing states were generated during the previous editing of the lock screen wallpaper. In this case, after the user enters the wallpaper editing interface 700 this time, they can also use the relevant controls in the wallpaper editing interface 700 to revert the lock screen wallpaper to a certain editing state among the multiple editing states.
[0232] For example, suppose the user is Figure 17 If the completion control 71 is clicked in the wallpaper editing interface 700 shown in (f), the electronic device can close the wallpaper editing interface 700 in response to the click operation and set wallpaper 4 of the lock screen wallpaper page 702 in the wallpaper editing interface 700 as the lock screen wallpaper. Afterwards, if the user re-enters the wallpaper editing interface 700, the wallpaper displayed on the lock screen wallpaper page 702 in the wallpaper editing interface 700 will be wallpaper 4. In this case, the user can use the relevant controls in the wallpaper editing interface 700 to sequentially revert from wallpaper 4 on the lock screen wallpaper page 702 to wallpaper 3, wallpaper 2, and wallpaper 1. After reverting to a certain wallpaper, the user can also choose to advance back to the corresponding wallpaper. Furthermore, after reverting or advancing to the desired wallpaper, the user can also perform one or more of the following processing methods: basic operations, engineered image expansion processing, AI image expansion processing, and AI stylization processing.
[0233] Based on this, the embodiments of this application can not only continue the previously edited wallpaper during wallpaper editing, but also continue the editing state generated by the previous editing. In this way, the wallpaper can be rolled back to a certain wallpaper generated in the previous editing process during the current editing process, thereby greatly improving the flexibility of wallpaper editing.
[0234] It should be noted that since the wallpaper editing interface 700 includes a lock screen wallpaper page 702 and a desktop wallpaper page 703, after the user clicks the completion control 71 in the wallpaper editing interface 700, the electronic device can set the wallpaper of the current lock screen wallpaper page 702 as the lock screen wallpaper, and at the same time set the wallpaper of the current desktop wallpaper page 703 as the desktop wallpaper.
[0235] Another point to note is that in some embodiments, if the electronic device enters the wallpaper editing interface 700 from the lock screen interface 800, then after the user clicks the completion control 71 in the wallpaper editing interface 700, in response to the click operation, the electronic device can display the lock screen interface 800 and show the edited lock screen wallpaper on the lock screen interface 800. Conversely, if the electronic device enters the wallpaper editing interface 700 from the desktop 900, then after the user clicks the completion control 71 in the wallpaper editing interface 700, in response to the click operation, the electronic device can display the desktop 900 and show the edited desktop wallpaper on the desktop 900.
[0236] In other embodiments, if the user clicks the completion control 71 in the wallpaper editing interface 700 while the lock screen wallpaper page 702 is displayed in the wallpaper editing interface 700, then in response to the click operation, the electronic device can display the lock screen interface 800 and display the edited lock screen wallpaper on the lock screen interface 800. If the user clicks the completion control 71 in the wallpaper editing interface 700 while the desktop wallpaper page 703 is displayed in the wallpaper editing interface 700, then in response to the click operation, the electronic device can display the desktop 900 and display the edited desktop wallpaper on the desktop 900.
[0237] In some other embodiments, after a user clicks the completion control 71 in the wallpaper editing interface 700, in response to the click operation, the electronic device can display the desktop 900 and display the edited desktop wallpaper on the desktop 900.
[0238] It should be noted that after editing the lock screen wallpaper and / or desktop wallpaper through the wallpaper editing interface 700, if the user does not wish to save the edited lock screen wallpaper and / or desktop wallpaper, they can click the return control 70 in the wallpaper editing interface 700. In response to this click, the electronic device will not apply the newly edited lock screen wallpaper and / or desktop wallpaper, but will instead retain the original lock screen wallpaper and desktop wallpaper.
[0239] After understanding the various editing functions in the wallpaper editing method provided in the embodiments of this application, the specific implementation process of these editing functions will be described in detail below.
[0240] The software system involved in the wallpaper editing method provided in the embodiments of this application will be described below.
[0241] The software system of an electronic device can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This application uses the layered architecture of the Android system as an example to illustrate the software system of an electronic device. It should be noted that although this application uses the Android system as an example, its basic principles are equally applicable to electronic devices based on operating systems such as iOS or Windows.
[0242] Figure 22 This is a block diagram of a software system for an electronic device provided in an embodiment of this application. See also... Figure 22 A layered architecture divides software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into an application layer, an application framework layer, the Android runtime, a system layer, and a kernel layer.
[0243] The application layer can include a series of applications. For example... Figure 22 As shown, the application layer can include applications such as camera, calendar, map, music, SMS, call, video, Bluetooth, lock screen, desktop, gallery, etc.
[0244] Both the lock screen app and the desktop app can instruct the gallery app to display the wallpaper editing interface.
[0245] When the gallery application receives an instruction from the lock screen application or the desktop application, it can load the wallpaper editing interface, which includes loading the function controls, the lock screen wallpaper page, and the desktop wallpaper page.
[0246] In some embodiments, the gallery application may include a main function module, a lock screen view module, and a desktop view module. In other embodiments, the main function module, lock screen view module, and desktop view module may not be included in the gallery application, but rather exist as separate applications, such as a standalone wallpaper editing application. The following explanation uses the example of the main function module, lock screen view module, and desktop view module being included in the gallery application.
[0247] The main functional module implements various editing functions during the wallpaper editing process. This module can interact with external systems, such as lock screen applications, desktop applications, and the file system. Furthermore, it can perform parsing tasks related to the wallpaper file during the wallpaper editing process. Additionally, the main functional module can save operation data for each editing action during the wallpaper editing process.
[0248] The lock screen view module is used to display the lock screen wallpaper on the lock screen wallpaper page based on the lock screen wallpaper display information.
[0249] The Desktop View module is used to display the desktop wallpaper on the desktop wallpaper page based on the desktop wallpaper display information.
[0250] The application framework layer provides application programming interfaces (APIs) and a programming framework for applications in the application layer. The application framework layer includes some predefined functions.
[0251] like Figure 22 As shown, the application framework layer may include a first cache management module, a second cache management module, a persistence management module, an engineering graph expansion module, an AI graph expansion module, and an AI stylization module.
[0252] The first cache management module is used to store the generated lock screen wallpaper data in various edit states into the first cache area during the wallpaper editing process. The first cache management module manages the lock screen wallpaper data stored in the first cache area. For example, the first cache area can be a memory cache area.
[0253] The second cache management module is used to store the generated lock screen wallpaper data in various edit states to a second cache area during the wallpaper editing process. The second cache area can be a cache area in the target storage. The second cache management module is used to manage the lock screen wallpaper data stored in the second cache area. For example, the target storage can be non-volatile storage. For instance, the target storage can be a disk, and the second cache area can be a disk cache area.
[0254] The persistence management module stores all lock screen wallpaper data generated during the wallpaper editing process in a target storage area (excluding the second cache area) upon completion of wallpaper editing, thus achieving persistent storage of the lock screen wallpaper data. The persistence management module manages the lock screen wallpaper data stored in the target storage area.
[0255] The engineering-grade image expansion module is used to perform engineering-grade image expansion processing on images.
[0256] The AI image expansion module is used to perform AI image expansion processing on images.
[0257] The AI stylization module is used to perform AI stylization processing on images.
[0258] For example, the engineering mapping module can also be called the engineering mapping pipeline. The AI mapping module can also be called the AI mapping pipeline. The AI stylization module can also be called the AI stylization pipeline.
[0259] The pipeline described in this application refers to a processing procedure in which multiple stages are performed sequentially, each stage is responsible for processing a part of the task, and each stage can process different data in parallel. A typical feature of a pipeline is pipelining, which can improve the operating efficiency of electronic devices.
[0260] For example, a pipeline can include multiple nodes, each representing a processing stage. During data processing, data flows sequentially through the pipeline, being processed one node at a time.
[0261] like Figure 22 As shown, the application framework layer may also include a window manager, content provider, view system, phone manager, resource manager, notification manager, etc.
[0262] The window manager manages windowed applications. It can determine the screen size, the presence of a status bar, screen lock, and screen capture. The content provider stores and retrieves data, making it accessible to applications. This data can include videos, images, audio, incoming and outgoing calls, browsing history and bookmarks, and phone books. The view system includes visual controls, such as controls for displaying text and images. The view system is used to build the application's display interface, which can consist of one or more views, such as a view displaying SMS notification icons, a view displaying text, and a view displaying images. The phone manager provides communication functionality for electronic devices, such as managing call status (including connection and disconnection). The resource manager provides applications with various resources, such as localized strings, icons, images, layout files, and video files. The notification manager allows applications to display notifications in the status bar. These notifications can be used to convey informational messages and can disappear automatically after a short pause without user interaction. For example, the notification manager can be used to notify of download completion or message alerts. The notification manager can also display notifications as icons or scrolling text in the system's top status bar, such as notifications from background applications. The notification manager can also display notifications as dialog boxes on the screen, such as text messages in the status bar, sound alerts, vibrations of electronic devices, and flashing indicator lights.
[0263] The Android Runtime comprises the core libraries and the virtual machine. The Android Runtime is responsible for the scheduling and management of the Android system. The core libraries consist of two parts: one part contains the functionalities that Java calls, and the other part is the core Android library itself. The application layer and application framework layer run in the virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.
[0264] The system layer can include multiple functional modules. For example... Figure 22 As shown, the system layer may include a file system.
[0265] The file system is used to manage lock screen wallpaper files, desktop wallpaper files, and wallpaper template files. For example, lock screen wallpaper files, desktop wallpaper files, and wallpaper template files can be stored in hardware-level memory. The file system can read lock screen wallpaper files, desktop wallpaper files, and wallpaper template files from this memory. The file system can also update the lock screen wallpaper files and desktop wallpaper files in this memory.
[0266] A lock screen wallpaper file can include a first file and a second file. The first file is used when editing the lock screen wallpaper in the wallpaper editing interface; that is, the gallery application can display the lock screen wallpaper on the lock screen wallpaper page based on the first file. The second file is used when displaying the lock screen wallpaper on the lock screen interface; that is, the lock screen application can display the lock screen wallpaper on the lock screen interface based on the second file.
[0267] A desktop wallpaper file can include a first file and a second file. The first file is used when editing the wallpaper in the wallpaper editing interface; that is, the gallery application can display the wallpaper on the wallpaper page based on the first file. The second file is used when displaying the wallpaper on the desktop; that is, the desktop application can display the wallpaper on the desktop based on the second file.
[0268] Wallpaper template files are files that provide users with a selection of wallpaper templates when editing lock screen wallpapers in the wallpaper editing interface. In this case, after the user selects a wallpaper template, the gallery application can display that wallpaper template on the lock screen wallpaper page based on the corresponding wallpaper template file.
[0269] like Figure 22As shown, the system layer may also include a surface manager, media libraries, 3D graphics processing libraries (such as OpenGL ES), and 2D graphics engines (such as SGL).
[0270] The Surface Manager manages the display subsystem and provides fusion of two-dimensional (2D) and three-dimensional (3D) layers for multiple applications. The Media Library supports playback and recording of various common audio and video formats, as well as still image files. It supports multiple audio and video coding formats, such as: Moving Picture Experts Group (MPEG) 4, H.264 (also known as Advanced Video Coding, AVC), 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). The 3D graphics processing library implements 3D graphics drawing, image rendering, compositing, and layer processing. The 2D graphics engine is the drawing engine for 2D graphics.
[0271] The kernel layer is the layer between hardware and software. For example... Figure 22 As shown, the kernel layer can include display drivers, camera drivers, audio drivers, sensor drivers, etc.
[0272] Understandably, Figure 22 The layers in the software system shown, and the functional modules included in each layer, do not constitute a specific limitation on the electronic device. In other embodiments of this application, the electronic device may include more or fewer layers than shown, and each layer may include more or fewer functional modules; this application does not limit this.
[0273] The above embodiments illustrate wallpaper editing using the functional modules described above. In practical applications, these functions can be assigned to different functional modules as needed, meaning the internal structure of the electronic device can be divided into different functional modules to complete all or part of the functions described above. Furthermore, the specific names of each functional module are only for easy differentiation and are not intended to limit the scope of protection of this application.
[0274] After describing the technical architecture of the wallpaper editing function provided in the embodiments of this application, a timing diagram of the wallpaper editing method provided in the embodiments of this application is described, which is consistent with... Figures 2 to 21 The scene shown corresponds to this.
[0275] Figure 23 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 23 The flowchart shown illustrates the specific process of displaying the wallpaper editing interface when the wallpaper editing function is used for the first time. See also... Figure 23 The method may include the following steps:
[0276] Step 2301: The lock screen application receives the first gesture operation.
[0277] The first gesture operation can be a predefined gesture operation. For example, the first gesture operation can be a two-finger pinch operation, a long press operation, a double-tap operation, an S-shaped swipe operation, etc., and this application embodiment does not limit it.
[0278] For example, suppose the first gesture is a two-finger pinch. Figure 8 As shown in (a), when the electronic device displays the lock screen interface 800, the user can perform a two-finger pinch on the lock screen interface 800. In this case, the lock screen application can receive the two-finger pinch operation on the lock screen interface 800. Specifically, the two-finger pinch operation triggered on the lock screen interface 800 is used to indicate entry into the wallpaper editing function, that is, to indicate the display of the wallpaper editing interface.
[0279] Step 2302: In response to the first gesture operation, the lock screen application sends a first message to the gallery application.
[0280] For example, the first message could be an intent message.
[0281] The first message can carry source information, which indicates which application the first message comes from. For example, the source information in the first message can be the application identifier of the lock screen application.
[0282] In some implementations, if the lock screen wallpaper has not been edited using the wallpaper editing method provided in this application, the lock screen wallpaper is generally a default wallpaper image. In this case, the first message may also carry the storage path of the wallpaper image.
[0283] Since the first gesture triggered on the lock screen is used to indicate entry into the wallpaper editing function, the lock screen application can send a first message to the gallery application after receiving the first gesture to instruct the gallery application to display the wallpaper editing interface.
[0284] Step 2303: After receiving the first message, the main functional module in the Gallery application determines that the first message comes from the Lock Screen application, and then displays the functional controls.
[0285] For example, such as Figure 8 As shown in (b) and (c) in the figure, the functional control may include main functional controls, such as the return control 70 and the completion control 71, and may also include related functional controls for editing lock screen wallpapers, such as clock frame 710, image change control 720, lock screen style control 72, AI style control 73, personalized decoration control 74, depth of field effect control 75, and related functional controls for editing desktop wallpapers, such as follow lock screen control 76, color control 77, wallpaper selection control 78, blur control 79, etc.
[0286] The main functional module can determine whether the first message comes from the lock screen application based on the source information in the first message.
[0287] In some embodiments, if the main functional module determines that the first message comes from a lock screen application, then the main functional module can determine that the display area of the lock screen wallpaper page is a preset first display area within the screen, and the display area of the desktop wallpaper page is a preset second display area, wherein the second display area is either partially located within the screen or completely located outside the screen. In this case, such as Figure 8 As shown in (b), the main functional module can first display the main functional controls and related functional controls for editing the lock screen wallpaper, while temporarily not displaying the related functional controls for editing the desktop wallpaper.
[0288] In some embodiments, the size of the first display area is the same as the size of the second display area. The area ratio (i.e., the area aspect ratio) of the first display area and the area ratio of the second display area are both the same as the screen ratio (i.e., the screen aspect ratio) of the electronic device.
[0289] For example, such as Figure 24As shown, when the first message originates from the lock screen application, the main functional module can determine that the display area of the lock screen wallpaper page is a preset display area A within the screen, while the display area of the desktop wallpaper page is a preset display area B. Display area B has only a very small portion within the screen, with the majority located off-screen. In this case, the user can see the complete lock screen wallpaper page, but only a very small portion of the desktop wallpaper page.
[0290] In some embodiments, if the main functional module determines that the first message comes from a lock screen application, it may also display a mask. For example, such as Figure 7 As shown, layer 704 is the bottommost layer of the wallpaper editing interface 700. The function controls, lock screen wallpaper page 702, and desktop wallpaper page 703 in the wallpaper editing interface 700 are all displayed on top of layer 704.
[0291] For example, the mask can be a blurred mask, which is a mask obtained through blurring.
[0292] As an example, the main functional module can retrieve the corresponding image based on the storage path of the image carried in the first message (i.e., the wallpaper image mentioned above), or it can retrieve a preset image. Then, the main functional module can adjust the image according to the screen information to make its size match the screen size, then blur the image to obtain the overlay, and finally display the overlay.
[0293] In one possible implementation, the main functional module can adjust the image based on screen information by: cropping the image according to the screen ratio, with the cropped image having the same aspect ratio as the screen; dividing the screen height by the height of the cropped image, or dividing the screen width by the width of the cropped image, to obtain the scaling ratio; and scaling the cropped image according to the scaling ratio, with the scaled image having the same size as the screen size.
[0294] Step 2304: The main functional module sends a first creation instruction to the lock screen view module. The first creation instruction is used to instruct the creation of m views.
[0295] m can be a pre-set value, such as the maximum number of layers a wallpaper template is expected to have, as estimated by a technician. For example, m is an integer greater than or equal to 2, such as 12, 13, etc., but this application does not limit this.
[0296] For example, the first creation instruction can carry the properties of each of the m views.
[0297] The properties of each of the m views can include view identifier, size, position, etc.
[0298] A view identifier is used to uniquely identify a view. For example, if m is 12, the view identifiers of the 12 views can be "layer_origin", "layer_color", "layer_res1", "layer_res2", "layer_res3", "layer_res4", "layer_res5", "layer_res6", "layer_res7", "layer_res8", "layer_timer", and "layer_crop".
[0299] The size of each of the m views can be the size of the display area of the lock screen wallpaper page (i.e., the first display area). The position of each of the m views can be the position of the first display area.
[0300] Step 2305: After receiving the first creation instruction, the lock screen view module creates m views.
[0301] The lock screen view module can create m views based on the attributes of each of the m views specified in the first creation command. All m newly created views are blank views, meaning they are transparent views without any content yet drawn.
[0302] Step 2306: The main functional module sends a second creation instruction to the desktop view module. The second creation instruction is used to instruct the creation of n views.
[0303] n can be a pre-set numerical value. For example, n is an integer greater than or equal to 2, such as 2, 3, etc., but this application does not limit this.
[0304] For example, the second creation instruction can carry the properties of each of the n views.
[0305] The properties of each of the n views can include view identifier, size, position, etc.
[0306] For example, when n equals 2, the view identifiers for the two views can be "layer_origin" and "layer_icon".
[0307] The size of each of the n views can be the size of the display area of the desktop wallpaper page (i.e., the second display area). The position of each of the n views can be the position of the second display area.
[0308] It should be noted that the operation of displaying the functional controls in step 2303, the operation of sending the first creation command to the lock screen view module in step 2304, and the operation of sending the second creation command to the desktop view module in step 2306 do not have a strict sequential order. That is, the functional module can display the functional controls first and then send the first and second creation commands, or the functional module can send the first and second creation commands first and then display the functional controls, or the functional module can send the first and second creation commands at the same time as displaying the functional controls.
[0309] Step 2307: After receiving the second creation instruction, the desktop view module creates n views.
[0310] The Desktop View module can create n views based on the attributes of each of the n views specified in the second creation command. All n newly created views by the Desktop View module are blank views.
[0311] Step 2308: The main functional module sends a wallpaper file retrieval request to the file system.
[0312] This wallpaper file retrieval request is used to request lock screen wallpaper files and desktop wallpaper files.
[0313] A lock screen wallpaper file is a file that contains data related to the current lock screen wallpaper of an electronic device.
[0314] A desktop wallpaper file is a file that contains data related to the current desktop wallpaper on your electronic device.
[0315] Step 2309: After receiving the wallpaper file retrieval request, the file system sends the lock screen wallpaper file and the desktop wallpaper file to the main functional module.
[0316] After receiving a wallpaper file retrieval request from the main functional module of the gallery application, the file system can send the first file of the lock screen wallpaper as the lock screen wallpaper file and the first file of the desktop wallpaper as the desktop wallpaper file to the main functional module.
[0317] The first file of the lock screen wallpaper is the lock screen wallpaper file that the gallery application needs to use when editing the lock screen wallpaper. In some implementations, if the lock screen wallpaper has not been edited using the wallpaper editing method provided in this application embodiment, the lock screen wallpaper can be a preset first image, in which case the first file of the lock screen wallpaper can contain the storage path of the first image.
[0318] The first file of the desktop wallpaper is the desktop wallpaper file that the gallery application needs to use when editing the desktop wallpaper. In some implementations, if the desktop wallpaper has not been edited using the wallpaper editing method provided in this application embodiment, the desktop wallpaper can be a preset second image, in which case the first file of the desktop wallpaper can include the storage path of the second image.
[0319] The first and second images are wallpaper images pre-installed on electronic devices. The first and second images may be the same or different, and this application embodiment does not limit this.
[0320] Step 2310: After receiving the lock screen wallpaper file and the desktop wallpaper file, the main functional module obtains the first image based on the lock screen wallpaper file and the second image based on the desktop wallpaper file.
[0321] After receiving the lock screen wallpaper file, if the lock screen wallpaper file contains the storage path of the first image, the main functional module can retrieve the first image based on the storage path.
[0322] After receiving the desktop wallpaper file, if the desktop wallpaper file contains the storage path of the second image, the main functional module can retrieve the second image based on the storage path.
[0323] It should be noted that, in this embodiment, after the main functional module obtains the image (such as the first image or the second image) according to the storage path, it saves the obtained image in memory and performs subsequent processing on it, rather than directly processing the original image in the storage path. This avoids the related processing from damaging the original image.
[0324] It should be noted that the images described in this application embodiment may exist in the electronic device as image data before being displayed, and can be drawn and rendered on the screen according to the image data during display. Therefore, obtaining the first image can be understood as obtaining the first image data, and obtaining the second image can be understood as obtaining the second image data.
[0325] Step 2311: The main functional module processes the first image to obtain the first display image, and processes the second image to obtain the second display image.
[0326] The first displayed image is the image used to fill the entire display area of the lock screen wallpaper page.
[0327] The second display image is the image used to display on the desktop wallpaper page. The second display image is an image that can fill the entire display area of the desktop wallpaper page.
[0328] In some embodiments, the operation of the main functional module to process the first image to obtain the first display image may include the following steps (1) to (2).
[0329] (1) The main functional module determines the initial scaling ratio of the first image based on the screen size and the size of the first image, and scales the first image according to the initial scaling ratio to obtain a full-screen image.
[0330] The initial scaling ratio is used to process the first image as a full-screen image, which means an image that can fill the entire screen.
[0331] Specifically, the screen height can be divided by the height of the first image to obtain a first value, and the screen width can be divided by the width of the first image to obtain a second value. The larger of the first and second values can then be used as the initial scaling ratio of the first image.
[0332] (2) The main functional module scales the full-screen image according to a specific scaling ratio to obtain the first display image.
[0333] A specific scaling factor is used to process the full-screen image into an image that can fill the display area of the lock screen wallpaper page. For example, the specific scaling factor can be obtained by dividing the height (or width) of the display area of the lock screen wallpaper page by the screen height (or screen width).
[0334] It should be noted that the operation of the main functional module in processing the second image to obtain the second display image is similar to the operation of the main functional module in processing the first image to obtain the first display image, and will not be described again in this embodiment.
[0335] Step 2312: The main functional module sends the first display command to the lock screen view module.
[0336] The first display instruction is used to instruct the display of the m views. The first display instruction carries a first view identifier and a first display image. For example, the first view identifier can be "layer_origin".
[0337] Step 2313: After receiving the first display instruction, the lock screen view module draws the first display image in the view identified by the first view identifier and displays the m views, where the content of the original layer is the first display image, and the other layers are blank views.
[0338] After the lock screen view module draws the first display image in the view identified by the first view identifier, the view with the first display image can be called the original layer. The other m-1 views besides the original layer are still blank views. Therefore, after the lock screen view module displays the m views, the user will only see the content in the original layer.
[0339] For example, the operation of the lock screen view module to draw the first display image in the view identified by the first view identifier can be as follows: the lock screen view module determines the target area in the first display image and draws the image in the first display image that is within the target area into the view identified by the first view identifier.
[0340] The target area in the first displayed image is the area within the first displayed image that can be shown on the lock screen wallpaper page. The target area in the first displayed image can be an area centered on the center of the first displayed image and having the same size as the view's dimensions. For example, the target area in the first displayed image could be... Figure 25 The area within the dashed line shown.
[0341] For example, when the lock screen view module displays the m views, it can submit the m views to the rendering service for rendering so that the m views can be displayed in the display area (i.e., the first display area) of the lock screen wallpaper page on the screen, thus realizing the display of the lock screen wallpaper in the lock screen wallpaper page.
[0342] It should be noted that, as Figure 24 As shown, since the first display area is display area A completely located within the screen, after the lock screen view module displays the m views, as follows: Figure 8 As shown in (b), users can see the lock screen wallpaper in lock screen wallpaper page 702.
[0343] Step 2314: The main functional module sends a second display command to the desktop view module.
[0344] The second display instruction is used to instruct the display of the n views.
[0345] For example, when n equals 2, the second display instruction can carry a second view identifier, a second display image, a third view identifier, and a desktop thumbnail. For example, the second view identifier can be "layer_origin", and the third view identifier can be "layer_icon". When n is greater than 2, the second display instruction can also carry other view identifiers and corresponding layer information.
[0346] The desktop thumbnail is a thumbnail of the desktop content. For example, after receiving the first message, the main functional module can obtain the desktop thumbnail from the desktop application. Of course, the main functional module can also obtain the desktop thumbnail through other means, and this embodiment of the application does not limit this.
[0347] Step 2315: After receiving the second display instruction, the desktop view module draws the second display image in the view identified by the second view identifier, draws the desktop thumbnail in the view identified by the third view identifier, and displays the n views.
[0348] When n equals 2, after the desktop view module draws the second display image in the view identified by the second view identifier, this view with the second display image can be called the original layer. After the desktop view module draws the desktop thumbnail in the view identified by the third view identifier, this view with the desktop thumbnail can be called the desktop icon layer. The desktop icon layer is at a higher level than the original layer; that is, the desktop icon layer is located above the original layer.
[0349] When n is greater than 2, the desktop view module can also draw layer content in the view identified by the other view identifier according to the layer information corresponding to the other view identifier carried by the second display instruction. When n is greater than 2, and the second display instruction only carries the second view identifier and the third view identifier, the second display image is drawn in the view identified by the second view identifier, and the desktop thumbnail is drawn in the view identified by the third view identifier. The other n-2 views, excluding the original layer and the desktop icon layer, remain blank views.
[0350] The operation of the desktop view module drawing the second display image in the view identified by the second view identifier is similar to the operation of the lock screen view module drawing the first display image in the view identified by the first view identifier, and will not be described again in this embodiment.
[0351] The operation of the desktop view module drawing a desktop thumbnail in the view identified by the third view identifier is similar to the operation of the lock screen view module drawing a first display image in the view identified by the first view identifier, and will not be described again in this embodiment.
[0352] For example, when displaying the n views, the desktop view module can submit the n views to the rendering service for rendering in ascending order of hierarchy, so that the n views can be displayed in the display area (i.e., the second display area) of the desktop wallpaper page on the screen, thus realizing the display of the desktop wallpaper and desktop content in the desktop wallpaper page.
[0353] It should be noted that in some cases, such as Figure 24As shown, since the second display area is display area B, which consists of only a small portion within the screen and the vast majority outside the screen, after the desktop view module displays these n views, as shown... Figure 8 As shown in (b), users cannot see the desktop wallpaper and desktop content on the desktop wallpaper page.
[0354] In other cases, the second display area may be mostly or completely within the screen. In this case, after the desktop view module displays the n views, the user can see part or all of the desktop wallpaper and desktop content from the desktop wallpaper page.
[0355] After displaying the function controls, lock screen wallpaper page, and desktop wallpaper page through the above steps, the display of the wallpaper editing interface is complete. For example, the displayed wallpaper editing interface can be... Figure 8 The wallpaper editing interface 700 is shown in (b) of the image.
[0356] It should be noted that after the wallpaper editing interface is displayed, the main functional module can be determined to be in the initial editing state.
[0357] In some embodiments, the main functional module may also create a first cache management module, a second cache management module, and a persistence management module during the display of the wallpaper editing interface.
[0358] After the wallpaper editing interface is displayed, users can edit the lock screen wallpaper based on the wallpaper editing interface. The following is a detailed explanation of the specific implementation process of various editing functions.
[0359] Figure 26 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 26 The flowchart shown illustrates the specific process of a user selecting a wallpaper template based on the wallpaper editing interface. See also... Figure 26 The method may include the following steps:
[0360] Step 2601: The main functional module receives click operations on the lock screen style control.
[0361] When the lock screen wallpaper page is displayed in the wallpaper editing interface, various editing operations can be performed on the wallpaper. In some cases, if the user wants to change the style of the lock screen wallpaper, such as... Figure 10 As shown in (a), the user can click on the lock screen style control 72, and the main functional module will receive the click operation on the lock screen style control 72.
[0362] Step 2602: In response to a click on the lock screen style control, the main function module displays the first pop-up window.
[0363] For example, such as Figure 10 As shown in (b), the first pop-up window 7011 displays multiple wallpaper template options. Optionally, it may also display image options from the gallery and some wallpaper image options preset by the electronic device.
[0364] Step 2603: The main functional module receives the selection operation for wallpaper template option 1.
[0365] For example, such as Figure 10 As shown in (b), after the user clicks on a wallpaper template option (hereinafter referred to as wallpaper template option 1) displayed in the first pop-up window 7011, the main functional module will receive a selection operation for wallpaper template option 1. For example, wallpaper template option 1 is the option corresponding to wallpaper template 1.
[0366] Step 2604: In response to the selection operation of wallpaper template option 1, the main function module obtains the template identifier corresponding to wallpaper template option 1.
[0367] Each template identifier uniquely identifies a wallpaper template. The template identifier corresponding to wallpaper template option 1 is the template identifier for wallpaper template 1.
[0368] The wallpaper templates in this embodiment can be preset. Each wallpaper template may include multiple layers, and the types and levels of the multiple layers included in each wallpaper template can be preset.
[0369] For example, such as Figure 4 As shown, a wallpaper template, from bottom to top, can include the original layer and a clock layer; or it can include the original layer, a color background layer, a clock layer, and a cutout layer; or it can include the original layer, decoration layer 1, a clock layer, and decoration layer 2; or it can include the original layer, decoration layer 1, a clock layer, a cutout layer, and decoration layer 2. Of course, these are not the only examples; the multiple layers included in a wallpaper template can be flexibly set according to actual needs.
[0370] Step 2605: The main functional module sends a wallpaper template data retrieval request to the file system.
[0371] This wallpaper template data retrieval request is used to request the wallpaper template file corresponding to wallpaper template 1. This request may include the template identifier for wallpaper template 1.
[0372] Step 2606: After receiving the wallpaper template data acquisition request, the file system sends the wallpaper template file to the main functional module.
[0373] Specifically, the file system can obtain the corresponding wallpaper template file based on the template identifier and send the wallpaper template file to the main functional module.
[0374] For example, a wallpaper template file may contain layer set information for the wallpaper template. Furthermore, the wallpaper template file may also contain one or more of the following: offset information, scale ratio information, blur factor information, and depth-of-field support status information.
[0375] Layer set information includes basic layer information for each of the multiple layers, and this basic layer information can be organized in hierarchical order within the layer set information.
[0376] For example, the basic information of the original layer may include view identifier, layer type, image storage path, etc. The basic information of the color background layer may include view identifier, layer type, color setting type, color value, etc. The basic information of the decoration layer may include view identifier, layer type, image storage path, color setting type, color value, etc. The basic information of the clock layer may include view identifier, layer type, layout, font, color value, color setting type, etc. The basic information of the cutout layer may include view identifier, layer type, image storage path, etc.
[0377] Offset information can be determined based on user movement and scaling operations on the main image, indicating how much the center of the main image has shifted relative to the screen center after movement. Offset information applies to both the original layer and the cutout layer. In some cases, if the user has not moved or scaled the main image, the offset in the offset information can be set to [0,0] by default.
[0378] The scaling ratio information is determined based on the user's scaling operation on the main image, indicating how much the scaled main image has been reduced compared to the original. The scaling ratio information applies to both the original layer and the cutout layer. In some cases, if the user has not scaled the main image, the scaling ratio in the scaling ratio information can default to 1.
[0379] Blur information can be determined based on the background blur adjusted by the user and is used to indicate the blur level of the main image. Blur information applies to the original layer. In some cases, if the user has not adjusted the background blur, the blur level in the blur information can be set to 0 by default.
[0380] The depth-of-field effect switch status information indicates whether the depth-of-field effect switch is on or off. This status information applies to the clock layer and the keying layer. In some cases, if the user has not interacted with the depth-of-field effect switch, the status information can default to on or off.
[0381] It should be noted that the basic layer information of each layer in the layer set information of the wallpaper template file can be preset. Furthermore, the offset information in the offset information of the wallpaper template file can be set to [0,0] by default, the scaling ratio information can be set to 1 by default, the blur information can be set to 0 by default, and the depth-of-field effect on / off status information can be set to on by default.
[0382] The format of the wallpaper template file can be preset. For example, the wallpaper template file can be a txt file, a doc file, a docx file, a JavaScript Object Notation (JSON) file, etc., and this embodiment of the application does not limit this.
[0383] JSON files can store data in the form of "key-value pairs," where each "key" has a unique "value," and each "value" can also have its own child "key-value pairs." This structure is effective for recording information such as layer sets, offsets, scaling ratios, blur levels, and depth-of-field effect on / off states.
[0384] As an example, a JSON file can contain, for example, Figure 27 The information shown includes various parameters. "type" indicates the layer type; for example, the values of "type" are: [0] Original layer, [1] Color background layer, [2] Decoration layer, [3] Clock layer, [4] Cutout layer. "colorPolicy" indicates the color setting type; for example, the values of "colorPolicy" are: [0] No color setting allowed, [1] Main color, can be set independently, [2] Cannot be set independently, use main color and secondary color, [3] Main color gradient, [4] Select clock color. "isDepthofFieldSupported" indicates the depth-of-field effect on / off status; for example, the values of "isDepthofFieldSupported" are: [true] On, [false] Off.
[0385] It's worth noting that JSON files have a simple and efficient format, with straightforward syntax rules and more efficient data parsing. Therefore, when the wallpaper template file is a JSON file, the main functional module can retrieve the wallpaper template file from the file system more quickly and parse it faster.
[0386] Step 2607: After receiving the wallpaper template file, the main functional module obtains the display information of each layer in the multiple layers according to the wallpaper template file.
[0387] For example, the display information of the clock layer may include the view identifier, hierarchy, and clock settings information (including layout, font, and color values).
[0388] For example, for layers other than the clock layer, such as the original layer, color background layer, decoration layer, cutout layer, etc., the display information of the layer may include the layer's view identifier, layer, and display image. This display image is an image used to display on the lock screen wallpaper page, and it can fill the display area of the lock screen wallpaper page.
[0389] For example, the original layer's display information also includes a specific offset, scaling factor, and blur level. The cut-out layer's display information also includes a specific offset and scaling factor.
[0390] In some embodiments, see Figure 28 The operation of step 2607 may include steps 2801 to 2804.
[0391] Step 2801: The main functional module determines the view identifier, layer, and clock setting information of the clock layer based on the layer set information in the wallpaper template file, as well as the view identifier, layer, and full-screen image of each layer other than the clock layer.
[0392] For layers other than the clock layer, such as the original layer, color background layer, decoration layer, cutout layer, etc., the layer has an initial image. In this embodiment of the application, the initial image can be processed into a full-screen image, which refers to an image that can fill the entire screen.
[0393] As an example, see Figure 29 Step 2801 may include the following steps 28011 to 28018:
[0394] Step 28011: The main functional module determines the number of layers based on the layer set information.
[0395] For example, the main functional module can determine the number of view identifiers in the layer set information as the layer number. For instance, for... Figure 27 The JSON file shown can be used to determine the number of "id" entries in "layers" as the number of layers, thus determining that the number of layers is 8.
[0396] The following assumes that the number of layers is k, where k is an integer greater than or equal to 2.
[0397] Step 28012: Determine i as 1 for the main functional module.
[0398] Step 28013: The main functional module determines whether the i-th layer in the layer set information is a clock layer.
[0399] For example, the main functional module can determine whether the i-th layer is a clock layer based on the layer type in the layer base information of the i-th layer.
[0400] Step 28014: If the i-th layer is a clock layer, the main functional module obtains the view identifier in the basic information of the clock layer, and uses the layout, font and color values in the basic information of the clock layer as the clock setting information of the clock layer, and determines the level of the clock layer as i.
[0401] Step 28015: If the i-th layer is not a clock layer, the main functional module obtains the view identifier and initial image of the i-th layer based on the basic layer information of the i-th layer, processes the initial image of the i-th layer to obtain the full-screen image of the i-th layer, and determines the level of the i-th layer as i.
[0402] Step 28016: The main functional module determines whether i is equal to k.
[0403] Step 28017: If i is not equal to k, then the main functional module sets i = i + 1 and re-executes step 28013 and subsequent steps.
[0404] Step 28018: If i equals k, then the main functional module ends its operation.
[0405] For example, the operation of the main functional module to obtain the initial image of the i-th layer based on the layer basic information of the i-th layer can be as follows: If the layer basic information of the i-th layer contains an image storage path but does not contain color values and color setting types, then the image is obtained based on the image storage path as the initial image of the i-th layer; if the layer basic information of the i-th layer contains an image storage path, color values, and color setting types, then the image is obtained based on the image storage path, and the color of the image is set according to the color values and color setting types to obtain the initial image of the i-th layer; if the layer basic information of the i-th layer does not contain an image storage path but contains color values and color setting types, then an image with the same size as the screen size is generated, and the color of the image is set according to the color values and color setting types to obtain the initial image of the i-th layer.
[0406] for example, Figure 27The first array in the "layers" section of the JSON file shown (the array containing "id": "layer_origin") contains the basic layer information for the first layer. Based on the layer type in the first array ("type": 0), the first layer can be identified as the original layer. Since the first array does not contain color values or color setting types, the image can be retrieved as the initial image for the first layer based on the image storage path in the first array ("src": "02_origin.png").
[0407] Figure 27 The second array in the "layers" section of the JSON file shown (the array containing "id": "layer_color") contains the basic layer information for the second layer. Based on the layer type ("type": 1) in the second array, the second layer is determined to be a color background layer. Since the second array does not contain the image storage path, an image with the same size as the screen can be generated. The image's color is then set according to the color value ("color": "#FFECBD5B") and color setting type ("colorPolicy": 1) in the second array, resulting in the initial image for the second layer.
[0408] Figure 27 The third array in the "layers" section of the JSON file shown (the array containing "id": "layer_res1") contains the basic layer information for the third layer. Based on the layer type in the third array ("type": 2), the third layer is identified as a decorative layer. The image can be retrieved using the image storage path in the third array ("src": "02_res1_1.png"), and its color can be set according to the color value ("color": "#FF9C3022") and color setting type ("colorPolicy": 1) in the third array to obtain the initial image for the third layer.
[0409] Figure 27 The fourth array in the "layers" section of the JSON file shown (the array containing "id": "layer_res3") contains the basic layer information for the fourth layer. Based on the layer type in the fourth array ("type": 2), the fourth layer can be identified as a decoration layer. Since the fourth array does not contain color values or color setting types, the image can be obtained as the initial image for the fourth layer based on the image storage path in the fourth array ("src": "02_res1_3.png").
[0410] Figure 27The fifth array in the "layers" section of the JSON file shown (the array containing "id": "layer_timer") contains the basic layer information for the fifth layer. Based on the layer type in the fifth array ("type": 3), we can determine that the fifth layer is a clock layer. We can retrieve the layout ("layout": 0), font ("font": "HonorDigits_SerifVF.ttf"), and color value ("color": "#FFAE3DF") from the fifth array as the clock settings information for the clock layer.
[0411] Figure 27 The sixth array in the "layers" section of the JSON file shown (the array containing "id": "layer_crop") contains the basic layer information for the sixth layer. Based on the layer type in the sixth array ("type": 4), the sixth layer can be identified as a cutout layer. Since the sixth array does not contain color values or color setting types, the image can be obtained as the initial image for the sixth layer based on the image storage path in the sixth array ("src": "02_crop.png").
[0412] For example, the operation of the main functional module to process the initial image of the i-th layer to obtain the full-screen image of the i-th layer can be as follows: the main functional module determines the initial scaling ratio based on the screen size and the size of the initial image, and scales the initial image according to the initial scaling ratio to obtain the full-screen image of the i-th layer.
[0413] This initial scaling factor is used to process the initial image into a full-screen image. Specifically, the screen height is divided by the height of the initial image to obtain a first value, and the screen width is divided by the width of the initial image to obtain a second value. The larger of the first and second values is then used as the initial scaling factor.
[0414] Step 2802: The main functional module scales the full-screen images of the layers other than the clock layer among the multiple layers according to a specific scaling ratio to obtain the display images of the other layers.
[0415] A specific scaling factor is used to process the full-screen image into an image that can fill the display area of the lock screen wallpaper page. For example, the specific scaling factor can be obtained by dividing the height (or width) of the display area of the lock screen wallpaper page by the screen height (or screen width).
[0416] Step 2803: If the depth-of-field effect in the wallpaper template file is in the "on" state, keep the clock layer and the cutout layer unchanged. This will enable the depth-of-field effect. For example, this can achieve... Figure 13 The depth-of-field effect in the wallpaper of lock screen wallpaper page 702 shown in (a) is turned off when the depth-of-field effect switch status information in the wallpaper template file is off. Swapping the layers of the clock layer and the cutout layer will turn off the depth-of-field effect, for example, as shown in (a). Figure 13 The wallpaper shown in (d) of lock screen wallpaper page 702 does not have a depth-of-field effect.
[0417] It should be noted that the layer hierarchy of the clock layer and the cutout layer indicated in the layer set information of the wallpaper template file is usually fixed, with the clock layer typically being lower than the cutout layer. In this case, if the depth-of-field effect switch status information in the wallpaper template file is "on," the layers of the clock layer and the cutout layer remain unchanged. However, if the depth-of-field effect switch status information in the wallpaper template file is "off," the layers of the clock layer and the cutout layer need to be swapped.
[0418] In some embodiments, if the layer set information in the wallpaper template file indicates that the clock layer is at a higher level than the cutout layer, then when the depth-of-field effect switch status information in the wallpaper template file is in the off state, the levels of the clock layer and the cutout layer remain unchanged; when the depth-of-field effect switch status information in the wallpaper template file is in the on state, the levels of the clock layer and the cutout layer need to be swapped.
[0419] Step 2804: The main functional module multiplies the offset in the offset information of the wallpaper template file by a specific scaling ratio to obtain a specific offset. The specific offset, the scaling ratio in the scaling ratio information of the wallpaper template file, and the blur in the blur information are used as the display information of the original layer. The specific offset and the scaling ratio in the scaling ratio information of the wallpaper template file are used as the display information of the cut-out layer.
[0420] It should be noted that in step 2607, after the main functional module receives the wallpaper template file, it can save the wallpaper template file as the currently edited lock screen wallpaper file in memory, and subsequent editing processes will modify the currently edited lock screen wallpaper file.
[0421] Step 2608: The main functional module sends a third display instruction to the lock screen view module.
[0422] The third display instruction is used to instruct the display of the wallpaper template. The third display instruction carries display information for each of the multiple layers.
[0423] Step 2609: After receiving the third display instruction, the lock screen view module draws the layer content in the corresponding view according to the display information of each layer in the multiple layers, and displays m views.
[0424] After receiving the third display command, the lock screen view module can first clear the hierarchy of the previously created m views and the content drawn within them. Then, based on the display information of each of the multiple layers, it sets the hierarchy of the multiple views that correspond one-to-one with the multiple layers, and draws the layer content in each of the multiple views. Finally, it displays the m views. In this case, the other views among the m views are blank views, so after the lock screen view module displays the m views, the user will only see the content drawn in those views.
[0425] In some embodiments, for a clock layer, the lock screen view module can draw a clock in the view identified by the view identifier of the clock layer based on the clock setting information in the clock layer's display information. In this case, the view that draws the layer content of the clock layer can be called the clock layer.
[0426] In some embodiments, for the original layer, the lock screen view module can first blur the displayed image in the original layer's display information based on the blur level. Then, based on the scaling ratio and a specific offset in the original layer's display information, it determines the target area in the displayed image. This target area is the region of the displayed image that can be displayed within the lock screen wallpaper page. Finally, the image within the target area of the displayed image is drawn onto the view identified by the view identifier of the original layer. In this case, the view that draws the layer content of the original layer can be called the original layer.
[0427] For example, such as Figure 30 As shown, taking a scaling ratio of 1.5 and a specific offset of [20,20] as an example, the lock screen view module blurs the displayed image according to the blur level, and can then determine the target area in the displayed image. The target area in the displayed image is the area in the displayed image centered on the center of the displayed image and with the same size as the view identified by the view identifier. While keeping the center of the displayed image unchanged, the displayed image is scaled according to the scaling ratio, and then the scaled displayed image is moved according to the specific offset so that the offset between the center of the moved displayed image and the center of the target area is the specific offset. After that, the image in the moved displayed image that is within the target area is drawn into the view identified by the view identifier.
[0428] In some embodiments, for a cutout layer, the lock screen view module can determine the target area in the displayed image of the cutout layer based on the scaling ratio and a specific offset in the display information of the cutout layer, and draw the image within the target area of the displayed image onto the view identified by the view identifier of the cutout layer. The view on which the layer content of the cutout layer is drawn can be called the cutout layer.
[0429] In some embodiments, for any one of the multiple layers other than the clock layer, the original layer, and the cutout layer, the lock screen view module can draw the display image from the display information of that layer onto the view identified by the view identifier of that layer. For example, the lock screen view module can determine a target area in the display image and draw the image within that target area onto the view.
[0430] For example, when displaying the m views, the lock screen view module can submit them to the rendering service for rendering in ascending order of hierarchy. This allows the m views to be overlaid on the lock screen wallpaper page's display area, thus displaying the wallpaper template on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page can be... Figure 10 The lock screen wallpaper page 702 shown in (c) displays the wallpaper template selected by the user.
[0431] It should be noted that after selecting a wallpaper template through the above process and displaying it on the lock screen wallpaper page, the main functional module can be determined that it is still in the initial editing state.
[0432] In some embodiments, after a user edits the lock screen wallpaper by selecting a wallpaper template, the user can also save the edited lock screen wallpaper to make it effective. This process may include the following steps 2610 to 2612.
[0433] Step 2610: The main functional module receives the click operation on the completion control.
[0434] For example, such as Figure 10 As shown in (c), after selecting a wallpaper template, the user can click the completion control 71 in the wallpaper editing interface 700, and the main functional module will receive the click operation on the completion control 71.
[0435] Step 2611: The main functional module sends a wallpaper file storage request to the file system.
[0436] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 1. Lock screen wallpaper file 1 is the currently edited lock screen wallpaper file, which in this embodiment is the wallpaper template file obtained by the main functional module after the user selects a wallpaper template.
[0437] Step 2612: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0438] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 1.
[0439] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 1, and the user can continue to edit that lock screen wallpaper.
[0440] The following is combined Figures 31 to 36 This section explains the implementation process of basic operations in the initial editing state. These basic operations refer to adjusting the clock, decorations, and depth-of-field effects in the wallpaper, as well as scaling, moving, and blurring the main image in the wallpaper.
[0441] Figure 31 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 31 The flowchart shown illustrates the specific process by which a user sets the clock based on the wallpaper editing interface. Figure 31 The flowchart shown can be executed after step 2609 above; or it can be executed after step 2612, when the user re-enters the wallpaper editing interface on the electronic device.
[0442] See Figure 31 The method may include the following steps:
[0443] Step 3101: The main functional module receives click operations on the clock frame.
[0444] In some cases, if a user wants to set a clock in the lock screen wallpaper, then... Figure 11 As shown in (a), the user can click on the clock frame 710, and the main functional module will receive the click operation on the clock frame 710.
[0445] Step 3102: In response to the click operation on the clock frame, the main function module displays the second pop-up window.
[0446] For example, such as Figure 11 As shown in (b) above, the second pop-up window 7012 displays multiple clock font options and multiple clock color options.
[0447] Step 3103: The main functional module receives the selection operation for clock color option 1.
[0448] For example, such as Figure 11 As shown in (b), after the user clicks on a clock color option (hereinafter referred to as clock color option 1) displayed in the second pop-up window 7012, the main functional module will receive the selection operation for clock color option 1.
[0449] Step 3104: In response to the selection operation of clock color option 1, the main function module obtains the color value corresponding to clock color option 1.
[0450] For example, the color value corresponding to clock color option 1 can be "#FFAE3DA".
[0451] Step 3105: The main function module updates the color value in the basic information of the clock layer in the currently edited lock screen wallpaper file to the color value corresponding to clock color option 1, thus obtaining lock screen wallpaper file 2, and then re-acquires the clock setting information of the clock layer.
[0452] It should be noted that, if Figure 31 The flowchart shown is executed after step 2609 above, or after step 2612, when the user re-enters the wallpaper editing interface on the electronic device. In this case, the currently edited lock screen wallpaper file can be lock screen wallpaper file 1.
[0453] For example, suppose the currently edited lock screen wallpaper file is Figure 27 The JSON file shown has a clock layer color value of "color":"#FFAE3DF". This color value can be updated to "color":"#FFAE3DA".
[0454] The main functional module can retrieve the clock settings information of the clock layer from the basic layer information of the clock layer in the lock screen wallpaper file 2.
[0455] Continuing with the example above, the clock settings information of the re-acquired clock layer may include: layout ("layout":0), font ("font":"HonorDigits_SerifVF.ttf"), and color value ("color":"#FFAE3DA").
[0456] Step 3106: The main functional module sends the view identifier and clock setting information of the clock layer to the lock screen view module.
[0457] Step 3107: After receiving the view identifier and clock setting information of the clock layer, the lock screen view module redraws the layer content in the view identified by the view identifier of the clock layer according to the clock setting information of the clock layer, and displays m views.
[0458] After receiving the view identifier and clock setting information of the clock layer, the lock screen view module can redraw the clock in the view according to the clock setting information while keeping the layer of the view identified by the view identifier unchanged. Then, these m views can be submitted to the rendering service for rendering in ascending order of layer level, so that the m views are overlaid on the display area of the lock screen wallpaper page on the screen, thus realizing the display of the wallpaper on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page can be... Figure 11 The lock screen wallpaper page 702 shown in (c) has a clock in the displayed wallpaper that is the color set by the user.
[0459] It should be noted that the operation of setting the font of the clock in the lock screen wallpaper through the second pop-up window is similar to the operation of setting the color of the clock as described above, and will not be described again in this embodiment.
[0460] In some embodiments, after a user edits the lock screen wallpaper by setting a clock, the user can also save the edited lock screen wallpaper to make it effective. This process may include the following steps 3108 to 3110.
[0461] Step 3108: The main functional module receives the click operation on the completion control.
[0462] For example, such as Figure 11 As shown in (c), after changing the color of the clock in the lock screen wallpaper, the user can directly click the completion control 71 in the wallpaper editing interface 700, and the main functional module will receive the click operation on the completion control 71. Or, as... Figure 11 As shown in (c), after changing the color of the clock in the lock screen wallpaper, the user can first click the fold control 712 in the second pop-up window 7012, and then, as shown in (c). Figure 11 As shown in (d), the user then clicks the completion control 71 in the wallpaper editing interface 700, and the main function module will receive the click operation on the completion control 71.
[0463] Step 3109: The main functional module sends a wallpaper file storage request to the file system.
[0464] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 2. Lock screen wallpaper file 2 is the currently edited lock screen wallpaper file, and in this embodiment, it is the lock screen wallpaper file updated by the main functional module according to relevant setting information after the user sets the clock.
[0465] Step 3110: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0466] For example, the file system can update the first lock screen wallpaper file to lock screen wallpaper file 2.
[0467] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 2, and the user can continue to edit that lock screen wallpaper.
[0468] Figure 32 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 32 The flowchart shown illustrates the specific process by which users set personalized decorations based on the wallpaper editing interface. Figure 32 The flowchart shown can be executed after step 2609 above; or, it can be executed after step 2612, when the user re-enters the wallpaper editing interface on the electronic device; or, it can be executed after step 3107; or, it can be executed after step 3110, when the user re-enters the wallpaper editing interface on the electronic device.
[0469] See Figure 32 The method may include the following steps:
[0470] Step 3201: The main functional module receives click operations on the personalized decoration control.
[0471] In some cases, if a user wants to set decorative elements in the lock screen wallpaper, then... Figure 12 As shown in (a), users can click on the personalized decoration control 74, and the main functional module will receive the click operation on the personalized decoration control 74.
[0472] Step 3202: In response to the click operation on the personalized decoration control, the main functional module displays the third pop-up window.
[0473] For example, such as Figure 12 As shown in (b) above, the third pop-up window 7014 displays multiple shape options and multiple color options.
[0474] Step 3203: The main functional module receives the selection operation for color option 1.
[0475] For example, such as Figure 12 As shown in (b), after the user clicks on a color option (hereinafter referred to as color option 1) displayed in the third pop-up window 7014, the main functional module will receive the selection operation for color option 1.
[0476] Step 3204: In response to the selection operation of color option 1, the main function module obtains the color value corresponding to color option 1.
[0477] It should be noted that when multiple decorative layers exist, color option 1 corresponds not only to a color value but also to one of the decorative layers. In this case, if the user adjusts the color of the decorative layer they are working with, the color of that specific decorative layer will be modified.
[0478] Step 3205: The main function module updates the color value in the basic information of the decorative layer of the currently edited lock screen wallpaper file to the color value corresponding to color option 1, thus obtaining lock screen wallpaper file 3, and then re-acquires the display image of the decorative layer.
[0479] It should be noted that, if Figure 32 The flowchart shown is executed after step 2609 above, or after step 2612, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 1. However, if... Figure 32 The flowchart shown is executed after step 3107 above, or after step 3110, when the user re-enters the wallpaper editing interface on the electronic device. In this case, the currently edited lock screen wallpaper file can be lock screen wallpaper file 2.
[0480] The main functional module can retrieve the display image of the decorative layer from the lock screen wallpaper file 3. For example, the main functional module can retrieve the image from the image storage path in the basic layer information of the decorative layer in the lock screen wallpaper file 3, set the color of the image according to the color value and color setting type in the basic layer information of the decorative layer in the lock screen wallpaper file 3, obtain the initial image of the decorative layer, process the initial image of the decorative layer to obtain the full-screen image of the decorative layer, and then scale the full-screen image of the decorative layer according to a specific scaling ratio to obtain the display image of the decorative layer. The operation of the main functional module processing the initial image of the decorative layer to obtain the full-screen image of the decorative layer is similar to the operation of the main functional module processing the initial image of the i-th layer to obtain the full-screen image of the i-th layer in step 2801 above, and will not be described again in this embodiment.
[0481] Step 3206: The main functional module sends the view identifier and display image of the decoration layer to the lock screen view module.
[0482] Step 3207: After receiving the view identifier and display image of the decoration layer, the lock screen view module redraws the layer content in the view identified by the view identifier of the decoration layer according to the display image of the decoration layer, and displays m views.
[0483] After receiving the view identifier and display image of the decoration layer, the lock screen view module can redraw the layer content in the view based on the display image, while keeping the layer hierarchy of the view identified by the view identifier unchanged. Specifically, it can determine the target area in the display image and draw the image within that target area into the view. Then, it can submit these m views to the rendering service for rendering in ascending order of layer hierarchy, so that the m views are overlaid on the display area of the lock screen wallpaper page on the screen, thus realizing the display of the wallpaper on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page can be... Figure 12 The lock screen wallpaper page 702 shown in (c) displays wallpapers where the colors of the decorative elements are those set by the user.
[0484] In some embodiments, after a user edits the lock screen wallpaper by setting the color of the decorative element, the user can also save the edited lock screen wallpaper to make it effective. This process may include the following steps 3208 to 3210.
[0485] Step 3208: The main functional module receives the click operation on the completion control.
[0486] For example, such as Figure 12 As shown in (c), after changing the color of the decorative element in the lock screen wallpaper, the user can directly click the completion control 71 in the wallpaper editing interface 700, and the main functional module will receive the click operation on the completion control 71. Or, as... Figure 12 As shown in (c), after changing the color of the decorative element in the lock screen wallpaper, the user can first click the fold control 714 in the third pop-up window 7014, and then, as shown in (c), the user can ... Figure 12 As shown in (d), the user then clicks the completion control 71 in the wallpaper editing interface 700, and the main function module will receive the click operation on the completion control 71.
[0487] Step 3209: The main functional module sends a wallpaper file storage request to the file system.
[0488] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 3. Lock screen wallpaper file 3 is the currently edited lock screen wallpaper file, which in this embodiment is the lock screen wallpaper file updated by the main functional module according to the relevant color information after the user sets the color of the decorative elements.
[0489] Step 3210: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0490] For example, the file system can update the first lock screen wallpaper file to lock screen wallpaper file 3.
[0491] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 3, and the user can continue to edit that lock screen wallpaper.
[0492] It should be noted that the operation of setting the shape of the decorative items in the lock screen wallpaper through the third pop-up window is similar to the operation of setting the color of the decorative items mentioned above. The following is a brief explanation of this.
[0493] Figure 33 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 33 The flowchart shown illustrates the specific process by which users set personalized decorations based on the wallpaper editing interface. Figure 33 The flowchart shown can be executed after step 2609 above; or, after step 2612, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3107; or, after step 3110, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3207; or, after step 3210, when the user re-enters the wallpaper editing interface on the electronic device.
[0494] See Figure 33 The method may include the following steps:
[0495] Step 3301: The main functional module receives click operations on the personalized decoration control.
[0496] Step 3302: In response to the click operation on the personalized decoration control, the main functional module displays the third pop-up window.
[0497] The third pop-up window displays several shape options, including shape option 1.
[0498] Step 3303: The main functional module receives the selection operation for shape option 1.
[0499] Step 3304: In response to the selection operation of shape option 1, the main function module obtains the image storage path corresponding to shape option 1.
[0500] The image storage path corresponding to Shape Option 1 is the storage path of the decorative image containing the pattern shape corresponding to Shape Option 1.
[0501] It should be noted that when multiple decorative layers exist, shape option 1 corresponds not only to the image storage path but also to one of the decorative layers. In this case, any shape adjustment made by the user to a specific decorative layer will modify the shape of that layer.
[0502] Step 3305: The main function module updates the image storage path in the basic layer information of the decorative layer in the currently edited lock screen wallpaper file to the image storage path corresponding to shape option 1, thus obtaining lock screen wallpaper file 4, and then re-acquires the display image of the decorative layer.
[0503] It should be noted that, if Figure 33 The flowchart shown is executed after step 2609 above, or after step 2612, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 1. However, if... Figure 33 The flowchart shown is executed after step 3107 above, or after step 3110, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 2. However, if... Figure 33 The flowchart shown is executed after step 3207 above, or after step 3210, when the user re-enters the wallpaper editing interface on the electronic device. In this case, the currently edited lock screen wallpaper file can be lock screen wallpaper file 3.
[0504] The main functional module can retrieve the display image of the decorative layer from the lock screen wallpaper file 4. The operation of the main functional module retrieving the display image of the decorative layer from the lock screen wallpaper file 4 is similar to the operation of the main functional module retrieving the display image of the decorative layer from the lock screen wallpaper file 3 in step 3205 above, and will not be described again in this embodiment.
[0505] Step 3306: The main functional module sends the view identifier and display image of the decoration layer to the lock screen view module.
[0506] Step 3307: After receiving the view identifier and display image of the decoration layer, the lock screen view module redraws the layer content in the view identified by the view identifier of the decoration layer according to the display image of the decoration layer, and displays m views.
[0507] After receiving the view identifier and display image of the decoration layer, the lock screen view module can redraw the layer content in the view based on the display image, while keeping the layer hierarchy of the view identified by the view identifier unchanged. Specifically, it can determine the target area in the display image and draw the image within the target area into the view. Then, it can submit these m views to the rendering service for rendering in ascending order of layer hierarchy, so that the m views are overlaid on the display area of the lock screen wallpaper page on the screen, thus realizing the display of the wallpaper on the lock screen wallpaper page. In this case, the shape of the wallpaper decoration on the displayed lock screen wallpaper page is the shape selected by the user.
[0508] In some embodiments, after a user edits the lock screen wallpaper by setting the shape of the decorative element, the user can also save the edited lock screen wallpaper to make it effective. This process may include the following steps 3308 to 3310.
[0509] Step 3308: The main functional module receives the click operation on the completion control.
[0510] Step 3309: The main functional module sends a wallpaper file storage request to the file system.
[0511] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 4. Lock screen wallpaper file 4 is the currently edited lock screen wallpaper file, which in this embodiment is the lock screen wallpaper file updated by the main functional module according to the relevant shape information after the user sets the shape of the decorative elements.
[0512] Step 3310: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0513] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 4.
[0514] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 4, and the user can continue to edit that lock screen wallpaper.
[0515] Figure 34 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 34 The flowchart shown illustrates the specific process by which users set depth-of-field effects based on the wallpaper editing interface. Figure 34The flowchart shown can be executed after step 2409; or, after step 2412, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 2907; or, after step 2910, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3007; or, after step 3010, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3107; or, after step 3110, when the user re-enters the wallpaper editing interface on the electronic device.
[0516] See Figure 34 The method may include the following steps:
[0517] Step 3401: The main functional module receives click operations on the depth-of-field effect control.
[0518] In some cases, if a user wants to set a depth-of-field effect in their lock screen wallpaper, then... Figure 13 As shown in (a), the user can click the depth-of-field effect control 75, and the main functional module will receive the click operation on the depth-of-field effect control 75.
[0519] Step 3402: In response to the click operation on the depth of field effect control, the main function module displays the fourth pop-up window.
[0520] For example, such as Figure 13 As shown in (b), the fourth pop-up window 7015 displays a depth-of-field effect switch 7151, and can further display a background blur control 7152.
[0521] Step 3403: The main functional module receives the operation to turn off the depth-of-field effect switch.
[0522] For example, such as Figure 13 As shown in (b), the user can turn off the depth-of-field effect switch by clicking the depth-of-field effect switch 7151, and the main function module will receive the turning-off operation of the depth-of-field effect switch 7151.
[0523] Step 3404: In response to the operation of turning off the depth-of-field effect switch, the main function module updates the state of the depth-of-field effect switch in the currently edited lock screen wallpaper file to the off state, obtains lock screen wallpaper file 5, and then re-acquires the layer of the clock layer and the layer of the cutout layer.
[0524] It should be noted that, if Figure 34The flowchart shown is executed after step 2609 above, or after step 2612, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 1. However, if... Figure 34 The flowchart shown is executed after step 3107 above, or after step 3110, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 2. However, if... Figure 34 The flowchart shown is executed after step 3207 above, or after step 3210, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 3. However, if... Figure 34 The flowchart shown is executed after step 3307 above, or after step 3310, when the user re-enters the wallpaper editing interface on the electronic device. In this case, the currently edited lock screen wallpaper file can be lock screen wallpaper file 4.
[0525] The main functional module can retrieve the levels of the clock layer and the cutout layer based on the lock screen wallpaper file 5. For example, if the depth-of-field effect is off in the lock screen wallpaper file 5, the main functional module can swap the levels of the clock layer and the cutout layer.
[0526] Generally, when the depth-of-field effect is turned on, the clock layer is at a lower level than the cutout layer, thus achieving a depth-of-field effect. When the depth-of-field effect is turned off, you can swap the levels of the clock layer and the cutout layer, making the clock layer higher than the cutout layer, thus turning off the depth-of-field effect.
[0527] Step 3405: The main functional module sends the view identifier and layer of the clock layer and the view identifier and layer of the cutout layer to the lock screen view module.
[0528] For example, suppose lock screen wallpaper file 1 is Figure 27 The JSON file shown indicates that the depth-of-field effect switch in lock screen wallpaper file 1 is in the "on" state. Therefore, based on lock screen wallpaper file 1, the clock layer's layer level is determined to be 5, and the cutout layer's layer level is 6. Subsequently, in response to the deactivation of the depth-of-field effect switch, the main functional module updates the depth-of-field effect switch status information in lock screen wallpaper file 1 to the "off" state. In this case, the main functional module can swap the previous layers of the clock layer and the cutout layer, resulting in the clock layer's layer level being 6 and the cutout layer's layer level being 5. Afterward, the main functional module can send the clock layer's layer level and the cutout layer's layer level to the lock screen view module.
[0529] Step 3406: After receiving the view identifier and level of the clock layer and the view identifier and level of the cutout layer, the lock screen view module resets the level of the view identified by the view identifier of the clock layer and the level of the view identified by the view identifier of the cutout layer, and displays m views.
[0530] For example, after resetting the hierarchy of the views identified by the view identifier of the clock layer and the hierarchy of the views identified by the view identifier of the cutout layer, the lock screen view module can submit the m views to the rendering service for rendering in ascending order of hierarchy. This allows the m views to be overlaid and displayed on the lock screen wallpaper page's display area, thus achieving the display of the wallpaper on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page can be... Figure 13 The lock screen wallpaper page 702 shown in (c) has no depth-of-field effect.
[0531] In some embodiments, after a user edits the lock screen wallpaper by turning off the depth-of-field effect switch, the user can also save the edited lock screen wallpaper to make it effective. This process may include the following steps 3407 to 3409.
[0532] Step 3407: The main functional module receives the click operation on the completion control.
[0533] For example, such as Figure 13 As shown in (c), after the user turns off the depth-of-field effect of the lock screen wallpaper, they can directly click the completion control 71 in the wallpaper editing interface 700, and the main functional module will receive the click operation on the completion control 71. Or, as... Figure 13 As shown in (c), after the user turns off the depth-of-field effect of the lock screen wallpaper, they can first click the folding control 7153 in the fourth pop-up window 7015, and then, as shown in (c), the user can ... Figure 13 As shown in (d), the user then clicks the completion control 71 in the wallpaper editing interface 700, and the main function module will receive the click operation on the completion control 71.
[0534] Step 3408: The main functional module sends a wallpaper file storage request to the file system.
[0535] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 5. Lock screen wallpaper file 5 is the currently edited lock screen wallpaper file, and in this embodiment, it is the lock screen wallpaper file updated by the main functional module according to the state of the depth effect switch after the user turns off the depth effect switch.
[0536] Step 3409: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0537] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 5.
[0538] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 5, and the user can continue to edit that lock screen wallpaper.
[0539] Figure 35 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 35 The flowchart shown illustrates the specific process by which users set the background blur based on the wallpaper editing interface. Figure 35 The flowchart shown can be executed after step 2609; or, after step 2612, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3107; or, after step 3110, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3207; or, after step 3210, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3307; or, after step 3310, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3406; or, after step 3409, when the user re-enters the wallpaper editing interface on the electronic device.
[0540] See Figure 35 The method may include the following steps:
[0541] Step 3501: The main functional module receives click operations on the depth-of-field effect control.
[0542] Step 3502: In response to the click operation on the depth of field effect control, the main function module displays a fourth pop-up window, which displays a background blur control.
[0543] Step 3503: The main functional module receives the trigger operation for the background blur control.
[0544] For example, such as Figure 13 As shown in (b), the background blur control 7152 can be a slider-type control with a slider in it. The position of the slider in the slider can indicate the corresponding blur (which can be called the target blur). Of course, the background blur control 7152 can also be other types of controls, and this application embodiment does not limit this.
[0545] The background blur control can be triggered by the user. That is, if a user wants to adjust the background blur, they can do so by manipulating the background blur control. For example, a user can drag... Figure 13 The slider in slider 7152 shown in (b) is used to adjust the position of the slider in the slider to set the background blur.
[0546] Step 3504: In response to the trigger operation of the background blur control, the main functional module determines the target blur.
[0547] Step 3505: The main functional module updates the blur information in the currently edited lock screen wallpaper file to the target blur, resulting in lock screen wallpaper file 6.
[0548] It should be noted that, if Figure 35 The flowchart shown is executed after step 2609 above, or after step 2612, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 1. However, if... Figure 35 The flowchart shown is executed after step 3107 above, or after step 3110, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 2. However, if... Figure 35 The flowchart shown is executed after step 3207 above, or after step 3210, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 3. However, if... Figure 35 The flowchart shown is executed after step 3307 above, or after step 3310, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 4. However, if... Figure 35 The flowchart shown is executed after step 3406 above, or after step 3409, when the user re-enters the wallpaper editing interface on the electronic device. In this case, the currently edited lock screen wallpaper file can be lock screen wallpaper file 5.
[0549] Step 3506: The main functional module sends the view identifier and target blur of the original layer to the lock screen view module.
[0550] Step 3507: After receiving the view identifier and target blur of the original layer, the lock screen view module redraws the layer content in the view identified by the view identifier of the original layer according to the target blur, and displays m views.
[0551] After receiving the view identifier and target blur of the original layer, the lock screen view module can redraw the layer content in the view based on the target blur while maintaining the layer hierarchy identified by the original layer's view identifier. Specifically, it can first blur the display image of the original layer according to the target blur, then determine the target area in the display image based on the scaling ratio and a specific offset of the original layer, and draw the image within the target area into the view. Afterwards, the lock screen view module can submit these m views to the rendering service for rendering in ascending order of layer hierarchy, so that the m views are overlaid on the display area of the lock screen wallpaper page on the screen, thus realizing the display of the wallpaper on the lock screen wallpaper page. In this case, the blur of the background part of the displayed wallpaper on the lock screen wallpaper page is the target blur set by the user.
[0552] In some embodiments, after a user edits the lock screen wallpaper using the background blur control, the user can save the edited lock screen wallpaper to make it effective. This process may include steps 3508 to 3510.
[0553] Step 3508: The main functional module receives the click operation on the completion control.
[0554] Step 3509: The main functional module sends a wallpaper file storage request to the file system.
[0555] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 6. Lock screen wallpaper file 6 is the currently edited lock screen wallpaper file, and in this embodiment, it is the lock screen wallpaper file updated by the main functional module according to the set target blur after the user sets the background blur.
[0556] Step 3510: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0557] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 6.
[0558] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 6, and the user can continue to edit that lock screen wallpaper.
[0559] Figure 36 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 36The flowchart shown illustrates the specific process of how users can zoom in and out on the main image of a wallpaper using the wallpaper editing interface. Figure 36 The flowchart shown can be executed after step 2609; or, after step 2612, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3107; or, after step 3110, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3207; or, after step 3210, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3307; or, after step 3310, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3406; or, after step 3409, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3507; or, after step 3510, when the user re-enters the wallpaper editing interface on the electronic device.
[0560] See Figure 36 The method may include the following steps:
[0561] Step 3601: The main functional module receives the zoom operation performed on the lock screen wallpaper page.
[0562] In some cases, if a user wants to zoom in on the main image of the lock screen wallpaper, then... Figure 15 As shown in (a) or (c), the user can perform a zoom operation on the lock screen wallpaper page 702, and the main function module will receive the zoom operation.
[0563] Step 3602: In response to the scaling operation, the main functional module determines the target scaling ratio and the target offset.
[0564] The target scaling factor is the scaling factor corresponding to this scaling operation. The target offset is obtained by dividing the offset corresponding to this scaling operation by the specific scaling factor.
[0565] For example, when the zoom operation is a two-finger zoom-in or two-finger zoom-out operation, the zoom ratio and offset corresponding to the zoom operation can be determined based on the sliding direction, sliding distance, sliding position, etc. of the two fingers.
[0566] Step 3603: The main functional module updates the scaling ratio in the scaling ratio information of the currently edited lock screen wallpaper file to the product of the scaling ratio and the target scaling ratio, and updates the offset in the offset information of the currently edited lock screen wallpaper file to the sum of the offset and the target offset, thus obtaining lock screen wallpaper file 7.
[0567] It should be noted that, if Figure 36 The flowchart shown is executed after step 2609 above, or after step 2612, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 1. However, if... Figure 36 The flowchart shown is executed after step 3107 above, or after step 3110, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 2. However, if... Figure 36 The flowchart shown is executed after step 3207 above, or after step 3210, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 3. However, if... Figure 36 The flowchart shown is executed after step 3307 above, or after step 3310, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 4. However, if... Figure 36 The flowchart shown is executed after step 3406 above, or after step 3409, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 5. However, if... Figure 36 The flowchart shown is executed after step 3507 above, or after step 3510, when the user re-enters the wallpaper editing interface on the electronic device. In this case, the currently edited lock screen wallpaper file can be lock screen wallpaper file 6.
[0568] Step 3604: The main functional module sends the view identifier of the original layer, the view identifier of the cut-out layer, the scaling ratio and the specific offset from the scaling ratio information in the lock screen wallpaper file 7 to the lock screen view module. The specific offset is obtained by multiplying the offset from the offset information in the lock screen wallpaper file 7 by the specific scaling ratio.
[0569] Step 3605: After receiving the view identifier of the original layer, the view identifier of the cut-out layer, the scaling ratio, and the specific offset, the lock screen view module redraws the layer content in the view identified by the view identifier of the original layer and the view content in the view identified by the view identifier of the cut-out layer according to the scaling ratio and the specific offset, and displays m views.
[0570] The lock screen view module can blur the original layer's display image based on its blur level while maintaining the layer's view identifier's hierarchy. Then, based on the scaling ratio and a specific offset, it determines the target area within the displayed image and draws the portion of the displayed image within that target area into the view. Similarly, the lock screen view module can also determine the target area within the cutout layer's display image based on the scaling ratio and a specific offset while maintaining the view's hierarchy.
[0571] Then, the lock screen view module can submit the m views to the rendering service for rendering in ascending order of hierarchy. These m views are then overlaid on the display area of the lock screen wallpaper page on the screen, thus displaying the wallpaper on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page could be... Figure 15 The lock screen wallpaper page 702 shown in (b) or (d) has its main image of the wallpaper enlarged or reduced accordingly.
[0572] It should be noted that the process of moving the main image of the lock screen wallpaper is similar to the process of scaling the main image of the lock screen wallpaper as described above, and will not be repeated in this embodiment.
[0573] In some embodiments, after a user edits the lock screen wallpaper by scaling or moving the main image, the user can save the edited lock screen wallpaper to make it effective. This process may include steps 3606 to 3608 as follows.
[0574] Step 3606: The main functional module receives click operations on the completion control.
[0575] For example, such as Figure 15 As shown in (b), (d), or (f), after zooming or moving the main image, the user can click the completion control 71 in the wallpaper editing interface 700, and the main function module will receive the click operation on the completion control 71.
[0576] Step 3607: The main functional module sends a wallpaper file storage request to the file system.
[0577] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 7. Lock screen wallpaper file 7 is the currently edited lock screen wallpaper file, and in this embodiment, it is the lock screen wallpaper file updated by the main functional module according to the relevant scaling ratio or offset after the user zooms or moves the main image.
[0578] Step 3608: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0579] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 7.
[0580] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 7, and the user can continue to edit that lock screen wallpaper.
[0581] It should be noted that the above is performed in the initial editing state. Figures 31 to 36 The system remains in the initial editing state even after performing the basic operations described above. Furthermore, even after changing the image in the initial editing state, the system remains in the initial editing state.
[0582] Figure 37 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 37 The flowchart shown illustrates the specific process of how a user changes the main image of the wallpaper based on the wallpaper editing interface. Figure 37 The flowchart shown can be executed after step 2609; or, after step 2612, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3107; or, after step 3110, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3207; or, after step 3210, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3307; or, after step 3310, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3406; or, after step 3409, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3507; or, after step 3510, when the user re-enters the wallpaper editing interface on the electronic device; or, after step 3605; or, after step 3608, when the user re-enters the wallpaper editing interface on the electronic device.
[0583] See Figure 37 The method may include the following steps:
[0584] Step 3701: The main functional module receives the click operation for changing the image control.
[0585] In some cases, if a user wants to change the main image of their lock screen wallpaper, then... Figure 14 As shown in (a), the user can click on the image change control 720, and the main functional module will receive the click operation on the image change control 720.
[0586] Step 3702: In response to the click operation on the image replacement control, the main function module displays the fifth pop-up window.
[0587] For example, such as Figure 14 As shown in (b) above, the fifth pop-up window 7201 displays the picture options in the gallery.
[0588] Step 3703: The main functional module receives the selection operation for image option 1.
[0589] For example, such as Figure 14 As shown in (b), the user can click on an image option (hereinafter referred to as image option 1) displayed in the fifth pop-up window 7201, and the main function module will receive the selection operation for image option 1.
[0590] Step 3704: In response to the selection operation of image option 1, the main function module obtains the image corresponding to image option 1 as the main image 1 and generates a cutout image 1 containing the foreground object in the main image 1.
[0591] Step 3705: The main functional module generates the first operation record. The first operation record is used to record the image replacement operation performed in the initial editing state, and records the main image 1 and the cutout image 1.
[0592] It should be noted that if a user changes the image in the initial editing state and then selects a different wallpaper template, the main function module can delete the first operation record.
[0593] Step 3706: The main function module re-obtains the display image of the original layer based on the main image 1, and re-obtains the display image of the cut-out layer based on the cut-out image 1.
[0594] For example, the operation of the main function module to re-obtain the display image of the original layer based on the main image 1 can be as follows: process the main image 1 to obtain the full-screen image of the original layer, and then scale the full-screen image of the original layer according to a specific scaling ratio to obtain the display image of the original layer.
[0595] For example, the main function module processes the main image 1 to obtain a full-screen image of the original layer as follows: The main function module determines an initial scaling ratio based on the screen size and the size of the main image 1, and scales the main image 1 according to this initial scaling ratio to obtain a full-screen image of the original layer. Specifically, this initial scaling ratio is used to process the main image 1 into a full-screen image. Specifically, the screen height can be divided by the height of the main image 1 to obtain a first value, and the screen width can be divided by the width of the main image 1 to obtain a second value. The larger of the first and second values is then used as the initial scaling ratio.
[0596] For example, the operation of the function cutout module to re-obtain the display image of the cutout layer based on the cutout image 1 can be as follows: process the cutout image 1 to obtain the full-screen image of the cutout layer, and then scale the full-screen image of the cutout layer according to a specific scaling ratio to obtain the display image of the cutout layer.
[0597] For example, the function of the cutout module processes the cutout image 1 to obtain a full-screen image of the cutout layer. The function can do this by: determining an initial scaling ratio based on the screen size and the size of the cutout image 1, and scaling the cutout image 1 according to this initial scaling ratio to obtain a full-screen image of the cutout layer. Specifically, this initial scaling ratio is used to process the cutout image 1 into a full-screen image. Specifically, the screen height can be divided by the height of the cutout image 1 to obtain a first value, and the screen width can be divided by the width of the cutout image 1 to obtain a second value. The larger of the first and second values is then used as the initial scaling ratio.
[0598] Step 3707: The main functional module sends the view identifier and display image of the original layer, as well as the view identifier and display image of the cut-out layer, to the lock screen view module.
[0599] In some embodiments, after performing an image replacement operation, the main functional module can set the offset information, scaling information, and blur information in the currently edited lock screen wallpaper file to their initial values. In other embodiments, after performing an image replacement operation, the main functional module can set the blur information in the currently edited lock screen wallpaper file to its initial value, and can set the offset information and scaling information in the currently edited lock screen wallpaper file according to the position of the foreground object in the main image 1, so that the foreground object can achieve a better display effect on the lock screen wallpaper page.
[0600] In some embodiments, for the offset information in the lock screen wallpaper file, the main functional module can multiply the offset in the offset information by a specific scaling ratio to obtain a specific offset. While sending the view identifier and display image of the original layer and the view identifier and display image of the cut-out layer to the lock screen view module, the main functional module can also send the specific offset, the scaling ratio in the scaling ratio information of the lock screen wallpaper file, and the blurriness in the blurriness information to the lock screen view module.
[0601] Step 3708: After receiving the view identifier and display image of the original layer and the view identifier and display image of the cutout layer, the lock screen view module redraws the layer content in the view identified by the view identifier of the original layer according to the display image of the original layer, and redraws the layer content in the view identified by the view identifier of the cutout layer according to the display image of the cutout layer, displaying m views.
[0602] After receiving the view identifier and display image of the original layer, the lock screen view module first blurs the display image based on the blur of the original layer while keeping the layer level of the view identified by the view identifier of the original layer unchanged. Then, it determines the target area in the display image based on the scaling ratio and specific offset of the original layer, and draws the image in the display image that is within the target area into the view.
[0603] After receiving the view identifier and display image of the cutout layer, the lock screen view module determines the target area in the display image based on the scaling ratio and specific offset of the cutout layer while keeping the layer level of the view identified by the view identifier of the cutout layer unchanged, and draws the image in the display image that is within the target area into the view.
[0604] Then, the lock screen view module can submit the m views to the rendering service for rendering in ascending order of hierarchy. These m views are then overlaid on the display area of the lock screen wallpaper page on the screen, thus displaying the wallpaper on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page could be... Figure 14 The lock screen wallpaper page 702 shown in (c) displays a wallpaper whose main image is a picture changed by the user.
[0605] In some embodiments, after a user edits the lock screen wallpaper by changing the main image, the user can also save the edited lock screen wallpaper to make it effective. This process may include the following steps 3709 to 3712.
[0606] Step 3709: The main functional module receives click operations on the completion control.
[0607] For example, such as Figure 14As shown in (c), after changing the main image, the user can click the completion control 71 in the wallpaper editing interface 700, and the main function module will receive the click operation on the completion control 71.
[0608] Step 3710: In the current initial editing state, the main function module stores the main image 1 and the cutout image 1 recorded in the first operation record to the file system, obtaining the storage path of the main image 1 and the storage path of the cutout image 1. It updates the image storage path in the layer basic information of the original layer in the currently edited lock screen wallpaper file to the storage path of the main image 1, and updates the image storage path in the layer basic information of the cutout layer in the currently edited lock screen wallpaper file to the storage path of the cutout image 1, thus obtaining lock screen wallpaper file 8.
[0609] It should be noted that, if Figure 37 The flowchart shown is executed after step 2609 above, or after step 2612, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 1. However, if... Figure 37 The flowchart shown is executed after step 3107 above, or after step 3110, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 2. However, if... Figure 37 The flowchart shown is executed after step 3207 above, or after step 3210, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 3. However, if... Figure 37 The flowchart shown is executed after step 3307 above, or after step 3310, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 4. However, if... Figure 37 The flowchart shown is executed after step 3406 above, or after step 3409, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 5. However, if... Figure 37 The flowchart shown is executed after step 3507 above, or after step 3510, when the user re-enters the wallpaper editing interface on the electronic device. Therefore, the currently edited lock screen wallpaper file can be lock screen wallpaper file 6. However, if... Figure 37 The flowchart shown is executed after step 3605 above, or after step 3608, when the user re-enters the wallpaper editing interface on the electronic device. In this case, the currently edited lock screen wallpaper file can be lock screen wallpaper file 7.
[0610] Step 3711: The main functional module sends a wallpaper file storage request to the file system.
[0611] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 8. Lock screen wallpaper file 8 is the currently edited lock screen wallpaper file, and in this embodiment, it is the lock screen wallpaper file updated by the main function module according to the changed main image after the user changes the main image.
[0612] Step 3712: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0613] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 8.
[0614] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, that is, the lock screen wallpaper corresponding to lock screen wallpaper file 8, and the user can continue to edit that lock screen wallpaper.
[0615] The following is combined Figures 38 to 40 The process of switching from the initial editing state to other editing states (such as engineering expansion editing state, AI expansion editing state, AI style editing state) is explained:
[0616] Figure 38 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 38 The flowchart shown illustrates the specific implementation process of users expanding wallpapers using the wallpaper editing interface. Figure 38 The flowchart shown can be found in the above text. Figure 26 In this embodiment, the process is executed after the user selects a wallpaper template, or it may be performed after the wallpaper on the lock screen wallpaper page has been modified as described above. Figures 31 to 37 Executed after one or more operations described in the embodiments.
[0617] See Figure 38 The method may include the following steps:
[0618] Step 3801: The main functional module receives the third gesture operation performed on the lock screen wallpaper page.
[0619] In some cases, if a user wants to engineer and expand the wallpaper on the lock screen, they can perform a third gesture operation on the lock screen wallpaper page.
[0620] The third gesture operation can be a predefined gesture operation. The third gesture operation is used to instruct on engineering expansion.
[0621] For example, the third gesture operation could be a two-finger zoom-out operation performed on the lock screen wallpaper page when the main image of the wallpaper can no longer be zoomed out. For instance, as shown... Figure 16 As shown in (a), the electronic device displays a lock screen wallpaper page 702. The main image of the wallpaper on the lock screen wallpaper page 702 can no longer be reduced. At this time, the user will trigger the engineering-style image enlargement function by performing a two-finger zoom operation on the lock screen wallpaper page 702.
[0622] For example, the third gesture operation could be a movement operation performed on the lock screen wallpaper page in the direction of the main image of the wallpaper, when the main image can no longer be moved in a certain direction. For instance, such as... Figure 18 As shown in (a), the electronic device displays a lock screen wallpaper page 702. The main image of the wallpaper on the lock screen wallpaper page 702 can no longer be moved down. At this time, when the user performs a downward movement operation on the lock screen wallpaper page 702, the engineering expansion function will be triggered.
[0623] Of course, it is not limited to this. The third gesture operation can also be other gesture operations, such as long press operation, double-click operation, S-shaped swipe operation, etc. This application embodiment does not limit this.
[0624] Step 3802: In response to the third gesture operation, the main functional module sends the lock screen wallpaper data in the initial editing state to the first cache management module and the second cache management module.
[0625] After receiving the third gesture, the main functional module determines that the engineering-style expanded image function has been triggered. At this point, the main functional module can confirm that an edit state switch has occurred, specifically a switch from the initial edit state to the engineering-style expanded image edit state. In this case, the main functional module can store the lock screen wallpaper data from the initial edit state in the first cache area through the first cache management module, and store the lock screen wallpaper data from the initial edit state in the second cache area through the second cache management module, so that it can be used for subsequent rollback and forward editing.
[0626] The lock screen wallpaper data in the initial editing state can include initial state data and initial image data. This initial state data can include wallpaper editing records and the lock screen wallpaper file edited in the initial editing state. The wallpaper editing records indicate the editing states generated during this editing process; here, the editing states generated in this process are sequentially: initial editing state. If a first operation record exists in the initial editing state, the initial image data can include the main image and the cutout image from the first operation record; if no first operation record exists in the initial editing state, the initial image data can be empty.
[0627] Step 3803: After receiving the lock screen wallpaper data in the initial editing state, the first cache management module stores the lock screen wallpaper data in the first cache area.
[0628] Step 3804: After receiving the lock screen wallpaper data in the initial editing state, the second cache management module stores the lock screen wallpaper data in the second cache area.
[0629] Step 3805: In response to the third gesture operation, the main functional module obtains the first target image based on the lock screen wallpaper data of the initial editing state. The first target image is the main image corresponding to the lock screen wallpaper data of the initial editing state.
[0630] The first target image is the one that requires engineering-level image expansion processing.
[0631] In some embodiments, the operation of the main functional module to obtain the first target image based on the lock screen wallpaper data in the initial editing state can be as follows: if the initial image data is empty, obtain the image as the first target image based on the image storage path in the layer basic information of the original layer in the lock screen wallpaper file in the initial state data; if the initial image data is not empty, use the main image in the initial image data as the first target image.
[0632] Step 3806: Construct the first callback function for the main functional module.
[0633] The first callback function is used to enable the engineering map expansion module to return the processing result after completing the engineering map expansion process.
[0634] Step 3807: Construct the engineering expansion module of the main functional module and initialize all nodes in the engineering expansion module.
[0635] Initializing all nodes in the engineering map expansion module is the process of setting up resources and configurations for each node in the engineering map expansion module. For example, the initialization process for each node may include one or more of the following: Loading the model: Loading a pre-trained image processing model for the node; Allocating memory: Allocating corresponding computing resources for the node; Setting input and output formats: Defining the image formats received and output by the node.
[0636] For example, the engineering map expansion module may include one or more of the following: decoding node, watermark removal node, engineering map expansion node, and image cutout node.
[0637] Step 3808: The main functional module sends the first callback function to the engineering drawing expansion module.
[0638] It should be noted that after step 3805, if the main functional module determines that the engineering expansion module has not been built in this editing process, the main functional module can execute steps 3806 to 3808; if after step 3805, the main functional module determines that the engineering expansion module has been built in this editing process, the main functional module does not need to execute steps 3806 to 3808, and can directly execute the following step 3809.
[0639] Step 3809: The main functional module sends the first target image to the engineering mapping module.
[0640] For example, the main functional module can call the relevant interfaces of the engineering map expansion module to send the first target image to the engineering map expansion module.
[0641] Step 3810: After receiving the first target image, the decoding node in the engineering map expansion module decodes the first target image to obtain the first decoded image.
[0642] Decoding refers to converting an image from its original encoding format (such as Joint Photographic Experts Group (JPEG), Portable Network Graphics (PNG), etc.) into a workable pixel data format.
[0643] During the decoding process, the encoded data of the image is restored to a pixel matrix. Each pixel in this matrix contains data information about color, brightness, and transparency. This data information may include color values or grayscale values of the red, green, and blue (RGB) channels, etc., but this embodiment does not limit the specific data.
[0644] For example, the decoding node can call the underlying interface to decode the first target image using a system-level image decoding library or a custom decoding algorithm to obtain the first decoded image.
[0645] In some embodiments, after decoding the first target image to obtain the first decoded image, the decoding node can store the association between the image identifier of the first target image and the first decoded image.
[0646] Step 3811: The decoding node sends the first decoded image to the watermark removal node.
[0647] Step 3812: After receiving the first decoded image, the watermark removal node removes the watermark information from the first decoded image to obtain the first watermark-free image.
[0648] Watermarks are typically used to identify the owner of an image. Watermarks can be in the form of text or images.
[0649] To improve the wallpaper display effect, in this embodiment of the application, when performing engineering image expansion, the watermark in the original image can be removed first, and then the subsequent image expansion processing can be performed.
[0650] In some embodiments, the operation of removing watermark information from the first decoded image by removing watermark nodes can be as follows: determining the target position in the first decoded image, where the target position is the location of the watermark; deleting the pixels at the target position in the first decoded image; and filling the target position in the first decoded image with pixels using an image content filling algorithm to obtain the first watermark-free image.
[0651] In some embodiments, the operation of removing watermark nodes to determine the target location in the first decoded image can be: identifying the target location from the first decoded image based on watermark feature data in the database.
[0652] The database can pre-store some watermark feature data. By matching this feature data with the first decoded image, the location of the watermark in the first decoded image can be found. For example, the watermark removal node can first construct a database connection instance to retrieve the watermark feature data from the database through this database connection instance. Optionally, the watermark removal node can cache the database connection instance after construction for future use.
[0653] Of course, this is not the only way. The target position in the first decoded image can also be determined by other means, such as by image recognition algorithms, neural network models, etc. The embodiments of this application do not limit this.
[0654] Image content filling algorithms can be pre-configured. For example, an image content filling algorithm can fill pixels at a target location based on pixels surrounding the target location in a first decoded image, so that the filled pixel area is continuous and transitions naturally with the content of the surrounding pixel area, thereby maintaining the integrity and aesthetics of the image.
[0655] In some embodiments, after the watermark removal node removes the watermark information from the first decoded image to obtain the first dewatermarked image, the association between the image identifier of the first decoded image and the first dewatermarked image can be stored.
[0656] Step 3813: The watermark removal node sends the first watermark-removed image to the engineering map expansion node.
[0657] Step 3814: After receiving the first watermark-free image, the engineering-enlargement node performs engineering-enlargement processing on the first watermark-free image to obtain the first enlarged image.
[0658] In some embodiments, the operation of the engineered image expansion node in performing engineered image expansion processing on the first watermark-free image can be as follows: initializing engineered image expansion algorithm resources, constructing an engineered image expansion algorithm instance, and processing the first watermark-free image using the engineered image expansion algorithm instance to obtain the first expanded image. Optionally, the engineered image expansion node can cache the engineered image expansion algorithm instance after construction for future use.
[0659] In some embodiments, the engineered image expansion node performs engineered image expansion processing on the first watermark-removed image to obtain the first expanded image, and can store the association between the image identifier of the first watermark-removed image and the first expanded image.
[0660] Step 3815: The engineering-based image expansion node sends the first expanded image to the image cutout node.
[0661] Step 3816: After receiving the first expanded image, the cutout node performs cutout processing on the first expanded image to obtain the first cutout image.
[0662] The first cutout image contains the foreground object from the first expanded image.
[0663] In some embodiments, the operation of the matting node in processing the first expanded image can be: initializing matting algorithm resources, constructing a matting algorithm instance, and processing the first expanded image using the matting algorithm instance to obtain the first matted image. Optionally, the matting node can cache the matting algorithm instance after construction for future use.
[0664] In some embodiments, the cutout node performs cutout processing on the first expanded image to obtain the first cutout image, and can store the association between the image identifier of the first expanded image and the first cutout image.
[0665] In some embodiments, the cutout node can also obtain the position of the foreground object in the first expanded image and send it to the main functional module through the engineered expanded image node, the watermark removal node, and the decoding node. The main functional module can use this as the position for secondary image composition, that is, as the basis for adjusting the offset and scaling ratio in the lock screen wallpaper file.
[0666] Step 3817: The cutout node sends the first cutout image to the engineering expansion node.
[0667] For example, the cutout node can call the relevant callback function to send the first cutout image to the engineered expansion node.
[0668] Step 3818: After receiving the first cutout image, the engineering expansion node sends the first expansion image and the first cutout image to the watermark removal node.
[0669] For example, an engineered image expansion node can call relevant callback functions to send the first expanded image and the first cutout image to the watermark removal node.
[0670] Step 3819: After receiving the first expanded image and the first cutout image, the watermark removal node sends the first expanded image and the first cutout image to the decoding node.
[0671] For example, the watermark removal node can call the relevant callback function to send the first expanded image and the first cutout image to the decoding node.
[0672] Step 3820: After receiving the first expanded image and the first cutout image, the decoding node calls the first callback function to send the first expanded image and the first cutout image to the main functional module.
[0673] Step 3821: After receiving the first expanded image and the first cutout image, the main functional module generates a second operation record. The second operation record is used to record the main image 2 and the cutout image 2 in the engineering expanded image editing state.
[0674] The main image 2 in the second operation record is the first expanded image, and the cutout image 2 in the second operation record is the first cutout image.
[0675] It should be noted that after switching from the initial editing state to the engineering expanded image editing state, the lock screen wallpaper file edited in the initial editing state is the lock screen wallpaper file currently being edited in the engineering expanded image editing state.
[0676] Step 3822: The main function module re-obtains the display image of the original layer based on the main image 2, and re-obtains the display image of the cut-out layer based on the cut-out image 2.
[0677] The operation of step 3822 is similar to the operation of step 3706 above, and will not be described again in this embodiment.
[0678] Step 3823: The main functional module sends the view identifier and display image of the original layer, as well as the view identifier and display image of the cut-out layer, to the lock screen view module.
[0679] In some embodiments, after the main functional module receives the first expanded image and the first cutout image, it can keep the offset information, scaling information and blur information in the currently edited lock screen wallpaper file unchanged.
[0680] In other embodiments, after receiving the first expanded image and the first cutout image, the main functional module can set the offset information, scaling information and blur information in the currently edited lock screen wallpaper file to their initial values.
[0681] In other embodiments, after receiving the first expanded image and the first cutout image, the main functional module can keep the blur information in the currently edited lock screen wallpaper file unchanged or set the blur information in the currently edited lock screen wallpaper file to the initial value. In addition, it can set the offset information and scaling ratio information in the currently edited lock screen wallpaper file according to the position of the foreground object in the main image 2, so that the foreground object can achieve a better display effect on the lock screen wallpaper page.
[0682] As an example, for the offset information in the lock screen wallpaper file, the main functional module can multiply the offset in the offset information by a specific scaling ratio to obtain the specific offset. While sending the view identifier and display image of the original layer and the view identifier and display image of the cut-out layer to the lock screen view module, the main functional module can also send the specific offset, the scaling ratio from the scaling ratio information in the lock screen wallpaper file, and the blurriness from the blurriness information to the lock screen view module.
[0683] Step 3824: After receiving the view identifier and display image of the original layer and the view identifier and display image of the cutout layer, the lock screen view module redraws the layer content in the view identified by the view identifier of the original layer according to the display image of the original layer, and redraws the layer content in the view identified by the view identifier of the cutout layer according to the display image of the cutout layer, displaying m views.
[0684] The operation of step 3824 is similar to that of step 3708 above, and will not be described again in this embodiment.
[0685] The lock screen view module displays these m views, thus enabling the wallpaper to be displayed on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page could be... Figure 16 The lock screen wallpaper page 702 shown in (b) is a wallpaper obtained through engineered image expansion.
[0686] It should be noted that after the wallpaper, which has undergone engineering-grade image expansion, is displayed on the lock screen wallpaper page, users can still perform basic operations on the wallpaper in the engineering-grade image expansion editing mode. For example, they can adjust the clock, decorations, and depth-of-field effects in the wallpaper, or scale, move, and blur the main image in the wallpaper. The specific process is the same as described above. Figures 31 to 36 The process described in the embodiments is similar, and will not be repeated in the embodiments of this application.
[0687] Another point to note is that if a user changes an image while in the engineered image expansion editing mode, it will trigger a switch to the initial editing mode. The specific process of changing an image while in the engineered image expansion editing mode is the same as described above. Figure 37The process described in the embodiments is similar, and will not be repeated in the embodiments of this application.
[0688] In some embodiments, after a user edits the lock screen wallpaper through engineering expansion, the user can save the edited lock screen wallpaper to make it effective. This process may include steps 3825 to 3830 as follows.
[0689] Step 3825: The main functional module receives the click operation on the completion control.
[0690] For example, such as Figure 16 As shown in (b), after the user completes the engineering expansion, they can click the completion control 71 in the wallpaper editing interface 700, and the main functional module will receive the click operation on the completion control 71.
[0691] Step 3826: In response to the click operation on the completion control, while the current state is in the engineering expansion editing state, the main functional module sends a persistent message to the second cache management module, and stores the lock screen wallpaper data in the engineering expansion editing state to the target storage area through the persistent management module.
[0692] The lock screen wallpaper data in the engineered image expansion editing state can include engineered image expansion state data and engineered image expansion image data. The engineered image expansion state data can include wallpaper editing records and the lock screen wallpaper file edited in the engineered image expansion editing state. Here, the wallpaper editing records indicate the editing states generated during this editing process, sequentially: initial editing state and engineered image expansion editing state. The engineered image expansion image data can include the main image and the cutout image from the second operation record.
[0693] This persistence message indicates that the lock screen wallpaper data from the edit states preceding the engineered expansion edit state should be persistently stored. Since this wallpaper editing record indicates that the edit states generated during this editing process are sequentially: initial edit state and engineered expansion edit state, this wallpaper completion message indicates that the lock screen wallpaper data from the initial edit state should be persistently stored.
[0694] Step 3827: After receiving the persistence message, the second cache management module stores the lock screen wallpaper data in the initial edit state stored in the second cache area to the target storage area through the persistence management module.
[0695] Since both the second cache area and the target storage area are located in the target memory, the lock screen wallpaper data in the initial editing state is moved from the second cache area in the target memory to the target storage area. Compared with the operation of storing data in memory to the target storage area, the operation of moving data from the second cache area to the target storage area can save processing resources and improve processing speed.
[0696] Thus, after the wallpaper editing is completed, the target storage area stores the lock screen wallpaper data of various editing states generated during this editing process. This area stores the lock screen wallpaper data of the initial editing state and the lock screen wallpaper data of the engineered expanded image editing state.
[0697] Step 3828: In response to the click operation on the completion control, while currently in the engineering expansion editing state, the main function module stores the main image 2 and the cutout image 2 recorded in the second operation record to the file system, obtaining the storage path of the main image 2 and the storage path of the cutout image 2. It updates the image storage path in the layer basic information of the original layer in the currently edited lock screen wallpaper file to the storage path of the main image 2, and updates the image storage path in the layer basic information of the cutout layer in the currently edited lock screen wallpaper file to the storage path of the cutout image 2, thus obtaining the lock screen wallpaper file 9.
[0698] Step 3829: The main functional module sends a wallpaper file storage request to the file system.
[0699] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 9. Lock screen wallpaper file 9 is the currently edited lock screen wallpaper file, and in this embodiment, it is the lock screen wallpaper file updated by the main functional module based on the main image obtained after the user performs engineering image expansion.
[0700] Step 3830: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0701] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 9.
[0702] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, i.e., the lock screen wallpaper corresponding to lock screen wallpaper file 9, and the user can continue to edit that lock screen wallpaper.
[0703] Figure 39 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 39 The flowchart shown illustrates the specific process of AI-powered image expansion based on the wallpaper editing interface. Figure 39 The flowchart shown can be found in the above text. Figure 26 In this embodiment, the process is executed after the user selects a wallpaper template, or it may be performed after the wallpaper on the lock screen wallpaper page has been modified as described above. Figures 31 to 37The above-described operations are performed after one or more of the operations described in the embodiments, or they may be performed after the wallpaper on the lock screen wallpaper page has been modified as described above. Figure 38 The engineering drawing expansion process described in the example is executed afterward.
[0704] See Figure 39 The method may include the following steps:
[0705] Step 3901: The main functional module receives click operations on the AI map expansion control.
[0706] In some cases, if a user wants to AI-enlarge the wallpaper on the lock screen, then... Figure 16 As shown in (b), users can click on the AI map expansion control 730, and the main functional module will receive the click operation on the AI map expansion control 730.
[0707] Step 3902: In response to the click operation of the AI expansion control, the main functional module sends the lock screen wallpaper data in the engineering expansion editing state to the first cache management module and the second cache management module.
[0708] After receiving a click on the AI image expansion control, the main functional module determines that the AI image expansion function has been triggered. At this point, the main functional module can confirm that an editing state switch has occurred; let's assume it's a switch from the engineering-based image expansion editing state to the AI image expansion editing state. In this case, the main functional module can store the lock screen wallpaper data from the engineering-based image expansion editing state to the first cache area via the first cache management module, and store the lock screen wallpaper data from the engineering-based image expansion editing state to the second cache area via the second cache management module, so that it can be used for subsequent rollback and forward editing.
[0709] The lock screen wallpaper data in the engineered image expansion editing state can include engineered image expansion state data and engineered image expansion image data. The engineered image expansion state data can include wallpaper editing records and the lock screen wallpaper file edited in the engineered image expansion editing state. Here, the wallpaper editing records indicate the editing states generated during this editing process, sequentially: initial editing state and engineered image expansion editing state. The engineered image expansion image data can include the main image and the cutout image from the second operation record.
[0710] Step 3903: After receiving the lock screen wallpaper data in the engineered expanded image editing state, the first cache management module stores the lock screen wallpaper data in the first cache area.
[0711] Step 3904: After receiving the lock screen wallpaper data in the engineered expanded image editing state, the second cache management module stores the lock screen wallpaper data in the second cache area.
[0712] Step 3905: In response to the click operation of the AI expansion control, the main functional module obtains the second target image based on the lock screen wallpaper data in the engineered expansion editing state. The second target image is the main image corresponding to the lock screen wallpaper data in the engineered expansion editing state.
[0713] The second target image is the image that needs to undergo AI image enlargement processing.
[0714] In some embodiments, the operation of the main functional module to obtain the second target image based on the lock screen wallpaper data in the engineered expanded image editing state can be: using the main image in the engineered expanded image data as the second target image.
[0715] Step 3906: The main functional module constructs the second callback function.
[0716] The second callback function is used to enable the AI image expansion module to return the processing result after completing the AI image expansion process.
[0717] Step 3907: The main functional module constructs the AI map expansion module and initializes all nodes in the AI map expansion module.
[0718] The operation of step 3907 is similar to that of step 3807 above, and will not be described again in this embodiment.
[0719] For example, the AI image expansion module may include one or more of the following: decoding node, watermark removal node, AI image expansion node, and image cutout node.
[0720] Step 3908: The main functional module sends the second callback function to the AI map expansion module.
[0721] It should be noted that after step 3905, if the main functional module determines that the AI map expansion module has not been built in this editing process, the main functional module can execute steps 3906 to 3908; if after step 3905, the main functional module determines that the AI map expansion module has been built in this editing process, the main functional module does not need to execute steps 3906 to 3908, and can directly execute the following step 3909.
[0722] Step 3909: The main functional module sends the second target image to the AI image expansion module.
[0723] The operation of step 3909 is similar to that of step 3809 above, and will not be described again in this embodiment.
[0724] Step 3910: After receiving the second target image, the decoding node in the AI image expansion module decodes the second target image to obtain the second decoded image.
[0725] The operation of step 3910 is similar to that of step 3810 above, and will not be described again in this embodiment.
[0726] Step 3911: The decoding node sends the second decoded image to the watermark removal node.
[0727] Step 3912: After receiving the second decoded image, the watermark removal node removes the watermark information from the second decoded image to obtain the second watermark-free image.
[0728] The operation of step 3912 is similar to that of step 3812 above, and will not be described again in this embodiment.
[0729] Step 3913: The watermark removal node sends the second watermark-removed image to the AI image expansion node.
[0730] Step 3914: After receiving the second watermark-free image, the AI image expansion node performs AI image expansion processing on the second watermark-free image to obtain the second expanded image.
[0731] In some embodiments, the operation of the AI image expansion node in processing the second watermark-free image using AI image expansion can be as follows: initializing AI image expansion algorithm resources, constructing an AI image expansion algorithm instance, and processing the second watermark-free image using the AI image expansion algorithm instance to obtain the second expanded image. Optionally, the AI image expansion node can cache the AI image expansion algorithm instance after construction for future use.
[0732] For example, this AI image augmentation algorithm instance can send a second watermark-free image to a server, where the server performs AI image augmentation processing on the second watermark-free image to obtain a second augmented image and returns it. The server can perform image augmentation processing on the second watermark-free image using AI technologies (such as neural network models).
[0733] In some embodiments, the AI image expansion node performs AI image expansion processing on the second watermark-free image to obtain the second expanded image, and can store the association between the image identifier of the second watermark-free image and the second expanded image.
[0734] Step 3915: The AI image expansion node sends the second expanded image to the image cutout node.
[0735] Step 3916: After receiving the second expanded image, the cutout node performs cutout processing on the second expanded image to obtain the second cutout image.
[0736] The second cutout image contains the foreground object from the second expanded image.
[0737] The operation of step 3916 is similar to that of step 3816 above, and will not be described again in this embodiment.
[0738] Step 3917: The cutout node sends the second cutout image to the AI expansion node.
[0739] The operation of step 3917 is similar to that of step 3817 above, and will not be described again in this embodiment.
[0740] Step 3918: After receiving the second cutout image, the AI image expansion node sends the second expanded image and the second cutout image to the watermark removal node.
[0741] The operation of step 3918 is similar to that of step 3818 above, and will not be described again in this embodiment.
[0742] Step 3919: After receiving the second expanded image and the second cutout image, the watermark removal node sends the second expanded image and the second cutout image to the decoding node.
[0743] The operation of step 3919 is similar to that of step 3819 above, and will not be described again in this embodiment.
[0744] Step 3920: After receiving the second expanded image and the second cutout image, the decoding node calls the second callback function to send the second expanded image and the second cutout image to the main functional module.
[0745] Step 3921: After receiving the second expanded image and the second cutout image, the main functional module generates a third operation record. The third operation record is used to record the main image 3 and the cutout image 3 in the AI expanded image editing state.
[0746] The main image 3 in the third operation record is the second expanded image, and the cutout image 3 in the third operation record is the second cutout image.
[0747] It should be noted that after switching from the engineering-style expandable editing mode to the AI-style expandable editing mode, the lock screen wallpaper file edited in the engineering-style expandable editing mode will be the same as the lock screen wallpaper file currently being edited in the AI-style expandable editing mode.
[0748] Step 3922: The main function module re-obtains the display image of the original layer based on the main image 3, and re-obtains the display image of the cut-out layer based on the cut-out image 3.
[0749] The operation of step 3922 is similar to that of step 3822 above, and will not be described again in this embodiment.
[0750] Step 3923: The main functional module sends the view identifier and display image of the original layer, as well as the view identifier and display image of the cut-out layer, to the lock screen view module.
[0751] The operation of step 3923 is similar to that of step 3823 above, and will not be described again in this embodiment.
[0752] Step 3924: After receiving the view identifier and display image of the original layer and the view identifier and display image of the cutout layer, the lock screen view module redraws the layer content in the view identified by the view identifier of the original layer according to the display image of the original layer, and redraws the layer content in the view identified by the view identifier of the cutout layer according to the display image of the cutout layer, displaying m views.
[0753] The operation of step 3924 is similar to that of step 3824 above, and will not be described again in this embodiment.
[0754] The lock screen view module displays these m views, thus enabling the wallpaper to be displayed on the lock screen wallpaper page. For example, the displayed lock screen wallpaper page could be... Figure 16 The lock screen wallpaper page 702 shown in (d) is a wallpaper obtained through AI image enlargement processing.
[0755] It should be noted that after the AI-processed wallpaper is displayed on the lock screen wallpaper page, users can still perform basic operations on the AI-processed wallpaper in edit mode. For example, they can adjust the clock, decorations, and depth-of-field effects, or scale, move, and blur the main image. The specific process is the same as described above. Figures 31 to 36 The process described in the embodiments is similar, and will not be repeated in the embodiments of this application.
[0756] Another point to note is that if a user changes an image while in AI image expansion editing mode, it will trigger a switch to the initial editing mode. The specific process of changing an image while in AI image expansion editing mode is the same as described above. Figure 37 The process described in the embodiments is similar, and will not be repeated in the embodiments of this application.
[0757] In some embodiments, after a user edits the lock screen wallpaper using AI image expansion, the user can save the edited lock screen wallpaper to make it effective. This process may include steps 3925 to 3930 below.
[0758] Step 3925: The main functional module receives the click operation on the completion control.
[0759] For example, such as Figure 16 As shown in (d), after the user completes the AI image expansion, they can click the completion control 71 in the wallpaper editing interface 700, and the main functional module will receive the click operation on the completion control 71.
[0760] Step 3926: In response to the click operation on the completion control, while the current state is AI expanded image editing, the main function module sends a persistent message to the second cache management module, and stores the lock screen wallpaper data of the AI expanded image editing state to the target storage area through the persistent management module.
[0761] The lock screen wallpaper data in the AI-enlarged image editing state can include AI-enlarged image state data and AI-enlarged image data. The AI-enlarged image state data can include wallpaper editing records and the lock screen wallpaper file edited in the AI-enlarged image editing state. Here, the wallpaper editing records indicate the editing states generated during this editing process, sequentially: initial editing state, engineered image enlargement editing state, and AI-enlarged image editing state. The AI-enlarged image data can include the main image and the cutout image from the third operation record.
[0762] This persistence message instructs that the lock screen wallpaper data from the previous edit states (before the AI-enlarged image editing state) be persistently stored. Since this wallpaper editing record indicates that the edit states generated during this editing process are sequentially: initial edit state, engineered image enlargement edit state, and AI-enlarged image editing state, this wallpaper completion message instructs that the lock screen wallpaper data from both the initial edit state and the engineered image enlargement edit state be persistently stored.
[0763] Step 3927: After receiving the persistence message, the second cache management module stores the lock screen wallpaper data in the initial editing state and the lock screen wallpaper data in the engineered expanded image editing state stored in the second cache area to the target storage area through the persistence management module.
[0764] Since both the second cache area and the target storage area are located in the target memory, the lock screen wallpaper data of the initial editing state and the engineered expanded image editing state are moved from the second cache area in the target memory to the target storage area. Compared with the operation of storing data in memory to the target storage area, the operation of moving data from the second cache area to the target storage area can save processing resources and improve processing speed.
[0765] Thus, after the wallpaper editing is completed, the target storage area stores lock screen wallpaper data in various editing states generated during this editing process. This area stores lock screen wallpaper data in the initial editing state, lock screen wallpaper data in the engineered expanded image editing state, and lock screen wallpaper data in the AI expanded image editing state.
[0766] Step 3928: In response to the click operation on the completion control, while currently in the AI image expansion editing state, the main function module stores the main image 3 and the cutout image 3 recorded in the third operation record to the file system, obtaining the storage path of the main image 3 and the storage path of the cutout image 3. The image storage path in the layer basic information of the original layer in the currently edited lock screen wallpaper file is updated to the storage path of the main image 3, and the image storage path in the layer basic information of the cutout layer in the currently edited lock screen wallpaper file is updated to the storage path of the cutout image 3, resulting in lock screen wallpaper file 10.
[0767] Step 3929: The main functional module sends a wallpaper file storage request to the file system.
[0768] The wallpaper file storage request is used to request the storage of lock screen wallpaper file 10. Lock screen wallpaper file 10 is the currently edited lock screen wallpaper file, and in this embodiment, it is the lock screen wallpaper file updated by the main module based on the main image obtained by the AI image expansion after the user performs AI image expansion.
[0769] Step 3930: After receiving the wallpaper file storage request, the file system updates the lock screen wallpaper file.
[0770] For example, the file system can update the first file of the lock screen wallpaper to lock screen wallpaper file 10.
[0771] It should be noted that after a user saves an edited lock screen wallpaper, the lock screen application can display that wallpaper on the lock screen interface. In this case, if the user wants to edit the lock screen wallpaper again while using the electronic device, they can re-enter the wallpaper editing interface. At this time, the wallpaper editing interface will display the previously edited lock screen wallpaper, that is, the lock screen wallpaper corresponding to lock screen wallpaper file 10, and the user can continue to edit that lock screen wallpaper.
[0772] Figure 40 This is a flowchart of a wallpaper editing method provided in an embodiment of this application. Figure 40 The flowchart shown illustrates the specific implementation process of AI stylization based on the wallpaper editing interface. Figure 40 The flowchart shown can be found in the above text. Figure 26 In this embodiment, the process is executed after the user selects a wallpaper template, or it may be performed after the wallpaper on the lock screen wallpaper page has been modified as described above. Figures 31 to 37 The above-described operations are performed after one or more of the operations described in the embodiments, or they may be performed after the wallpaper on the lock screen wallpaper page has been modified as described above. Figure 38 The engineering-based image expansion processing described in the embodiment is executed afterward, or it can be performed after the wallpaper on the lock screen wallpaper page has been processed as described above. Figure 39 The AI image expansion process described in the example is executed afterward.
[0773] See Figure 40 The method may include the following steps:
[0774] Step 4001: The main functional module receives click operations on the AI-style control.
[0775] In some cases, if a user wants to AI-stylize the wallpaper on the lock screen, then... Figure 17 As shown in (a), users can click on the AI style control 73, and the main functional module will receive the click operation on the AI style control 73.
[0776] Step 4002: In response to a click on the AI-style control, the main functional module displays the sixth pop-up window.
[0777] For example, such as Figure 17 As shown in (b), the sixth pop-up window 7013 displays multiple style options and a confirmation generation control 731.
[0778] Step 4003: The main functional module receives the selection operation for style option 1.
[0779] For example, such as Figure 17 As shown in (b), after the user clicks on a style option (hereinafter referred to as style option 1) displayed in the sixth pop-up window 7013, the main functional module will receive the selection operation for style option 1.
[0780] Step 4004: The main functional module receives the click operation for the confirmation generation control.
[0781] For example, such as Figure 17 As shown in (c), after the user clicks the confirmation generation control 731 displayed in the sixth pop-up window 7013, the main functional module will receive the click operation on the confirmation generation control 731.
[0782] Step 4005: In response to the click operation of the confirmation generation control, the main functional module sends the lock screen wallpaper data in AI expanded image editing state to the first cache management module and the second cache management module.
[0783] After receiving a click on the AI-style control, the main functional module determines that the AI stylization function has been triggered. At this point, the main functional module can confirm that an editing state switch has occurred; let's assume it's a switch from AI expanded image editing state to AI style editing state. In this case, the main functional module can store the lock screen wallpaper data from the AI expanded image editing state to the first cache area via the first cache management module, and store the lock screen wallpaper data from the AI expanded image editing state to the second cache area via the second cache management module, so that it can be used for subsequent rollback and forward editing.
[0784] The lock screen wallpaper data in the AI-enlarged image editing state can include AI-enlarged image state data and AI-enlarged image data. The AI-enlarged image state data can include wallpaper editing records and the lock screen wallpaper file edited in the AI-enlarged image editing state. Here, the wallpaper editing records indicate the editing states generated during this editing process, sequentially: initial editing state, engineered image enlargement editing state, and AI-enlarged image editing state. The AI-enlarged image data can include the main image and the cutout image from the third operation record.
[0785] Step 4006: After receiving the lock screen wallpaper data in AI expanded image editing mode, the first cache management module stores the lock screen wallpaper data in AI expanded image editing mode in the first cache area.
[0786] Step 4007: After receiving the lock screen wallpaper data in AI expanded image editing mode, the second cache management module stores the lock screen wallpaper data in AI expanded image editing mode in the second cache area.
[0787] Step 4008: In response to the click operation of the confirmation generation control, the main functional module obtains the AI style parameters.
[0788] The AI style parameters may include the third target image and the style identifier corresponding to style option 1. Optionally, the AI style parameters may also include the screen size.
[0789] The third target image is the main image corresponding to the lock screen wallpaper data in the AI expanded image editing state. The third target image is the image that needs to undergo AI stylization processing. For example, the main function module can use the main image from the AI expanded image data as the third target image.
[0790] Step 4009: The main functional module constructs the third callback function.
[0791] The third callback function is used to enable the AI stylization module to return the processing result after completing the AI stylization process.
[0792] Step 4010: The main functional module constructs the AI stylization module and initializes all nodes in the AI stylization module.
[0793] The operation of step 4010 is similar to that of step 3807 above, and will not be described again in this embodiment.
[0794] For example, the AI stylization module may include one or more of the following: decoding node, region cropping node, AI stylization node, and image matting node.
[0795] Step 4011: The main functional module sends the third callback function to the AI stylization module.
[0796] It should be noted that after step 4008, if the main functional module determines that the AI stylization module has not been built in this editing process, the main functional module can execute steps 4009 to 4011; if after step 4008, the main functional module determines that the AI stylization module has been built in this editing process, the main functional module does not need to execute steps 4009 to 4011, and can directly execute the following step 4012.
[0797] Step 4012: The main functional module sends AI style parameters to the AI stylization module.
[0798] For example, the main functional module can call the relevant interfaces of the AI stylization module to send AI style parameters to the AI stylization module.
[0799] Step 4013: After receiving the AI style parameters, the decoding node in the AI stylization module decodes the third target image to obtain the third decoded image.
[0800] The operation of step 4013 is similar to that of step 3810 above, and will not be described again in this embodiment.
[0801] Step 4014: The decoding node sends the third decoded image, style identifier, and screen size to the region clipping node.
[0802] Step 4015: After receiving the third decoded image, style identifier, and screen size, the region cropping node crops the third decoded image according to the screen size to obtain the cropped image.
[0803] The cropped image is the same size as the screen.
[0804] In some embodiments, the region cropping node can crop the third decoded image based on the screen size and the image content displayed on the current lock screen wallpaper page to obtain a cropped image. In this case, the image content of the cropped image is the same as the image content displayed on the lock screen wallpaper page when the user triggers the AI stylization function.
[0805] In other embodiments, the region cropping node can crop the third decoded image based on the screen size and the position of the foreground object in the third decoded image to obtain a cropped image. In this case, the cropped image includes the foreground object from the third decoded image.
[0806] In this embodiment of the application, by cropping the third decoded image, it is possible to process only the user-visible area of the original image during AI stylization, without processing all areas of the original image. This saves processing resources and improves processing speed.
[0807] In some embodiments, the region cropping node crops the third decoded image according to the screen size. After obtaining the cropped image, the association between the image identifier of the third decoded image and the cropped image can be stored.
[0808] Step 4016: The region cropping node sends the style identifier and the cropped image to the AI stylization node.
[0809] Step 4017: After receiving the style identifier and the cropped image, the AI stylization node performs AI stylization processing on the cropped image according to the style identifier to obtain an AI styled image.
[0810] In some embodiments, the operation of the AI stylization node in performing AI stylization processing on the cropped image based on the style identifier can be as follows: initializing AI stylization algorithm resources, constructing an AI stylization algorithm instance, and performing AI stylization processing on the cropped image corresponding to the style identifier using the AI stylization algorithm instance to obtain an AI-styled image. Optionally, the AI stylization node can cache the AI stylization algorithm instance after construction for future use.
[0811] For example, this AI stylization algorithm instance can send the style identifier and the cropped image to the server, which then performs AI stylization processing on the cropped image corresponding to the style identifier, obtaining an AI-styled image and returning it. The server can perform AI stylization processing on the cropped image using AI technologies (such as neural network models).
[0812] In some embodiments, the AI stylization node performs AI stylization processing on the cropped image based on the style identifier. After obtaining the AI style image, it can store the association between the image identifier of the cropped image and the AI style image.
[0813] Step 4018: The AI stylization node sends the AI-styled image to the cutout node.
[0814] Step 4019: After receiving the AI-style image, the cutout node performs cutout processing on the AI-style image to obtain the third cutout image.
[0815] The third cutout image contains foreground objects from the AI-style image.
[0816] In some embodiments, the operation of the matting node in processing the AI-style image can be as follows: initializing matting algorithm resources, constructing a matting algorithm instance, and processing the AI-style image using the matting algorithm instance to obtain a third matted image. Optionally, the matting node can cache the matting algorithm instance after construction for future use.
[0817] In some embodiments, after the cutout node performs cutout processing on the AI-style image to obtain a third cutout image, it can store the association between the image identifier of the AI-style image and the third cutout image.
[0818] As an example, the AI stylization module may not include a region cropping node. In this case, after the decoding node obtains the third decoded image, it can send the style identifier and the third decoded image to the AI stylization node. Upon receiving the style identifier and the third decoded image, the AI stylization node can perform AI stylization processing on the third decoded image based on the style identifier to obtain an AI-styled image, which is then sent to the cutout node. In this case, after the cutout node performs cutout processing on the AI-styled image to obtain the third cutout image, it can also obtain the position of the foreground object in the AI-styled image and send it to the main functional module through the AI stylization node and the decoding node. The main functional module can use this as the secondary composition position, that is, as the basis for adjusting the offset and scaling ratio in the lock screen wallpaper file.
[0819] Step 4020: The cutout node sends the third cutout image to the AI stylization node.
[0820] The operation of step 4020 is similar to that of step 3817 above, and will not be described again in this embodiment.
[0821] Step 4021: After receiving the third cutout image, the AI stylization node sends the AI style image and the third cutout image to the region cropping node.
[0822] The operation of step 4021 is similar to that of step 3818 above, and will not be described again in this embodiment.
[0823] Step 4022: After receiving the AI-style image and the third cutout image, the region cropping node sends the AI-style image and the third cutout image to the decoding node.
[0824] For example, the region cropping node can call the relevant callback function to send the AI-style image and the third cutout image to the decoding node.
[0825] In some embodiments, the region cropping node can also obtain the position information of the cropped image in the third decoded image as specified position information, and send the specified position information to the decoding node as well.
[0826] Step 4023: After receiving the AI-style image and the third cutout image, the decoding node calls the third callback function to send the AI-style image and the third cutout image to the main functional module.
[0827] In some embodiments, the decoding node may also send the specified location information to the main functional module.
[0828] Step 4024: After receiving the AI-style image and the third cutout image, the main functional module generates a fourth operation record. The fourth operation record is used to record the main image 4 and the cutout image 4 in the AI-style editing state.
[0829] The main image 4 in the fourth operation record is the AI-style image, and the cutout image 4 in the fourth operation record is the third cutout image.
[0830] It should be noted that after switching from AI expanded image editing mode to AI style editing mode, the lock screen wallpaper file edited in AI expanded image editing mode is the same as the lock screen wallpaper file currently being edited in AI style editing mode.
[0831] Step 4025: The main function module re-obtains the display image of the original layer based on the main image 4, and re-obtains the display image of the cut-out layer based on the cut-out image 4.
[0832] The operation of step 4025 is similar to the operation of step 3822 above, and will not be described again in this embodiment of the application.
[0833] Step 4026: The main functional module sends the view identifier and display image of the original la...
Claims
1. A wallpaper editing method, characterized in that, The method includes: Display a wallpaper editing interface, which includes a lock screen wallpaper page; In response to a user operation received in the wallpaper editing interface, the wallpaper on the lock screen wallpaper page is subjected to multiple target processing, each of which corresponds to a different editing state. For each target processing performed on the wallpaper on the lock screen wallpaper page, the wallpaper obtained after the target processing is displayed on the lock screen wallpaper page. The wallpaper obtained after the target processing is the wallpaper of the editing state corresponding to the target processing. In response to a user operation received in the wallpaper editing interface, the lock screen wallpaper page is reverted from the current editing state to displaying the wallpaper from the previous editing state.
2. The method as described in claim 1, characterized in that, The various target processing methods include at least two of the following: initial processing, engineered image expansion processing, artificial intelligence (AI) image expansion processing, and AI stylization processing. The initial processing refers to other processing performed on the wallpaper of the lock screen wallpaper page when the engineering image expansion processing, the AI image expansion processing, and the AI stylization processing have not been performed. The editing state corresponding to the initial processing is the initial editing state, the editing state corresponding to the engineering-based image expansion processing is the engineering-based image expansion editing state, the editing state corresponding to the AI image expansion processing is the AI image expansion editing state, and the editing state corresponding to the AI stylization processing is the AI style editing state.
3. The method as described in claim 1 or 2, characterized in that, Before performing various target processing on the wallpaper of the lock screen wallpaper page in response to a user operation received on the wallpaper editing interface, the method further includes: In response to an operation on a first control in the wallpaper editing interface, multiple wallpaper template options are displayed, including a first wallpaper template option. The wallpaper template corresponding to the first wallpaper template option includes multiple layers, and the multiple layers include layers of various types. In response to an operation performed on the first wallpaper template option, the wallpaper template corresponding to the first wallpaper template option is displayed on the lock screen wallpaper page.
4. The method as described in claim 3, characterized in that, The plurality of layers includes the original layer, and the plurality of layers also includes one or more of the following: a decoration layer, a color background layer, a clock layer, and a cutout layer; The original layer image is the main image, the decorative layer image is used to create a decorative effect on the main image, the color background layer image is a solid color image or a gradient color image, the clock layer is used to display the time, and the cutout layer image contains the foreground object in the main image. The original layer, the decorative layer, the color background layer, the clock layer, and the cutout layer are all of different layer types.
5. The method as described in claim 3 or 4, characterized in that, The wallpaper template file includes layer set information, which includes basic layer information for each of the multiple layers. The basic layer information of the multiple layers is organized in hierarchical order in the layer set information.
6. The method as described in claim 5, characterized in that, The wallpaper template file also includes one or more of the following: offset information, scaling ratio information, blur information, and depth of field effect on / off status information.
7. The method as described in claim 5 or 6, characterized in that, The method further includes: In response to the operation performed on the first wallpaper template option, the wallpaper template file is saved in memory as a lock screen wallpaper file; In response to a basic operation on any one of the multiple layers, the lock screen wallpaper file currently being edited in the editing state is updated. The basic operation is either a selection of a color option, a selection of a shape option, an on / off operation of the depth-of-field effect switch, a trigger operation of a control for adjusting blur, or a zoom or move operation performed on the lock screen wallpaper page.
8. The method as described in any one of claims 1 to 7, characterized in that, The step of performing a target processing on each pair of wallpapers on the lock screen wallpaper page, and displaying the wallpaper obtained after the target processing on the lock screen wallpaper page, includes: While currently in the first editing state, a first user operation is received on the wallpaper editing interface, the first user operation being used to instruct the target processing corresponding to the second editing state; In response to the first user operation, the lock screen wallpaper data of the first editing state is stored in the first cache area. The lock screen wallpaper data of the first editing state includes status data and image data. The status data includes wallpaper editing records and the lock screen wallpaper file edited in the first editing state. The wallpaper editing records are used to indicate the editing state generated during the current editing process. The image data includes the main image generated in the first editing state. Obtain the main image corresponding to the lock screen wallpaper data in the first editing state; Perform target processing on the main image corresponding to the lock screen wallpaper data in the first editing state, corresponding to the second editing state, to obtain the main image of the second editing state; Generate a target operation record, which is used to record the main image of the second editing state; Based on the target operation record and the lock screen wallpaper file, display the wallpaper on the lock screen wallpaper page.
9. The method as described in claim 8, characterized in that, The step of storing the lock screen wallpaper data from the first edit state into the first cache area includes: The lock screen wallpaper data in the first editing state is stored in the first cache area and the second cache area. The first cache area is a cache area in memory, and the second cache area is a cache area in the target memory. The method further includes: In response to an operation performed on the second control in the wallpaper editing interface, the lock screen wallpaper data of the current editing state is stored in the target storage area of the target memory, and the lock screen wallpaper data of each editing state before the current editing state during this editing process is moved from the second cache area to the target storage area.
10. The method as described in claim 8 or 9, characterized in that, The step of performing a target processing on each pair of wallpapers on the lock screen wallpaper page, and displaying the wallpaper obtained after the target processing on the lock screen wallpaper page, includes: While currently in the initial editing state, receive a third gesture operation on the lock screen wallpaper page; In response to the third gesture operation, the lock screen wallpaper data of the initial editing state is stored in the first cache area. The lock screen wallpaper data of the initial editing state includes initial state data and initial image data. The initial state data includes wallpaper editing records and the lock screen wallpaper file edited in the initial editing state. The wallpaper editing records are used to indicate the editing states generated in this editing process in the following order: initial editing state. Obtain a first target image, which is the main image corresponding to the lock screen wallpaper data in the initial edit state; The first target image is subjected to engineering-based image enlargement processing to obtain the first enlarged image; A second operation record is generated, which is used to record the main image in the engineering expanded image editing state, wherein the main image in the engineering expanded image editing state is the first expanded image; Based on the second operation record and the lock screen wallpaper file, the wallpaper is displayed on the lock screen wallpaper page.
11. The method as described in claim 10, characterized in that, The step of performing a target processing on each pair of wallpapers on the lock screen wallpaper page, and displaying the wallpaper obtained after the target processing on the lock screen wallpaper page, includes: Receive click operations on the AI image expansion control in the wallpaper editing interface; In response to a click operation on the AI image expansion control, the lock screen wallpaper data of the engineered image expansion editing state is stored in the first cache area. The lock screen wallpaper data of the engineered image expansion editing state includes engineered image expansion status data and engineered image expansion image data. The engineered image expansion status data includes wallpaper editing records and the lock screen wallpaper file edited in the engineered image expansion editing state. The wallpaper editing records are used to indicate the editing states generated during this editing process in sequence: initial editing state and engineered image expansion editing state. The engineered image expansion image data includes the main image in the second operation record. Obtain a second target image, which is the main image in the engineered expanded image data; The second target image is subjected to AI image enlargement processing to obtain the second enlarged image; A third operation record is generated, which is used to record the main image of the AI image expansion editing state, and the main image of the AI image expansion editing state is the second image expansion; Based on the third operation record and the lock screen wallpaper file, the wallpaper is displayed on the lock screen wallpaper page.
12. The method as described in claim 11, characterized in that, The step of displaying the wallpaper on the lock screen wallpaper page based on the second operation record and the lock screen wallpaper file further includes: The AI image expansion control is displayed in the wallpaper editing interface, and the AI image expansion control is in an unselected state. The step of displaying the wallpaper on the lock screen wallpaper page based on the third operation record and the lock screen wallpaper file further includes: Display the AI image expansion control as selected.
13. The method as described in claim 11 or 12, characterized in that, The step of performing a target processing on each pair of wallpapers on the lock screen wallpaper page, and displaying the wallpaper obtained after the target processing on the lock screen wallpaper page, includes: Receive click operations on the AI-style controls in the wallpaper editing interface; In response to a click on the AI-style control, a sixth pop-up window is displayed, which includes one or more style options and a confirmation control for generating the control. In response to a received selection of a style option and a click on the confirmation control, the lock screen wallpaper data in the AI-enlarged image editing state is stored in the first cache area. The lock screen wallpaper data in the AI-enlarged image editing state includes AI-enlarged image status data and AI-enlarged image data. The AI-enlarged image status data includes wallpaper editing records and the lock screen wallpaper file edited in the AI-enlarged image editing state. The wallpaper editing records indicate the editing states generated during this editing process in sequence: initial editing state, engineered image enlargement editing state, and AI-enlarged image editing state. The AI-enlarged image data includes the main image in the third operation record. Obtain a third target image, which is the main image in the AI-enlarged image data; The third target image is subjected to AI stylization processing based on the selected style option to obtain an AI-styled image; A fourth operation record is generated, which is used to record the main image of the AI-style editing state, and the main image of the AI-style editing state is the AI-style image; Based on the fourth operation record and the lock screen wallpaper file, the wallpaper is displayed on the lock screen wallpaper page.
14. The method as described in any one of claims 8 to 13, characterized in that, The step of responding to a user operation received on the wallpaper editing interface by reverting the lock screen wallpaper page from the current editing state to displaying the wallpaper from the previous editing state includes: The wallpaper editing interface receives a second user operation, which is used to indicate the cancellation of the target processing corresponding to the third editing state. In response to the second user operation, a fourth editing state is determined based on the wallpaper editing record, the fourth editing state being the previous editing state of the third editing state; Obtain the lock screen wallpaper data of the fourth editing state from the first cache area; Based on the lock screen wallpaper data in the fourth editing state, the wallpaper is displayed on the lock screen wallpaper page.
15. The method as described in claim 14, characterized in that, The step of displaying the wallpaper on the lock screen wallpaper page based on the lock screen wallpaper data from the fourth editing state further includes: While currently in the fourth editing state, a third user operation is received on the wallpaper editing interface, the third user operation being used to instruct the target processing corresponding to the third editing state; In response to the third user operation, if the third editing state is determined to be the next editing state after the fourth editing state based on the wallpaper editing record, then the lock screen wallpaper data of the third editing state is obtained from the first cache area; Based on the lock screen wallpaper data in the third editing state, the wallpaper is displayed on the lock screen wallpaper page.
16. The method according to any one of claims 1 to 15, characterized in that, The method further includes: In response to an operation performed on the second control in the wallpaper editing interface, the wallpaper currently displayed on the lock screen wallpaper page is set as the lock screen wallpaper.
17. The method as described in claim 16, characterized in that, The step of setting the currently displayed wallpaper on the lock screen wallpaper page as the lock screen wallpaper in response to an operation on the second control in the wallpaper editing interface includes: In response to the operation of the second control in the wallpaper editing interface, the lock screen wallpaper file edited in the current editing state is stored in the file system, and the lock screen wallpaper data of each editing state generated in the current editing process is stored in the target storage area.
18. The method as described in claim 17, characterized in that, After storing the lock screen wallpaper data for each of the multiple editing states generated during the current editing process to the target storage area, the process further includes: In response to a fourth user action, the lock screen wallpaper file is retrieved from the file system; The wallpaper is displayed on the lock screen wallpaper page in the wallpaper editing interface according to the lock screen wallpaper file; Retrieve the target wallpaper editing record from the target storage area; the target wallpaper editing record is the wallpaper editing record of the previous editing process. The wallpaper editing interface receives a fifth user operation, which is used to indicate the cancellation of the target processing corresponding to the fifth editing state. In response to the fifth user operation, a sixth editing state is determined based on the target wallpaper editing record, the sixth editing state being the previous editing state of the fifth editing state; Retrieve the lock screen wallpaper data of the sixth editing state from the target storage area; Based on the lock screen wallpaper data in the sixth editing state, the wallpaper is displayed on the lock screen wallpaper page.
19. The method as described in claim 18, characterized in that, The step of displaying the wallpaper on the lock screen wallpaper page based on the lock screen wallpaper data from the sixth editing state further includes: While currently in the sixth editing state, a sixth user operation is received on the wallpaper editing interface. The sixth user operation is used to instruct the target processing corresponding to the fifth editing state. In response to the sixth user operation, if the fifth editing state is determined to be the next editing state after the sixth editing state based on the target wallpaper editing record, then the lock screen wallpaper data of the fifth editing state is obtained from the target storage area; Based on the lock screen wallpaper data from the fifth editing state, the wallpaper is displayed on the lock screen wallpaper page.
20. The method according to any one of claims 1 to 19, characterized in that, Before displaying the wallpaper editing interface, the method further includes: Receive the first gesture operation on the lock screen; The wallpaper editing interface includes: In response to the first gesture operation, the wallpaper editing interface is displayed.
21. The method according to any one of claims 1 to 19, characterized in that, Before displaying the wallpaper editing interface, the method further includes: Receive a second gesture on the desktop; In response to the second gesture operation, a desktop editing interface is displayed, the desktop editing interface including a third control; The wallpaper editing interface includes: In response to an operation performed on the third control, the wallpaper editing interface is displayed.
22. An electronic device, characterized in that, The electronic device includes: one or more processors, and memory; The memory is coupled to the one or more processors, the memory being used to store computer program code, the computer program code including computer instructions, the one or more processors invoking the computer instructions to cause the electronic device to perform the method as described in any one of claims 1 to 21.
23. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes instructions that, when executed on an electronic device, cause the electronic device to perform the method as described in any one of claims 1 to 21.
24. A computer program product, characterized in that, When the computer program product is run on an electronic device, it causes the electronic device to perform the method as described in any one of claims 1 to 21.