Electronic device and tablecloth generation method thereof
By detecting the arrangement layout and specification parameters of the display device and using the image restoration model to amplify and segment the image, the problem of wallpaper matching on multiple display devices is solved, automatic wallpaper generation is achieved, and the user experience and aesthetics are improved.
Patent Information
- Application Number
- CN202410281050.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-12
- Publication Date
- 2025-09-12
AI Technical Summary
When users change wallpapers for multiple display devices, they need to manually edit the images to match the resolution and screen resolution, which makes the operation inconvenient and time-consuming, especially when it is difficult to find wallpapers of similar styles in multi-monitor situations.
By acquiring the original image, detecting the arrangement layout and specification parameters of the display device, using the image restoration model to enlarge the image to the target resolution, and segmenting the image according to the device layout to generate a wallpaper suitable for each display device.
Dynamically generate wallpapers that match the resolution and layout configurations of multiple display devices, reducing user time for manual editing and image searching, improving the user experience, and ensuring that the wallpapers are aligned and beautiful on all devices.
Smart Images

Figure CN120634845A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to an electronic device, and in particular to an electronic device and a wallpaper generation method thereof. Background Art
[0002] With the advancement of technology, powerful performance and rich applications have made electronic devices an indispensable item in modern people's daily lives. Generally speaking, these electronic devices can display the user's favorite wallpaper on the display, thereby enhancing the aesthetics of the electronic device and achieving a personalized effect.
[0003] Currently, when users want to change their monitor's wallpaper, after finally finding a picture they like, they often need to manually edit the image to match their desired display resolution because the image resolution doesn't match the screen resolution. This manual image editing process is quite inconvenient and time-consuming for users. Furthermore, when users use multiple monitors, if they want to display a similar wallpaper style on all of them, they have to spend even more time searching for other images with similar styles. Summary of the Invention
[0004] The present invention relates to an electronic device and a wallpaper generation method, which can solve the above technical problems.
[0005] An embodiment of the present invention provides a wallpaper generation method comprising the following steps: obtaining an original image; detecting the layout positions and display specifications of multiple display devices; determining a target image resolution based on the layout positions and display specifications of each display device; utilizing an image restoration model to enlarge the original image into a target enlarged image having the target image resolution; and generating a wallpaper for display on each display device by segmenting the target enlarged image.
[0006] An embodiment of the present invention provides an electronic device comprising a storage device and a processor. The storage device stores a plurality of instructions. The processor is coupled to the storage device and accesses the instructions to perform the following operations: acquiring an original image; detecting the arrangement layout positions and display specification parameters of a plurality of display devices; determining a target image resolution based on the arrangement layout positions and display specification parameters of each display device; utilizing an image restoration model to enlarge the original image into a target enlarged image having the target image resolution; and generating a wallpaper displayed on each display device by segmenting the target enlarged image.
[0007] Based on the above, in embodiments of the present invention, an image restoration model can be used to enlarge an original image into a target enlarged image with a target resolution. The target resolution is determined based on the layout and display specifications of each display device. Consequently, the target enlarged image can be segmented based on the layout and display specifications of each display device to generate a wallpaper for display on each display device. This allows for dynamic generation of wallpaper images that match the resolutions and layouts of multiple display devices, eliminating the need for time-consuming manual image editing or image searching, thereby enhancing the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0008] Figure 1A is a block diagram of a multi-screen display system according to an embodiment of the present invention;
[0009] Figure 1B is a schematic diagram of a multi-screen display system according to an embodiment of the present invention;
[0010] Figure 2 is a flowchart of a method for generating a wallpaper according to an embodiment of the present invention;
[0011] Figure 3 is a flow chart of generating a target augmented image according to one embodiment of the present invention;
[0012] Figure 4 is a schematic diagram of generating a target amplified image according to an embodiment of the present invention;
[0013] Figures 5A to 5B is a schematic diagram of an application scenario of multiple displays according to an embodiment of the present invention;
[0014] Figure 6 is a flowchart of a method for generating a wallpaper according to an embodiment of the present invention;
[0015] Figure 7 FIG. 1 is a schematic diagram of an application scenario of multiple display devices according to an embodiment of the present invention.
[0016] Description of Reference Numerals
[0017] 10: Multi-screen display system;
[0018] 100: electronic device;
[0019] 110_1 to 110_n: display devices;
[0020] 120: storage device;
[0021] 130: processor;
[0022] IMG_ori1, IMG_ori2, IMG_ori3: original images;
[0023] MB1: mask block;
[0024] IMG_t1, IMG_t2, IMG_t3, IMG_t4: target amplified images;
[0025] IMG_im1, IMG_im2: input mask image;
[0026] IMG_s1: scaled mask image;
[0027] IMG_f1: restored image;
[0028] SIMG1~SIMG8: sub-images;
[0029] S210~S250, S310~S323, S610~S651: steps. DETAILED DESCRIPTION
[0030] Reference will now be made in detail to exemplary embodiments of the present invention, examples of which are illustrated in the accompanying drawings. Whenever possible, the same reference numerals are used in the drawings and the description to refer to the same or like parts.
[0031] Figure 1A is a block diagram of a multi-screen display system according to an embodiment of the present invention. Figure 1A The multi-screen display system 10 includes multiple display devices 110_1-110_n, a storage device 120, and a processor 130. The present disclosure does not limit the number of the multiple display devices 110_1-110_n. Furthermore, in some embodiments, one of the multiple display devices 110_1-110_n can be implemented as an electronic device with display functionality together with the storage device 120 and the processor 130. In some embodiments, the multiple display devices 110_1-110_n can also be connected in a daisy chain topology, but the present disclosure is not limited thereto.
[0032] For example, Figure 1B is a schematic diagram of a multi-screen display system according to an embodiment of the present invention. Figure 1BIn the embodiment of the present invention, the number of the multiple display devices 110_1 to 110_2 is 2. The display device 110_1 can be implemented as an electronic device 100 with a display function together with the storage device 120 and the processor 130. The electronic device 100 is, for example, a tablet computer, a laptop computer, a desktop computer, or an all-in-one computer, etc., and the present disclosure is not limited to this. The display device 110_2 can be connected to the electronic device 100 via a wired or wireless transmission interface. For example, the transmission interface is, for example, a DP transmission interface, an HDMI transmission interface, a USB-C transmission interface, or a WiFi transmission interface, etc.
[0033] The display devices 110_1 to 110_n are, for example, liquid crystal displays (LCDs), light-emitting diode (LED) displays, organic light-emitting diode (OLED) displays, or other types of displays, which are not limited in the present invention.
[0034] The storage device 120 is used to store data and data such as software modules (such as operating systems, applications, and drivers) accessed by the processor 130. It can be, for example, any type of fixed or removable random access memory (RAM), read-only memory (ROM), flash memory, hard disk, or a combination thereof.
[0035] The processor 130 is coupled to the plurality of display devices 110_1-110_n and the storage device 120. The processor 130 may be, for example, a central processing unit (CPU), an application processor (AP), or other programmable general-purpose or special-purpose microprocessor, digital signal processor (DSP), programmable controller, application-specific integrated circuit (ASIC), programmable logic device (PLD), graphics processing unit (GPU), or other similar devices or combinations thereof. The processor 130 may execute program code, software modules, instructions, etc. stored in the storage device 120 to implement the dynamic wallpaper display method of the present embodiment.
[0036] Figure 2 is a flowchart of a method for generating a wallpaper according to an embodiment of the present invention, and Figure 2 The method flow can be Figure 1A The components of the multi-screen display system 10 are implemented. Please also refer to Figure 1A and Figure 2 , the following is matched Figure 1A The steps of the wallpaper generation method of this embodiment are described with reference to the components of FIG.
[0037] In step S210, the processor 130 obtains an original image. The present disclosure does not limit the resolution of the original image. The original image can be a photo, a default wallpaper image built into the electronic device 100, or any image downloaded from the Internet by the user.
[0038] In some embodiments, processor 130 may also generate multiple candidate images with different or similar image styles based on a reference image, and select the original image from the multiple candidate images based on user instructions. For example, processor 130 may input the reference image into a trained image style transfer model to generate these candidate images. This can enhance the diversity of wallpapers across multiple display devices 110_1-110_n.
[0039] In step S220, the processor 130 detects the arrangement layout positions and display specification parameters of the plurality of display devices 110_1 to 110_n. In some embodiments, the display specification parameters include screen resolution and screen size. In different embodiments, the screen resolution and screen size of the display devices 110_1 to 110_n may be the same or different. For example, Figure 1B In the example, the screen resolution of display device 110_1 may be 1920x1080, and the screen size of display device 110_1 may be 15.6 inches. Alternatively, the screen resolution of display device 110_2 may be 1920x1080, and the screen size of display device 110_1 may be 24 inches. However, this is merely an example, and the present disclosure is not limited thereto.
[0040] In addition, the processor 130 can identify the arrangement and layout of these display devices 110_1 to 110_n to obtain the arrangement and layout position of each display device 110_1 to 110_n. For example, Figure 1BIn the example, display devices 110_1-110_2 are arranged side by side, but this is not limited to this arrangement. In other words, processor 130 can recognize that display device 110_2 is located to the right of display device 110_1. Processor 130 can, for example, obtain the arrangement and layout positions of each display device 110_1-110_n through a specific Windows API provided by the Windows operating system.
[0041] In step S230, the processor 130 determines a target image resolution based on the arrangement layout position and display specification parameters of each display device 110_1 to 110_n. That is, the processor 130 can determine the range of image augmentation content that needs to be additionally generated based on the arrangement layout position and display specification parameters of each display device 110_1 to 110_n. For example, assuming that the display devices 110_1 to 110_2 are arranged side by side and the screen size and screen resolution of the display devices 110_1 to 110_2 are the same, the processor 130 can multiply the width of this screen resolution by 2 to obtain the width of the target image resolution (indicating that the processor 130 needs to generate image augmentation content in the horizontal direction), and set the height of the target image resolution equal to the height of this screen resolution. Then, in step S240, the processor 130 uses an image restoration model to amplify the original image into a target augmented image with the target image resolution.
[0042] In some embodiments, Figure 3 This is a flow chart of generating a target amplified image according to an embodiment of the present invention. Figure 4 Matching instructions, Figure 4 This is a schematic diagram of generating a target amplification image according to an embodiment of the present invention. Figure 3 and Figure 4 .
[0043] In step S310, the processor 130 determines an input mask image IMG_im1, comprising a mask block MB1 and an original image IMG_ori1, based on the layout of the display devices 110_1-110_n and the target image resolution. The mask block MB1 represents the area to be infilled by the image inpainting model. As can be seen, after determining the target image resolution, the extent of the mask block MB1 can be determined based on the resolution of the original image IMG_ori1 and the layout of the display devices 110_1-110_n.
[0044] In other embodiments, the processor 130 may first obtain a partial image block from the original image. Next, based on the layout of each display device 110_1 - 110_n and the target image resolution, the processor 130 determines an input mask image that includes a mask block and a partial image block of the original image. In other words, the input mask image only includes a partial image block of the original image, with the remainder being the mask block.
[0045] Then, in step S320 , the processor 130 utilizes the image restoration model to restore the input mask image IMG_im1 to the target augmented image IMG_t1 . In this embodiment, step S320 can be implemented as steps S321 to S323 .
[0046] In step S321 , the processor 130 performs an image scaling process on the input mask image IMG_im1 to generate a scaled mask image IMG_s1 . That is, the processor 130 first scales the input mask image IMG_im1 into a model input format that conforms to the image restoration model.
[0047] In step S322, the processor 130 inputs the scaled mask image IMG_s1 into the image restoration model to obtain a restored image IMG_f1. The image restoration model is a deep learning model used to fill in missing, damaged or incomplete parts of an image. The image restoration model is usually based on a convolutional neural network (CNN) or a generative adversarial network (GAN), which can learn to infer the content of the missing area from the context of the image. In addition, in some embodiments, the processor 130 can also input a text content into the image restoration model so that the image restoration model fills the image according to the text content. For example, the processor 130 can use a Stable Diffusion model and an inpainting ControlNet model to generate a restored image IMG_f1. In some embodiments, the above-mentioned text content can be input by the user. In other embodiments, the processor 130 can use an image-generated text model to generate the above-mentioned text content based on the original image.
[0048] In step S323 , the processor 130 performs another image scaling process on the restored image IMG_f1 to generate a target upscaled image IMG_t1 having a target resolution. That is, the processor 130 may scale the restored image IMG_f1 conforming to the model output format into a target upscaled image IMG_t1 having a target resolution.
[0049] In some embodiments, the processor 130 may further overlay the original image IMG_ori on the target augmented image IMG_t1 to ensure that the target augmented image IMG_t1 includes the original content of the original image IMG_ori1 and improve the phenomenon that multiple image scaling processes may cause image quality degradation.
[0050] In step S250, processor 130 segments the target augmented image IMG_t1 to generate a wallpaper (also known as a wallpaper or desktop background) for display on each of display devices 110_1-110_n. Specifically, the target augmented image IMG_t1 is segmented to generate a wallpaper for each of display devices 110_1-110_n. As expected, the wallpaper image quality of the disclosed embodiment is higher and clearer than simply magnifying the original image and displaying it blurrily on each display device.
[0051] Figures 5A to 5B This is a schematic diagram of an application scenario of multiple displays according to an embodiment of the present invention. Figure 5A Based on the display specification parameters and arrangement layout positions of the display devices 110_1 to 110_3, the processor 130 can generate a target augmented image IMG_t2 according to the original image IMG_ori2. Figure 5A As shown, processor 130 generates augmented image content to the right and left of original image IMG_ori2. As a result, primary display device 110_1 can display the center sub-image SIMG1 as a wallpaper. Left display device 110_2 can display the left sub-image SIMG2 as a wallpaper. Right display device 110_3 can display the right sub-image SIMG3 as a wallpaper.
[0052] Please refer to Figure 5B Based on the display specification parameters and arrangement layout positions of the display devices 110_1 to 110_3, the processor 130 can generate a target augmented image IMG_t3 according to the original image IMG_ori2. Figure 5B As shown, processor 130 generates augmented image content toward the upper right of original image IMG_ori2. Subsequently, processor 130 cuts out three sub-images SIMG4 through SIMG6 from target augmented image IMG_t3. The primary display device 110_1 then displays the lower-left sub-image SIMG4 as a wallpaper. The upper display device 110_2 displays the upper-left sub-image SIMG5 as a wallpaper. The right display device 110_3 displays the right sub-image SIMG6 as a wallpaper.
[0053] It should be noted that when the pixel densities (Pixels Per Inch, PPI) of the display devices 110_1-110_n differ greatly, if the target image resolution and image segmentation are determined based solely on the screen resolution of the display devices 110_1-110_n, the wallpaper contents displayed on the display devices 110_1-110_n may be misaligned (e.g., Figure 5A The wallpaper content of display device 110_1 and the wallpaper content of display device 110_2 may not be aligned well. Therefore, in some embodiments, the processor 130 may further determine the target image resolution and perform image segmentation based on the pixel density of these display devices 110_1 to 110_n. An embodiment will be described in detail below.
[0054] Figure 6 is a flowchart of a method for generating a wallpaper according to an embodiment of the present invention, and Figure 6 The method flow can be implemented by the components of the electronic device 100 in FIG1. Figure 6 .
[0055] In step S610, the processor 130 acquires an original image. In step S620, the processor 130 detects the arrangement and layout of the plurality of display devices 110_1 to 110_n and the display specifications. The display specifications include screen resolution and screen size. These steps can be described with reference to the previous embodiment and are not repeated here.
[0056] In step S630 , the processor 130 determines a target image resolution based on the arrangement and layout positions of the display devices 110_1 - 110_n and the display specification parameters. In this embodiment, step 630 can be implemented as steps S631 to S632 .
[0057] In step S631 , the processor 130 calculates the pixel density (PPI) of each display device 110_1 - 110_n based on the display specification parameters of each display device 110_1 - 110_n. For example, the processor 130 may calculate the pixel density of each display device 110_1 - 110_n based on the following equation (1).
[0058]
[0059] Among them, dp is the resolution of the screen diagonal; wp is the horizontal resolution of the screen; hp is the vertical resolution of the screen; di is the actual length of the screen diagonal (in inches).
[0060] In step S632 , the processor 130 compares the pixel densities of the display devices 110_1 ˜ 110_n In step S633 , the processor 130 determines the target image resolution based on the comparison result and the screen resolution of the display devices 110_1 ˜ 110_n .
[0061] In some embodiments, when the pixel densities of the display devices 110_1-110_n are similar, the processor 130 may determine the target image resolution based solely on the screen resolution and layout of the display devices 110_1-110_n. For example, when the display devices 110_1-110_n are arranged horizontally, the width of the target image resolution may be the sum of the widths of the screen resolutions of the display devices 110_1-110_n. When the display devices 110_1-110_n are arranged vertically, the height of the target image resolution may be the sum of the heights of the screen resolutions of the display devices 110_1-110_n.
[0062] In some embodiments, when the pixel densities of the display devices 110_1 - 110_n differ significantly, the processor 130 may determine the target image resolution based on the ratio of the pixel densities of the display devices, the screen resolutions of the display devices 110_1 - 110_n, and their layout positions. In other words, the processor 130 determines the range of image augmentation content based on the degree of pixel density difference, allowing the display device with the lower pixel density to capture a larger range of image content for reduced display.
[0063] In some embodiments, the comparison result of the pixel density includes a ratio between the pixel density of the first display device and the pixel density of the second display device, and the ratio is greater than or equal to 1. The processor 130 may calculate a first multiplication result of the width of the screen resolution of the first display device and the ratio. Then, the processor 130 may add the first multiplication result to the width of the screen resolution of the second display device to generate the width of the target image resolution. Here, the pixel density of the first display device is less than the pixel density of the second display device. Further, in some embodiments, the processor 130 may calculate a second multiplication result of the height of the screen resolution of the first display device and the ratio. Thereafter, the processor 130 may set the larger of the second multiplication result and the height of the screen resolution of the second display device as the height of the target image resolution.
[0064] In another embodiment, the processor 130 may calculate a first multiplication result of the height of the screen resolution of the first display device and the ratio. The processor 130 may then add the first multiplication result to the height of the screen resolution of the second display device to generate the height of the target image resolution. In this case, the pixel density of the first display device is less than the pixel density of the second display device. Furthermore, in some embodiments, the processor 130 may calculate a second multiplication result of the width of the screen resolution of the first display device and the ratio. The processor 130 may then set the larger of the second multiplication result and the width of the screen resolution of the second display device as the width of the target image resolution.
[0065] For example, Figure 7 is a schematic diagram of an application scenario of multiple display devices according to an embodiment of the present invention. Figure 7 , in order to clearly illustrate the principle of the present invention, Figure 7 The following description uses two display devices 110_1 and 110_2 arranged horizontally side by side as an example. Furthermore, the display specifications of the display device 110_1 are A inches and W1 x H1, while the display specifications of the display device 110_2 are B inches and W2 x H2.
[0066] Assuming A = 15.6 inches; B = 24 inches; W1 = W2 = 1920; and H1 = H2 = 1080, processor 130 can calculate that the pixel density of display device 110_1 is approximately 142 PPI, and that the pixel density of display device 110_2 is approximately 94 PPI. The ratio between the pixel density of display device 110_1 and the pixel density of display device 110_2 is approximately 1.5. Therefore, because the pixel density of display device 110_2 (i.e., the first display device) is lower than the pixel density of display device 110_1 (i.e., the second display device), processor 130 can first multiply the width W2 and height H2 of the screen resolution of display device 110_2 by 1.5, respectively, to generate a first multiplication result W' = 1.5*W2 and a second multiplication result 1.5*H2. Then, the height H' of the target image resolution is equal to the second multiplication result 1.5*H2, and the width W71 of the target image resolution is equal to the second multiplication result W' plus the width W1 of the screen resolution of the display device 110_1. After substituting the above assumed values, it can be seen that the target image resolution is equal to 4800x1620.
[0067] Next, in step S640, the processor 130 uses an image restoration model to enlarge the original image into a target enlarged image having a target image resolution. These steps can be described with reference to the above embodiments and are not described in detail here.
[0068] In step S650 , the processor 130 generates a wallpaper to be displayed on each of the display devices 110_1 to 110_n by segmenting the target augmented image. In this embodiment, step 650 can be implemented as steps S651 to S652 .
[0069] In step S651 , the processor 130 divides the target augmented image into a plurality of sub-images corresponding to the plurality of display devices 110_1 ˜ 110 — n according to the comparison result and the arrangement and layout positions of the display devices 110_1 ˜ 110 — n .
[0070] In some embodiments, when the pixel densities of the display devices 110_1-110_n are relatively similar, the processor 130 may segment the target augmented image based solely on the screen resolution and layout of each display device 110_1-110_n. For example, when the display devices 110_1-110_n are arranged horizontally, the processor 130 may segment the target augmented image into multiple horizontally aligned sub-images based solely on the width of each display device 110_1-110_n's screen resolution, thereby obtaining multiple sub-images for the multiple display devices 110_1-110_n. When the display devices 110_1-110_n are arranged vertically, the processor 130 may segment the target augmented image into multiple vertically aligned sub-images based solely on the height of each display device 110_1-110_n's screen resolution, thereby obtaining multiple sub-images for the multiple display devices 110_1-110_n.
[0071] In some embodiments, when the pixel densities of the display devices 110_1-110_n differ significantly, the processor 130 may determine the target image resolution based on a ratio between the pixel densities of adjacent display devices, the screen resolution of each display device 110_1-110_n, and the layout position, to segment the target upscaled image. In other words, the processor 130 determines the image content to be allocated to each display device based on the degree of pixel density difference, allowing display devices with lower pixel density to capture a wider range of image content for reduced display.
[0072] In some embodiments, the comparison result includes a ratio between the pixel density of the first display device and the pixel density of the second display device, where the ratio is greater than or equal to 1. That is, the larger of the pixel density of the first display device and the pixel density of the second display device serves as the numerator of the ratio, and the smaller of the pixel density of the first display device and the pixel density of the second display device serves as the denominator of the ratio.
[0073] In some embodiments, the pixel density of the first display device is lower than the pixel density of the second display device. Accordingly, the image resolution of the second sub-image corresponding to the second display device is equal to the screen resolution of the second display device, and the image resolution of the first sub-image corresponding to the first display device is equal to the screen resolution of the first display device multiplied by the ratio.
[0074] For example, please refer again to Figure 7 . After the processor 130 determines the target image resolution W71 x H'2, the processor 130 may generate an input mask image IMG_im2 including the original image IMG_ori3 and the mask block. Thereafter, the processor 130 may use the image restoration model to generate a target augmented image IMG_t4 based on the input mask image IMG_im2. Next, the processor 130 may segment the target augmented image IMG_t4 into sub-images SIMG7 to SIMG8 based on the ratio between pixel densities and the respective screen resolutions of the display devices 110_1 to 110_2. Since the pixel density of the display device 110_2 (i.e., the first display device) is smaller than the pixel density of the display device 110_1 (i.e., the second display device), the image resolution of the sub-image SIMG7 obtained by the processor 130 is equal to the screen resolution of the display device 110_1. Furthermore, the image resolution of the sub-image SIMG8 obtained by the processor 130 is equal to the screen resolution of the display device 110_2 multiplied by the ratio 1.5. Assuming A=15.6; B=24; W1=W2=1920; H1=H2=1080, the image resolution of the sub-image SIMG7 of the display device 110_1 is 1920×1080, while the image resolution of the sub-image SIMG8 of the display device 110_2 is 2880×1620.
[0075] In step S652, the processor 130 generates a wallpaper to be displayed on each display device 110_1 to 110_n based on the plurality of sub-images. In some embodiments, the processor 130 performs an image reduction process on the first sub-image corresponding to the first display device according to the screen resolution of the first display device to obtain the wallpaper of the first display device. That is, the processor 130 may perform an image reduction process on the sub-image of the display device with a lower pixel density to generate the final wallpaper. Figure 7 For example, processor 130 may display the 1920x1080 sub-image SIMG7 as the wallpaper of display device 110_1. Furthermore, processor 130 may downscale the 2880x1620 sub-image SIMG8 to obtain a 1920x1080 wallpaper for display on display device 110_2. Consequently, the content of the wallpaper displayed on display device 110_1 and the wallpaper displayed on display device 110_2 can be aligned.
[0076] In summary, in an embodiment of the present invention, an image restoration model can be used to enlarge the original image into a target enlarged image with a target image resolution, wherein the target image resolution is determined according to the arrangement layout position and display specification parameters of each display device. Therefore, the target enlarged image can be segmented based on the arrangement layout position and display specification parameters of each display device to generate a wallpaper displayed on each display device. Based on this, a wallpaper image that meets the resolution and layout configuration of multiple display devices can be dynamically generated without the user having to spend time manually editing or searching for images, thereby improving the user experience. In addition, in an embodiment of the present invention, wallpaper content suitable for each display device can be generated based on the differences in pixel density between these display devices, so that the aesthetics and alignment effects of the wallpapers displayed by these display devices can be improved.
[0077] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the above embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for generating a wallpaper, characterized in that: include: Get the original image; Detect the arrangement layout positions and display specification parameters of multiple display devices; determining a target image resolution according to the arrangement layout positions and the display specification parameters of each of the plurality of display devices; Amplifying the original image into a target amplified image having the target image resolution using an image restoration model; as well as A wallpaper displayed on each of the plurality of display devices is generated by dividing the target enlarged image.
2. The method for generating a wallpaper according to claim 1, wherein: The display specification parameters include screen resolution and screen size.
3. The method for generating a wallpaper according to claim 2, wherein: The step of using the image restoration model to amplify the original image into the target amplified image having the target image resolution includes: Determining an input mask image including a mask block and the original image according to the arrangement layout positions of each of the plurality of display devices and the target image resolution; and The input mask image is inpainted into the target augmented image using the image inpainting model.
4. The method for generating a wallpaper according to claim 3, wherein: The step of using the image restoration model to restore the input mask image to the target augmented image includes: performing image scaling processing on the input mask image to generate a scaled mask image; Inputting the scaled mask image into the image restoration model to obtain a restored image; and Another image scaling process is performed on the restored image to generate the target upscaled image with the target picture resolution.
5. The method for generating a wallpaper according to claim 2, wherein: The step of determining the target image resolution according to the arrangement layout positions and the display specification parameters of each of the plurality of display devices includes: Calculating the pixel density of each of the plurality of display devices according to the display specification parameters of each of the plurality of display devices; comparing the pixel density of each of the plurality of display devices; and The target image resolution is determined according to the comparison result and the screen resolution of each of the plurality of display devices.
6. The method for generating a wallpaper according to claim 5, wherein: The multiple display devices include a first display device and a second display device, the comparison result includes a ratio between the pixel density of the first display device and the pixel density of the second display device, the ratio being greater than or equal to 1, and determining the target image resolution based on the comparison result and the screen resolution of each of the multiple display devices includes: calculating a first multiplication result of a width of the screen resolution of the first display device and the ratio, wherein the pixel density of the first display device is smaller than the pixel density of the second display device; and The first multiplication result is added to the width of the screen resolution of the second display device to generate the width of the target image resolution.
7. The method for generating a wallpaper according to claim 6, wherein: The step of determining the target image resolution based on the comparison result and the screen resolution of each of the plurality of display devices further includes: Calculating a second multiplication result of the height of the screen resolution of the first display device and the ratio; and The larger one between the second multiplication result and the high of the screen resolution of the second display device is set as the high of the target image resolution.
8. The method for generating a wallpaper according to claim 7, wherein: The step of generating the wallpaper displayed on each of the plurality of display devices by segmenting the target augmented image comprises: dividing the target enlarged image into a plurality of sub-images corresponding to the plurality of display devices respectively according to the comparison result and the arrangement layout positions of the plurality of display devices; and The wallpaper displayed on each of the plurality of display devices is generated according to the plurality of sub-images.
9. The method for generating a wallpaper according to claim 8, wherein: The multiple display devices include a first display device and a second display device, the comparison result includes a ratio between the pixel density of the first display device and the pixel density of the second display device, the ratio is greater than or equal to 1, the pixel density of the first display device is less than the pixel density of the second display device, the image resolution of the second sub-image corresponding to the second display device is equal to the screen resolution of the second display device, and the image resolution of the first sub-image corresponding to the first display device is equal to the screen resolution of the first display device multiplied by the ratio.
10. The method for generating a wallpaper according to claim 8, wherein: The pixel density of the first display device is smaller than the pixel density of the second display device, and the step of generating the wallpaper displayed on each of the plurality of display devices according to the plurality of sub-images includes: According to the screen resolution of the first display device, image reduction processing is performed on the first sub-image corresponding to the first display device to obtain the wallpaper of the first display device.
11. An electronic device, characterized in that: include: a storage device storing a plurality of instructions; as well as a processor coupled to the storage device and configured to: Get the original image; Detect the arrangement layout positions and display specification parameters of multiple display devices; determining a target image resolution according to the arrangement layout positions and the display specification parameters of each of the plurality of display devices; Amplifying the original image into a target amplified image having the target image resolution using an image restoration model; as well as A wallpaper displayed on each of the plurality of display devices is generated by dividing the target enlarged image.