Image production method, device, electronic equipment, and storage medium
By pre-rendering and compositing images, the problem of long rendering time for complex images is solved, and the process of image display and sharing is synchronized.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING DONGCHEZU TECHNOLOGY CO LTD
- Filing Date
- 2024-12-18
- Publication Date
- 2026-05-08
AI Technical Summary
Existing image rendering technologies are time-consuming when processing complex images, making it difficult to synchronize image display and sharing processes.
Multiple candidate objects are rendered in advance to generate a foreground layer image, and the target image is synthesized in response to switching commands during the image display process, reducing rendering time.
It enables the synchronization of image display and sharing processes, improving the speed and efficiency of image production.
Smart Images

Figure CN119741401B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of image processing technology, and in particular to an image production method, apparatus, electronic device, and storage medium. Background Technology
[0002] In today's era of increasingly frequent digital information exchange, users often have the need to share multiple things with others in various scenarios such as daily social interactions, work collaborations, and interest-based exchanges. For example, in activities such as product demonstrations, images are used to present key features and detailed information about the product. The use of images can improve the effectiveness of information transmission.
[0003] However, in creating images for sharing, especially for complex objects—which often contain numerous components, intricate textures, diverse materials, and complex spatial relationships—existing image rendering technologies require precise calculations and simulations of every detail, such as ray tracing, material reflection and refraction, and shadow generation, resulting in lengthy rendering times. During the sharing process, as the content progresses, images matching the current content need to be created quickly to ensure synchronized display and sharing. However, due to the aforementioned rendering time constraints, corresponding images cannot be generated in a timely manner, making it difficult to synchronize image display and sharing. Summary of the Invention
[0004] In order to solve the above-mentioned technical problems, or at least partially solve the above-mentioned technical problems, this disclosure provides an image production method, apparatus, electronic device, and storage medium.
[0005] In a first aspect, this disclosure provides an image creation method, including:
[0006] Obtain the background layer image and rendering data for multiple candidate objects;
[0007] The multiple candidate objects are sorted according to a preset sorting rule to obtain a target sequence;
[0008] According to the target sequence, image rendering is performed sequentially based on the rendering data of the candidate objects to obtain the foreground layer image corresponding to the candidate objects;
[0009] During image display, in response to a switching command to switch to the target object, the foreground layer image and the background layer image corresponding to the target object are combined to obtain a target image corresponding to the target object and displayed; the target object is an object among the plurality of candidate objects.
[0010] Secondly, this disclosure also provides an image production apparatus, comprising:
[0011] The acquisition module is used to acquire the background layer image and rendering data of multiple candidate objects;
[0012] The sorting module is used to sort the multiple candidate objects according to a preset sorting rule to obtain a target sequence;
[0013] The rendering module is used to render images sequentially based on the rendering data of the candidate objects according to the target sequence, so as to obtain a foreground layer image corresponding to the candidate objects;
[0014] The switching module is used to, in response to a switching command to switch to the target object during the image display process, combine the foreground layer image and the background layer image corresponding to the target object to obtain and display the target image corresponding to the target object; the target object is an object among the plurality of candidate objects.
[0015] Thirdly, this disclosure also provides an electronic device, the electronic device comprising:
[0016] One or more processors;
[0017] Storage device for storing one or more programs;
[0018] When the one or more programs are executed by the one or more processors, the one or more processors implement the image creation method as described above.
[0019] Fourthly, this disclosure also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the image creation method described above.
[0020] The technical solution provided in this disclosure has the following advantages compared with the prior art:
[0021] The technical solution provided in this disclosure renders images sequentially based on the rendering data of candidate objects according to a target sequence, obtaining a foreground layer image corresponding to the candidate object. During image display, in response to a switching command to the target object, the foreground layer image and background layer image corresponding to the target object are composited to obtain and display the target image corresponding to the target object. The target object is an object among multiple candidate objects. In practice, rendering candidate objects usually takes a long time, while compositing the foreground layer image and background layer image often takes less time. The essence of the above technical solution is to pre-render each candidate object to obtain a foreground layer image corresponding to the candidate object. When a switching command for a certain candidate object is detected, the previously rendered foreground layer image and background layer image corresponding to that candidate object can be directly called for compositing, instead of starting to render the foreground layer image corresponding to the candidate object only after the switching command is detected. This can significantly shorten the time interval from detecting the switching command to displaying the target image corresponding to the switching command, enabling rapid creation and timely display of the target image, thereby synchronizing the image display and sharing process. Attached Figure Description
[0022] The accompanying drawings, which are incorporated in and form a part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure.
[0023] To more clearly illustrate the technical solutions in the embodiments of this disclosure or the prior art, the accompanying drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0024] Figure 1 A flowchart illustrating an image creation method provided in this embodiment of the disclosure;
[0025] Figure 2 A schematic diagram of image creation provided in this embodiment of the disclosure;
[0026] Figure 3 A flowchart illustrating another image creation method provided in this disclosure embodiment;
[0027] Figure 4 A schematic diagram of a live streaming page provided in an embodiment of this disclosure;
[0028] Figure 5 This is a schematic diagram of the structure of an image processing apparatus according to an embodiment of the present disclosure;
[0029] Figure 6 This is a schematic diagram of the structure of an electronic device according to an embodiment of this disclosure. Detailed Implementation
[0030] To better understand the above-mentioned objectives, features, and advantages of this disclosure, the solutions disclosed herein will be further described below. It should be noted that, unless otherwise specified, the embodiments and features described herein can be combined with each other.
[0031] Numerous specific details are set forth in the following description in order to provide a full understanding of this disclosure, but this disclosure may also be implemented in other ways different from those described herein; obviously, the embodiments in the specification are only some, and not all, of the embodiments of this disclosure.
[0032] Figure 1 This is a flowchart illustrating an image creation method provided in an embodiment of this disclosure. This embodiment is applicable to image creation on a client side. The method can be executed by an image creation device, which can be implemented in software and / or hardware. This device can be configured in an electronic device, such as a terminal, including but not limited to smartphones, PDAs, tablets, wearable devices with displays, desktop computers, laptops, all-in-one computers, smart home devices, etc. Alternatively, this embodiment can be applied to image creation on a server side. The method can be executed by an image creation device, which can be implemented in software and / or hardware. This device can be configured in an electronic device, such as a server.
[0033] like Figure 1 As shown, the method may specifically include:
[0034] S110: Obtain the background layer image and rendering data for multiple candidate objects.
[0035] Candidate objects can be, for example, things that a user wishes to share. Rendering data for candidate objects can be, for example, data used to render an image including the candidate object. Exemplarily, the rendering data for candidate objects can include at least one of the following: geometric data, material data, lighting data, and color data of a 3D model of the candidate object.
[0036] The image produced using the technical solution provided in this application is the target image, and the target image corresponds to the candidate object. In other words, different candidate objects have different target images.
[0037] In this application, the target image is considered as a superposition of two parts: a foreground layer image and a background layer image. The foreground layer image is obtained by rendering the candidate object's rendering data. The background layer image is pre-specified or created using image generation techniques or other image processing techniques. For example, see [link to example]. Figure 2The target image is a composite of a foreground layer image and a background layer image. The foreground layer image is obtained based on the rendering data of the candidate object and is used to display the features of the candidate object.
[0038] The technical solution provided in this application can be used in various scenarios such as video conferencing and live streaming. Taking a live streaming scenario as an example, the candidate object can be something shared between the host and viewers during the live stream. Optionally, the candidate object can be a purchasable product or service. For example, if the target live stream is mainly used for the host and viewers to share information about various brands and models of vehicles, the candidate object would be the various brands and models of vehicles shared in the target live stream. In this scenario, the target image created using the technical solution provided in this application can be used as a background image during the live stream.
[0039] It is also important to emphasize that the candidate objects correspond to the use cases of the target image. For example, in a live streaming scenario, since the candidate objects could be things that the host and viewers want to share during the live stream in the target live streaming room, the candidate objects correspond to the target live streaming room.
[0040] S120. Sort multiple candidate objects according to preset sorting rules to obtain the target sequence.
[0041] The preset sorting rule is pre-specified and used to sort multiple candidate objects. This application does not limit the specific type of the preset sorting rule. The target sequence is the sorted result of multiple candidate objects.
[0042] For example, if the candidate object is a product, the preset sorting rule could be, for example, sorting the candidate objects by price. Alternatively, the preset sorting rule could be, for example, placing the most popular candidate object first in the target sequence, and sorting the remaining candidate objects according to their similarity to the first-ranked candidate object and / or their own popularity value.
[0043] The specific implementation method of this step may differ depending on the preset sorting rules.
[0044] For example, if the preset sorting rules include: placing the most popular candidate object at the first position in the target sequence; and sorting the remaining candidate objects according to their similarity to the first-ranked candidate object and / or their own popularity value, the implementation method of this step may include: determining a first candidate object and a second candidate object among multiple candidate objects based on preset screening conditions; the first candidate object meets the preset screening conditions, while the second candidate object does not meet the preset screening conditions; the preset screening conditions include the candidate object having the highest popularity value; determining the similarity between the second candidate object and the first candidate object; and determining the position of each second candidate object in the target sequence according to the similarity between the second candidate object and the first candidate object and / or the popularity value of the second candidate object, thereby obtaining the target sequence.
[0045] The popularity value is a parameter used to characterize the popularity of the corresponding candidate. Optionally, the popularity value of a candidate may include at least one of the following: the number of followers, favorites, purchases, reviews, shares, views, inquiries, and likes.
[0046] "The first candidate meets the preset screening criteria, while the second candidate does not," means that the first candidate is the most popular candidate among all candidates corresponding to the target live stream. All other candidates corresponding to the target live stream besides the first candidate are considered second candidates.
[0047] Based on the similarity between the second candidate object and the first candidate object, the position of each second candidate object in the target sequence is determined to obtain the target sequence. For example, it may include: arranging the second candidate objects in descending order of similarity between the second candidate object and the first candidate object, after the first candidate object, to obtain the target sequence.
[0048] Based on the popularity value of the second candidate object, the position of each second candidate object in the target sequence is determined to obtain the target sequence. For example, it may include: arranging the second candidate objects in descending order of popularity value after the first candidate object to obtain the target sequence.
[0049] Based on the similarity between the second candidate object and the first candidate object and the popularity value of the second candidate object, the position of each second candidate object in the target sequence is determined to obtain the target sequence. For example, it may include: determining the score of each second candidate object based on the similarity between the second candidate object and the first candidate object and the popularity value of the second candidate object; and arranging the second candidate objects in descending order of their scores after the first candidate object to obtain the target sequence.
[0050] Candidate vehicles typically possess a variety of characteristics, encompassing multiple aspects. For example, if the candidate vehicle is a vehicle, these characteristics include performance features (such as engine power, torque, acceleration, fuel economy, and braking performance), configuration features (such as the number of airbags, anti-lock braking system, whether the seats have heating / ventilation functions, in-vehicle air conditioning performance, automatic parking, and autonomous driving assistance systems), vehicle size features (such as body length, width, height, and wheelbase), interior features (such as the texture of interior materials, color scheme, and center console design), and usage features (such as sedans, SUVs, MPVs, and commercial vehicles).
[0051] Optionally, the similarity between the second candidate object and the first candidate object can be determined based on one or more features of the second candidate object and the first candidate object. In practice, this application does not limit which features(s) are specifically used to determine the similarity between the second candidate object and the first candidate object.
[0052] S130. According to the target sequence, perform image rendering based on the rendering data of the candidate objects in sequence to obtain the foreground layer image corresponding to the candidate objects.
[0053] The foreground layer image corresponding to the candidate object is a two-dimensional image obtained by rendering the rendering data of the candidate object. It is then combined with the background layer image obtained in S110 to obtain the final target image.
[0054] Optionally, in practical applications, when rendering any candidate object, the rendering data of the candidate object is first rendered as a 3D model, and then the 3D model is converted into a 2D image. This setting can better restore the candidate object, allowing the foreground layer image corresponding to the candidate object to more accurately display the detailed features of the candidate object.
[0055] S140. During the image display process, in response to the switching command to switch to the target object, the foreground layer image and background layer image corresponding to the target object are combined to obtain the target image corresponding to the target object and displayed; the target object is an object among multiple candidate objects.
[0056] Switching to the target object can be, for example, an instruction indicating that the target image corresponding to the target object should be displayed.
[0057] There are various times when the switching instruction to switch to the target object can be generated, and this application does not limit this. For example, the timing of generating the switching instruction to switch to the target object includes: detecting that the user has selected an option to display a target image corresponding to the target object, or detecting that a preset object switching condition is met.
[0058] In this context, the user selects an option to display a target image corresponding to the target object. This could be triggered by the user performing an action (such as clicking, dragging, or hovering) on the option. In a live streaming scenario, "detecting that a preset object switching condition is met" could be, for example, pre-setting the object switching condition to include the host saying a preset statement or phrase during the target image display, such as "Next, let's talk about the next car." When the host says "Next, let's talk about the next car," the next car in the target sequence will be selected as the target vehicle, and a switching command will be generated to switch to the target object.
[0059] In a live streaming scenario, a target image corresponding to the target object is displayed. For example, the target image corresponding to the target object can be used as the background of the live stream so that it is displayed on the live stream page. The live stream page can be the page that viewers see when they enter the target live stream room while it is in progress.
[0060] The above technical solution renders images sequentially based on the rendering data of candidate objects according to a target sequence, obtaining a foreground layer image corresponding to each candidate object. During image display, in response to a switching command to the target object, the foreground layer image and background layer image corresponding to the target object are composited to obtain and display the target image. The target object is one of multiple candidate objects. In practice, rendering candidate objects is usually time-consuming, while compositing the foreground layer image and background layer image is usually quick. The essence of the above technical solution is to pre-render each candidate object to obtain a foreground layer image corresponding to each candidate object. When a switching command for a candidate object is detected, the previously rendered foreground layer image and background layer image corresponding to that candidate object can be directly called for compositing, instead of starting to render the foreground layer image corresponding to the candidate object only after the switching command is detected. This can significantly shorten the time interval from detecting the switching command to displaying the target image corresponding to the switching command, enabling rapid creation and timely display of the target image, thus synchronizing the image display and sharing process. If the technical solution provided in this application is applied to a live streaming scenario, the utilization rate of the live streaming background can be improved.
[0061] Figure 3A flowchart of another image creation method provided in this application is given. See also... Figure 3 The image creation method may include:
[0062] S210, Obtain the background layer image and rendering data of multiple candidate objects.
[0063] S220. Sort multiple candidate objects according to a preset sorting rule to obtain a target sequence. The candidate object at the beginning of the target sequence is the first candidate object, and all objects after the first candidate object in the target sequence are second candidate objects.
[0064] S230. Before the image display begins, the image is rendered based on the rendering data of the first candidate object to obtain the foreground layer image corresponding to the first candidate object.
[0065] S240. Combine the foreground layer image and the background layer image corresponding to the first candidate object to obtain the target image corresponding to the first candidate object.
[0066] S250. In response to the image display start command, display the target image corresponding to the first candidate object, and render the image sequentially based on the rendering data of the second candidate object according to the target sequence to obtain the foreground layer image corresponding to the second candidate object.
[0067] S260. During the image display process, in response to the switching instruction to switch to the second candidate object, the foreground layer image and background layer image corresponding to the second candidate object are combined to obtain the target image corresponding to the second candidate object and displayed.
[0068] Continuing with the live streaming scenario as an example, before the live stream begins, only the foreground layer image corresponding to the first candidate object is rendered; the foreground layer image corresponding to the second candidate object is not rendered. Furthermore, before the live stream begins, the foreground layer image corresponding to the first candidate object is composited with the background layer image to obtain the target image corresponding to the first candidate object. When the live stream start command is detected, the target image corresponding to the first candidate object is directly displayed. During the display of the target image corresponding to the first candidate object, the foreground layer images corresponding to the second candidate objects are rendered sequentially according to their order in the target sequence. Subsequently, when a switch command to a specific second candidate object is detected, the previously rendered foreground and background layer images corresponding to that second candidate object are retrieved to obtain the target image corresponding to the desired candidate object, which is then displayed.
[0069] The purpose of this setting is to rationally plan the rendering timing of the foreground layer image corresponding to each candidate object and the compositing timing with the background layer image, thereby rationally allocating the computing resources used to create the target image and ensuring that the time from detecting the instruction to displaying the target image corresponding to the instruction is short.
[0070] Based on the above technical solutions, there are alternatively multiple specific methods for "obtaining the background layer image," and this application does not limit this. For example, "obtaining the background layer image" may include: obtaining target subject information; and generating a background layer image based on the target subject information.
[0071] Target theme information can be, for example, the core points set for the shared content or a descriptive information about the sharing background. Taking a live streaming scenario as an example, target theme information can be, for example, a descriptive information about the core points set for a single live stream in a target live streaming room. It is used to reflect the core information that the live streaming room wants to convey in that live stream. For example, the target theme information of a live stream may include, but is not limited to, at least one of the following: a descriptive information about the festival targeted by the live stream, a descriptive information about the event targeted by the live stream, and a descriptive information about the business purpose of the live stream.
[0072] Based on the target theme information, a background layer image is generated. For example, the target theme information can be used as a prompt message and input into the image generation module to obtain the background layer image.
[0073] By setting up a background layer image based on the target topic information, this background layer image can become a tool for conveying the target topic information, helping other users quickly understand the theme of the sharing session. In a live streaming scenario, this setting can help viewers quickly understand the theme of the live stream.
[0074] Furthermore, generating a background layer image based on the target theme information may include: generating candidate background images based on the target theme information; cropping the candidate background images based on the features of preset graphic elements to obtain the background layer image; the preset graphic elements include at least one of the following: a foreground layer image corresponding to the candidate object, a functional component displayed on the image display page, and graphic elements used to decorate the image display page. The image display page is used to display the target object.
[0075] For example, the candidate background image can be an image directly generated based on the target subject information.
[0076] Taking a live streaming scenario as an example, the image display page can be the live streaming page. The functional components displayed on the image display page may include one or more of the following: a link to the product being introduced by the host in real time (also called a product card in some scenarios); an interactive panel for posting comments or interacting with the host (also called a comment section or public chat in some scenarios); an object display panel for centrally displaying candidate objects to be shared in the live stream; and a component for displaying the live stream name. For example, in... Figure 4 In the image display page, component 1 displays the live stream name, component 2 is an object display panel showcasing candidate objects to be shared, and component 3 is an interactive panel for posting comments or interacting with the host. Components 1, 2, and 3 are all functional components displayed on the image display page.
[0077] Graphic elements used to decorate image display pages can be, for example, ambient stickers displayed on the image display page to create an atmosphere. Specifically, taking a live streaming scenario as an example, graphic elements used to decorate the live streaming page of a target live streaming room can be, for example, stickers related to specific holidays or events, or interactive stickers such as applause, hearts, and smiley faces.
[0078] The features of a preset graphic element can be, for example, features related to the appearance of the preset graphic element, such as shape, size, or color.
[0079] In practice, if certain areas of the candidate background image have complex patterns or colors similar to the preset graphic element, and if these areas are too close to the preset graphic element, the contrast between the preset graphic element and the pattern in that area will be low, causing the graphic element to be submerged and making it difficult for other users to quickly distinguish the preset graphic element. To address this, by setting features based on the preset graphic element, the candidate background image is cropped to obtain a background layer image. This involves selecting areas from the candidate background image that best highlight the preset graphic element, cropping them, and using the cropped image as the background layer image. This improves the recognizability of the preset graphic element.
[0080] In practice, there are various specific methods for "extracting candidate background images based on the features of preset graphic elements to obtain a background layer image," and this application does not limit this method. For example, the implementation method of this step includes: dividing the candidate background image into blocks to obtain multiple sub-images; determining the matching degree value between the sub-images and preset graphic elements; determining the target sub-image among the multiple sub-images based on the matching degree value between the sub-images and preset graphic elements and a preset matching degree threshold; and obtaining the background layer image based on the target sub-image.
[0081] The matching degree value between the sub-image and the preset graphic element is used to characterize the degree of influence of the sub-image on the distinguishability of the preset graphic element when the two are displayed at a relatively close distance (such as a preset distance). Optionally, the larger the matching degree value between the sub-image and the preset graphic element, the smaller the influence of the sub-image on the distinguishability of the preset graphic element when the two are displayed at a relatively close distance (such as a preset distance).
[0082] Furthermore, the matching degree value between the sub-image and the preset graphic element can be set, including: determining the color difference between the sub-image and the preset graphic element; determining the complexity score of each sub-image; and determining the matching degree value between the sub-image and the preset graphic element based on the color difference between the sub-image and the preset graphic element and the complexity score of the sub-image.
[0083] When there are multiple preset graphic elements, "determining the color difference between the sub-image and the preset graphic elements" can include: selecting one of the preset graphic elements as a representative, calculating the color difference between the sub-image and the representative preset graphic element; and using the color difference between the sub-image and the representative preset graphic element as the color difference between the sub-image and the preset graphic element. Alternatively, the color difference between the sub-image and each preset graphic element can be calculated separately, and the average of the color differences between the sub-image and each preset graphic element can be used as the color difference between the sub-image and the preset graphic element. The CMC color difference formula can be used for calculation. A larger color difference between the sub-image and the preset graphic elements means that the sub-image is less likely to overwhelm the preset graphic elements.
[0084] There are several ways to determine the complexity score of each sub-image. Optionally, a discrete cosine transform can be performed on the image to obtain the transform result; based on the transform result, the proportion of high-frequency components can be determined. If the proportion of high-frequency components in a sub-image is higher, the pattern of the sub-image is more complex, and the complexity score of the sub-image is lower.
[0085] "Based on the color difference between the sub-image and the preset graphic elements, as well as the complexity score of the sub-image, determine the matching degree value between the sub-image and the graphic elements associated with the target live broadcast room." For example, it can be to calculate the average value of the color difference between the sub-image and the preset graphic elements, as well as the complexity score of the sub-image; and select the sub-image with an average value greater than a set threshold as the target sub-image.
[0086] There are various specific methods for "obtaining a background layer image based on a target sub-image", and this application does not limit this method. For example, multiple target sub-images can be stitched together to obtain a background layer image; or, based on the target sub-images, an image generation technique can be used to perform an image expansion operation to obtain a background layer image.
[0087] The above technical solution can make the final background layer image better highlight the preset graphic elements, especially the candidate object image, making it easier for users to distinguish the preset graphic elements.
[0088] It should be noted that, for the sake of simplicity, the foregoing method embodiments are all described as a series of actions. However, those skilled in the art should understand that the present invention is not limited to the described order of actions, because according to the present invention, some steps can be performed in other orders or simultaneously. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions and modules involved are not necessarily essential to the present invention.
[0089] Figure 5 This is a schematic diagram of an image processing apparatus according to an embodiment of this disclosure. The image processing apparatus provided in this embodiment can be configured in a client or in a server. See also Figure 5 The image-making apparatus specifically includes:
[0090] The acquisition module 310 is used to acquire the background layer image and the rendering data of multiple candidate objects;
[0091] The sorting module 320 is used to sort the multiple candidate objects according to a preset sorting rule to obtain a target sequence;
[0092] The rendering module 330 is used to render images sequentially based on the rendering data of the candidate objects according to the target sequence, so as to obtain a foreground layer image corresponding to the candidate objects;
[0093] The switching module 340 is used to, in response to a switching command to switch to the target object during the image display process, combine the foreground layer image and the background layer image corresponding to the target object to obtain and display the target image corresponding to the target object; the target object is an object among the plurality of candidate objects.
[0094] Furthermore, the sorting module 320 is used for:
[0095] Among the multiple candidate objects, a first candidate object and a second candidate object are determined based on preset screening conditions; the first candidate object meets the preset screening conditions, while the second candidate object does not meet the preset screening conditions; the preset screening conditions include: the candidate object has the highest popularity value; the popularity value is a parameter used to characterize the popularity of the corresponding candidate object;
[0096] Determine the similarity between the second candidate object and the first candidate object;
[0097] Based on the similarity between the second candidate object and the first candidate object and / or the popularity value of the second candidate object, the position of each second candidate object in the target sequence is determined, and the target sequence is obtained.
[0098] Furthermore, the rendering module 330 is used for:
[0099] Before the image display begins, image rendering is performed based on the rendering data of the first candidate object to obtain a foreground layer image corresponding to the first candidate object.
[0100] The foreground layer image corresponding to the first candidate object is combined with the background layer image to obtain the target image corresponding to the first candidate object;
[0101] In response to the image display start command, the target image corresponding to the first candidate object is displayed, and the image is rendered sequentially based on the rendering data of the second candidate object according to the target sequence to obtain the foreground layer image corresponding to the second candidate object;
[0102] Switching module 340 is used for:
[0103] During image display, in response to a switching command to switch to the second candidate object, the foreground layer image and the background layer image corresponding to the second candidate object are combined to obtain the target image corresponding to the second candidate object and then displayed.
[0104] Furthermore, module 310 is used for:
[0105] Obtain target topic information;
[0106] Based on the target theme information, a background layer image is generated.
[0107] Furthermore, module 310 is used for:
[0108] Based on the target theme information, candidate background images are generated;
[0109] Based on the features of preset graphic elements, the candidate background image is cropped to obtain the background layer image; the preset graphic elements include at least one of the following: a foreground layer image corresponding to the candidate object, a functional component displayed on the image display page, and graphic elements used to decorate the image display page; the image display page is used to display the target object.
[0110] Furthermore, module 310 is used for:
[0111] The candidate background image is divided into blocks to obtain multiple sub-images;
[0112] Determine the matching degree value between the sub-image and the preset graphic element;
[0113] Based on the matching degree value between the sub-image and the preset graphic element, and the preset matching degree threshold, the target sub-image is determined among the plurality of sub-images;
[0114] The background layer image is obtained based on the target sub-image.
[0115] Furthermore, module 310 is used for:
[0116] Determine the color difference between the sub-image and the preset graphic element;
[0117] Determine the complexity score of each of the sub-images;
[0118] Based on the color difference between the sub-image and the preset graphic element, and the complexity score of the sub-image, the matching degree value between the sub-image and the preset graphic element is determined.
[0119] The image production apparatus provided in this disclosure can execute the steps performed by the client or server in the image production method provided in this disclosure, and has the execution steps and beneficial effects, which will not be described in detail here.
[0120] Figure 6 This is a schematic diagram of the structure of an electronic device according to an embodiment of this disclosure. See below for details. Figure 6 The diagram illustrates a structural schematic suitable for implementing the electronic device 1000 in the embodiments of this disclosure. The electronic device 1000 in the embodiments of this disclosure may include, but is not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., in-vehicle navigation terminals), wearable electronic devices, etc., as well as fixed terminals such as digital TVs, desktop computers, smart home devices, etc. Figure 6 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.
[0121] like Figure 6 As shown, the electronic device 1000 may include a processing device (e.g., a central processing unit, a graphics processor, etc.) 1001, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1002 or a program loaded from a storage device 1008 into a random access memory (RAM) 1003 to implement the image creation method as described in the embodiments of this disclosure. The RAM 1003 also stores various programs and information required for the operation of the electronic device 1000. The processing device 1001, ROM 1002, and RAM 1003 are interconnected via a bus 1004. An input / display (I / O) interface 1005 is also connected to the bus 1004.
[0122] Typically, the following devices can be connected to the I / O interface 1005: input devices 1006 including, for example, a touchscreen, touchpad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; display devices 1007 including, for example, a liquid crystal display (LCD), speaker, vibrator, etc.; storage devices 1008 including, for example, magnetic tape, hard disk, etc.; and communication devices 1009. Communication device 1009 allows electronic device 1000 to exchange information with other devices wirelessly or via wired communication. Although Figure 6 An electronic device 1000 with various devices is shown; however, it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed alternatively.
[0123] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts, thereby implementing the image creation method as described above. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 1009, or installed from a storage device 1008, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, it performs the functions defined in the methods of embodiments of this disclosure.
[0124] It should be noted that the computer-readable medium described in this disclosure can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include information signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated information signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.
[0125] In some implementations, clients and servers may communicate using any known or future network protocol, such as HTTP (Hypertext Transfer Protocol), and may interconnect with any form or medium of digital information communication (e.g., a communication network). Examples of communication networks include local area networks (“LANs”), wide area networks (“WANs”), the Internet (e.g., the Internet of Things), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any known or future network.
[0126] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device.
[0127] The aforementioned computer-readable medium carries one or more programs that, when executed by the electronic device, cause the electronic device to:
[0128] Obtain the background layer image and rendering data for multiple candidate objects;
[0129] The multiple candidate objects are sorted according to a preset sorting rule to obtain a target sequence;
[0130] According to the target sequence, image rendering is performed sequentially based on the rendering data of the candidate objects to obtain the foreground layer image corresponding to the candidate objects;
[0131] During image display, in response to a switching command to switch to the target object, the foreground layer image and the background layer image corresponding to the target object are combined to obtain a target image corresponding to the target object and displayed; the target object is an object among the plurality of candidate objects.
[0132] Optionally, when one or more of the above-described procedures are executed by the electronic device, the electronic device may also perform other steps described in the above embodiments.
[0133] Computer program code for performing the operations of this disclosure can be written in one or more programming languages or a combination thereof, including but not limited to object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0134] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0135] The units described in the embodiments of this disclosure can be implemented in software or hardware. The names of the units are not, in some cases, intended to limit the specific unit.
[0136] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. For example, exemplary types of hardware logic components that can be used, without limitation, include: Field Programmable Gate Arrays (FPGAs), Application-Specific Integrated Circuits (ASICs), Application Standard Products (ASSPs), System-on-Chip (SoCs), Complex Programmable Logic Devices (CPLDs), and so on.
[0137] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0138] According to one or more embodiments of this disclosure, this disclosure provides an electronic device, including:
[0139] One or more processors;
[0140] Memory, used to store one or more programs;
[0141] When the one or more programs are executed by the one or more processors, the one or more processors implement any of the image creation methods provided in this disclosure.
[0142] According to one or more embodiments of the present disclosure, the present disclosure provides a computer-readable storage medium having a computer program stored thereon that, when executed by a processor, implements an image creation method as described in any of the present disclosure.
[0143] This disclosure also provides a computer program product, which includes a computer program or instructions that, when executed by a processor, implement the image creation method described above.
[0144] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0145] The above description is merely a specific embodiment of this disclosure, enabling those skilled in the art to understand or implement it. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of this disclosure. Therefore, this disclosure is not to be limited to the embodiments described herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. An image creation method, characterized in that, include: Obtain the background layer image and rendering data for multiple candidate objects; The multiple candidate objects are sorted according to a preset sorting rule to obtain a target sequence; The candidate object located at the beginning of the target sequence is the first candidate object, and all objects located after the first candidate object in the target sequence are the second candidate objects; Before the image display begins, image rendering is performed based on the rendering data of the first candidate object to obtain a foreground layer image corresponding to the first candidate object. The foreground layer image corresponding to the first candidate object is combined with the background layer image to obtain the target image corresponding to the first candidate object; In response to the image display start command, the target image corresponding to the first candidate object is displayed, and the image is rendered sequentially based on the rendering data of the second candidate object according to the target sequence to obtain the foreground layer image corresponding to the second candidate object; During image display, in response to a switching command to switch to the second candidate object, the foreground layer image and the background layer image corresponding to the second candidate object are combined to obtain the target image corresponding to the second candidate object and then displayed.
2. The method according to claim 1, characterized in that, The step of sorting the multiple candidate objects based on a preset sorting rule to obtain a target sequence includes: Among the multiple candidate objects, a first candidate object and a second candidate object are determined based on preset screening conditions; the first candidate object meets the preset screening conditions, while the second candidate object does not meet the preset screening conditions; the preset screening conditions include: the candidate object has the highest popularity value; the popularity value is a parameter used to characterize the popularity of the corresponding candidate object; Determine the similarity between the second candidate object and the first candidate object; Based on the similarity between the second candidate object and the first candidate object and / or the popularity value of the second candidate object, the position of each second candidate object in the target sequence is determined, and the target sequence is obtained.
3. The method according to claim 1, characterized in that, The process of obtaining the background layer image includes: Obtain target topic information; Based on the target theme information, a background layer image is generated.
4. The method according to claim 3, characterized in that, The step of generating a background layer image based on the target theme information includes: Based on the target theme information, candidate background images are generated; Based on the features of preset graphic elements, the candidate background image is cropped to obtain the background layer image; the preset graphic elements include at least one of the following: a foreground layer image corresponding to the candidate object, a functional component displayed on the image display page, and graphic elements used to decorate the image display page; the image display page is used to display the target image.
5. The method according to claim 4, characterized in that, The step of cropping the candidate background image based on the features of preset graphic elements to obtain the background layer image includes: The candidate background image is divided into blocks to obtain multiple sub-images; Determine the matching degree value between the sub-image and the preset graphic element; Based on the matching degree value between the sub-image and the preset graphic element, and the preset matching degree threshold, the target sub-image is determined among the plurality of sub-images; The background layer image is obtained based on the target sub-image.
6. The method according to claim 5, characterized in that, Determining the matching degree value between the sub-image and the preset graphic element includes: Determine the color difference between the sub-image and the preset graphic element; Determine the complexity score for each of the sub-images; Based on the color difference between the sub-image and the preset graphic element, and the complexity score of the sub-image, the matching degree value between the sub-image and the preset graphic element is determined.
7. An image processing apparatus, characterized in that, include: The acquisition module is used to acquire the background layer image and rendering data of multiple candidate objects; The sorting module is used to sort the multiple candidate objects according to a preset sorting rule to obtain a target sequence; The candidate object located at the beginning of the target sequence is the first candidate object, and all objects located after the first candidate object in the target sequence are the second candidate objects; The rendering module is used to render the image based on the rendering data of the first candidate object before the image display begins, so as to obtain the foreground layer image corresponding to the first candidate object. The foreground layer image corresponding to the first candidate object is combined with the background layer image to obtain the target image corresponding to the first candidate object; In response to the image display start command, the target image corresponding to the first candidate object is displayed, and the image is rendered sequentially based on the rendering data of the second candidate object according to the target sequence to obtain the foreground layer image corresponding to the second candidate object; The switching module is used to, in response to a switching command to switch to the second candidate object during the image display process, combine the foreground layer image and the background layer image corresponding to the second candidate object to obtain and display the target image corresponding to the second candidate object.
8. An electronic device, characterized in that, The electronic device includes: One or more processors; Storage device for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any one of claims 1-6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1-6.
Citation Information
Patent Citations
Microphone-connected live broadcast video image rendering method and device and video live broadcast system
CN116962748A
Generation method and device of display image of target object, equipment and storage medium
CN117152302A
Information display method and device, electronic equipment and storage medium
CN118555437A
Image processing method and device, electronic equipment and storage medium
CN118898660A