An image processing method, apparatus, electronic device, and storage medium
By automatically identifying virtual characters and synthesizing images in a graphical user interface, the problems of complex image processing operations and poor quality in existing technologies are solved, achieving automated image processing and efficient integration of real and virtual information.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUANGZHOU BOGUAN TELECOMM TECH LTD
- Filing Date
- 2026-01-26
- Publication Date
- 2026-06-19
AI Technical Summary
In existing technologies, the processing of real-shot images requires manual operation by the user, which is complex and results in large differences in image quality, making it difficult to achieve an efficient combination of real and virtual information in the image.
By displaying images in a graphical user interface, responding to user marking operations on target objects, automatically identifying virtual characters associated with the target objects, and generating replacement images based on character appearance parameters, image compositing is achieved, simplifying user operation processes and improving image quality.
It automates image processing, simplifies user operations, improves image processing efficiency and quality, enriches the replacement effects of virtual character images, and enhances user creation and social interaction methods.
Smart Images

Figure CN122244061A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of image processing technology, and in particular to an image processing method, apparatus, electronic device and storage medium. Background Technology
[0002] With the continuous development of computer technology, users' demands for image quality and visual appeal are constantly increasing. Specifically, users can perform image processing on captured images to combine real and virtual information in the images.
[0003] In the process of developing this disclosure, the inventors discovered at least the following technical problems in the prior art: the processing of real-shot images is generally achieved manually by the user using third-party software, which requires high levels of image processing skills from the user and is quite difficult. Specifically, the manual image processing process generally includes image cutout and overlay, which requires processing each person in the image one by one, making the operation complex and tedious, and resulting in significant differences in image quality. Summary of the Invention
[0004] This disclosure provides an image processing method, apparatus, electronic device, and storage medium to automate the processing of captured images, enable virtual avatars to automatically update the first target object in the image, and improve image processing efficiency and image quality.
[0005] According to one aspect of this disclosure, an image processing method is provided, applied to a terminal device, comprising: A first image is displayed in a graphical user interface, the first image containing an image region of at least one target object; In response to a tagging operation on a first target object among the at least one target object, a first virtual character associated with the first target object is determined; Generate a replacement image based on the character appearance parameters of the first virtual character; The replacement image is combined with the first image to obtain the second image.
[0006] According to another aspect of this disclosure, an image processing apparatus is provided, comprising: An image display module is used to display a first image in a graphical user interface, wherein the first image contains an image area of at least one target object; A virtual role determination module is configured to determine a first virtual role associated with the first target object in response to a marking operation on a first target object among the at least one target object; The replacement image generation module is used to generate a replacement image based on the character appearance parameters of the first virtual character. An image synthesis module is used to synthesize the replacement image with the first image to obtain a second image.
[0007] According to another aspect of this disclosure, an electronic device is provided, the electronic device comprising: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the image processing method described in any embodiment of this disclosure.
[0008] According to another aspect of this disclosure, a computer-readable storage medium is provided that stores computer instructions for causing a processor to execute and implement the image processing method described in any embodiment of this disclosure.
[0009] According to another aspect of this disclosure, a computer program product is provided, characterized in that the computer program product includes a computer program that, when executed by a processor, implements the image processing method described in any embodiment of this disclosure.
[0010] This disclosure provides an image processing method, apparatus, electronic device, and storage medium. The method displays a first image in a graphical user interface, the first image containing an image region of at least one target object. In response to a marking operation on the first target object among the at least one target object, a first virtual character associated with the first target object is determined. A replacement image is generated based on the character appearance parameters of the first virtual character. The replacement image is then composited with the first image to obtain a second image. This disclosure significantly simplifies the user operation process through automated target object detection and virtual character mapping processing, avoiding the tedious steps of manual annotation and image cutout, and improving the interactive experience. Through precise acquisition of character appearance parameters and replacement image generation technology, diverse virtual character image replacement effects are achieved, enriching the user's creative possibilities and social interaction methods.
[0011] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description
[0012] To more clearly illustrate the technical solutions in the embodiments of this disclosure, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0013] Figure 1 This is a flowchart of an image processing method provided in an embodiment of this disclosure; Figure 2 This is a schematic diagram of a graphical user interface provided in an embodiment of this disclosure; Figure 3 This is a schematic diagram of another graphical user interface provided in an embodiment of this disclosure; Figure 4 This is a schematic diagram of another graphical user interface provided in an embodiment of this disclosure; Figure 5 This is a schematic diagram of the structure of an image processing apparatus provided in an embodiment of this disclosure; Figure 6 This is a schematic diagram of the structure of an electronic device provided in the embodiments of this disclosure. Detailed Implementation
[0014] To enable those skilled in the art to better understand the present disclosure, the technical solutions of the present disclosure will be clearly and completely described below with reference to the accompanying drawings of the embodiments. Obviously, the described embodiments are only some embodiments of the present disclosure, and not all embodiments. Based on the embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present disclosure.
[0015] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this disclosure are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this disclosure described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0016] Figure 1This is a flowchart of an image processing method provided in an embodiment of this disclosure. This embodiment is applicable to situations where a first image is displayed on the display component of a terminal device, and a second image is obtained by updating the image area of a target object in the first image with a replacement image corresponding to a virtual image. This method can be executed by an image processing device, which can be implemented in hardware and / or software. The image processing device can be configured in a terminal device, which is a device with image display capabilities, and may include, but is not limited to, mobile phones, tablet computers, and cameras. Figure 1 As shown, the method includes: S110. Display a first image in a graphical user interface, wherein the first image contains an image region of at least one target object.
[0017] S120, in response to a marking operation on a first target object among the at least one target object, determine a first virtual character associated with the first target object.
[0018] S130. Generate a replacement image based on the character appearance parameters of the first virtual character.
[0019] S140. Combine the replacement image with the first image to obtain the second image.
[0020] In this embodiment, the terminal device may be equipped with a display component, which may include a display screen or a touch screen, etc., for displaying a graphical user interface and enabling interaction between the terminal device and the user. The terminal device displays a first image through the graphical user interface displayed by the display component.
[0021] The first image can be a real image captured by an image acquisition device. For example, the terminal device is a device with image acquisition capabilities, and correspondingly, the image acquisition device can be a terminal device. The terminal device acquires the first image through an image acquisition component (such as a camera) and displays the first image through a graphical user interface displayed by a display component. Alternatively, the terminal device receives the first image transmitted by the image acquisition device and displays the first image through a graphical user interface displayed by a display component.
[0022] In some embodiments of this disclosure, the terminal device displays a graphical user interface (GUI), which may include controls, including image upload controls and / or image capture controls. For example, in response to a trigger operation on the image upload control, an image selection page is displayed. The image selection page includes locally stored selectable images, which may be pre-captured by the terminal device or transmitted externally. In response to a selection operation on the image selection page, a first image is determined and displayed in the GUI. As another example, in response to a trigger operation on the image capture control, an image capture component is invoked, an image capture page is displayed, and in response to an image capture operation on the image capture page, a first image is obtained and displayed in the GUI.
[0023] In some cases, an interactive page for an image processing application can be displayed through a graphical user interface (GUI). This GUI displays a first image and a processed second image. The interactive page can be triggered by launching the image processing application, activating image processing controls within the application, or using set gestures. Similarly, in some cases, an interactive page for a virtual game application can be displayed through a GUI. This interactive page displays a first image and a processed second image. The interactive page can also be triggered by activating image processing controls within the virtual game application or using set gestures.
[0024] The first image contains an image region of at least one target object, which can be a person; that is, the image region of the target object can be a portrait region of a real person formed by taking a photograph. In some cases, the first image can be a group photo of at least two people. The first image may also include a background region, the actual content of which can be the environment in which the real people are located, obtained by taking a photograph.
[0025] By updating the image region corresponding to the target object in the first image based on the virtual image corresponding to the virtual character, a second image is obtained that includes a real background image and a virtual image, thus achieving the combination of real information and virtual information.
[0026] Specifically, by identifying the image region of the target object in the first image, a replacement image corresponding to the image region of the target object is determined. This replacement image is determined by a virtual character associated with the target object. The replacement image is then combined with the first image to obtain a second image, which includes a background region and the image region corresponding to the replacement image. The virtual character can be understood as a digital visual image created through computer graphics, artificial intelligence, or motion capture, and may include one or more game characters or cartoon / anime characters.
[0027] When a first image includes two or more target objects, virtual characters can be replaced for either local or all target objects in the first image to obtain different second images. For example, a replacement image corresponding to the virtual character associated with a local target object in the first image is determined, and this replacement image is merged with the first image. The resulting second image includes both the virtual character and the target object (e.g., a real human figure), achieving the co-framed appearance of the virtual character and the real human figure against a real background. Alternatively, a replacement image corresponding to the virtual character associated with each target object in the first image is determined, and this replacement image is merged with the first image. The resulting second image includes both a real background area and the virtual character, achieving the co-framed appearance of the virtual character against a real background.
[0028] In some embodiments, each target object in the first image is marked so that each target object enters a selectable state. Specifically, the image region of each target object in the first image is identified, a positioning marker is set for the image region of each target object, and the positioning marker of each target object in the first image is displayed in the graphical user interface. The target object with the positioning marker is in a selectable state, and the positioning marker can be a positioning box. The target object is selected by selecting the positioning marker. Here, identifying the image region of each target object in the first image can be understood as performing contour recognition on the target object, and correspondingly, the image region of the target object is the area formed by the contour of the target object.
[0029] By marking each target object in the first image, each target object enters a selectable state, thereby enabling the selection of each target object, improving interactivity, and allowing for flexible processing of at least one target object in the first image.
[0030] By selecting any target object in the selectable state, the selected target object is taken as the first target object, the first virtual role associated with the first target object is determined, and a replacement image corresponding to the first virtual role is generated.
[0031] In some embodiments, in response to a marking operation on a first target object among the at least one target object, a first virtual character associated with the first target object is determined, wherein the marking operation can be understood as an operation for determining the first virtual character associated with the first target object.
[0032] In one scenario, the tagging operation may include an input operation for identifying a virtual character. Specifically, in response to a tagging operation targeting a first target object among the at least one target object, an identification input box is displayed. In response to input in the identification input box, a first virtual character associated with the first target object is determined. Each virtual character corresponds to a virtual character identifier, which may be information such as the virtual character's account information, nickname, or a unique string.
[0033] In one scenario, the marking operation may include a search operation for a virtual character. Specifically, in response to a marking operation for a first target object among the at least one target object, a search box is displayed. In response to an input operation for search information in the search box and a search trigger operation (e.g., a click operation on a search control), search processing is performed based on the search information, and the search results are displayed in a graphical user interface. The search results may include identification information of virtual characters matching the search information. The identification information of the virtual characters may include at least one of the following: the character's appearance, account information, and nickname. In response to a selection operation of the displayed character's appearance, a first virtual character associated with the first target object is determined. The search information may be descriptive information such as the virtual character's account information, nickname, or character type.
[0034] For example, see Figure 2 , Figure 2 This is a schematic diagram of a graphical user interface provided in an embodiment of this disclosure. Figure 2 The graphical user interface includes an image display area 10, which displays a first image. The first image includes a target object 20 and a location identifier 30 for the target object. It is understood that... Figure 2 The example shows two target objects 20, whose appearance and location are provided as examples. In other embodiments, target objects 20 may be one or more. In response to a marking operation (e.g., a click operation) on the location identifier 30 of the target object, a search sub-region 40 is displayed in the graphical user interface. In response to a search operation on the search sub-region 40, the search information is matched against a virtual character database. The virtual appearances of the successfully matched virtual characters are used to form search results, which are then displayed in the display sub-region 50. Figure 2 The display sub-area 50 displays the virtual images of multiple searched virtual characters, i.e., the character images corresponding to the virtual characters. In response to the selection operation of any character image in the display sub-area 50, the first virtual character associated with the first target object is determined.
[0035] In one scenario, determining a first virtual character associated with the first target object in response to a marking operation on the first target object among the at least one target objects includes: displaying a character image list in response to the marking operation on the first target object among the at least one target objects; and determining the first virtual character associated with the first target object in response to a selection operation on the character image list. The marking operation may include a selection operation on a target object, specifically a selection operation on a location marker of the target object, which may be a click operation on the location marker of the target object. The character image list can be understood as a list used to display the virtual images of multiple virtual characters. The virtual images in the character image list may be in image form, facilitating a visual presentation of the virtual character's image to the user. The selection operation on the character image list may include a click operation on a character image in the character image list.
[0036] In response to a marking operation (e.g., a click operation) on the location identifier 30 of the target object, a sub-region 50 is displayed in the graphical user interface. This sub-region 50 displays a list of character images, including identification information for multiple virtual characters. The identification information for each virtual character may include at least one of the following: the character's appearance, account information, and nickname. See, for example... Figure 3 , Figure 3 This is a schematic diagram of a graphical user interface provided in an embodiment of this disclosure. Figure 5 The display sub-area 50 displays the virtual images of multiple virtual characters. The virtual characters in this character image list may include virtual characters associated with the user's account information and virtual characters representing the user's account friends. In response to a selection operation of any character image in the display sub-area 50, a first virtual character associated with a first target object is determined.
[0037] The appearance parameters of the first virtual character are obtained, and a replacement image for the target object is determined based on these appearance parameters. In one case, the appearance parameters of the first virtual character are extracted using an appearance parameter extraction model to obtain the appearance parameters corresponding to the first virtual character. This appearance parameter extraction model can be a neural network model, which can be trained using a sample character image and its appearance parameters.
[0038] In one scenario, the server can store the appearance parameters of virtual characters, with a one-to-one correspondence between the account identifier and the appearance parameters of each virtual character. Accordingly, the account identifier associated with the first virtual character is determined; based on the account identifier, the appearance parameters corresponding to the first virtual character are obtained. Each virtual character corresponds to one account identifier, which can be account information. Specifically, the terminal device sends a parameter request to the server, including the account identifier associated with the first virtual character. The server receives the parameter request, matches the account identifier in the parameter request to obtain the appearance parameters corresponding to the first virtual character, and then sends this information back to the terminal device.
[0039] The character appearance parameters include at least one of the following: facial feature parameters, hairstyle parameters, skin tone parameters, makeup parameters, and clothing parameters. Facial feature parameters can be understood as parameters for constructing the facial model, such as, but not limited to, facial proportion parameters and facial contour parameters. Facial proportion parameters include, but are not limited to, eye distance, eye width, nose length and width, mouth thickness, and chin shape. Facial contour parameters include, but are not limited to, cheekbone height, jaw width, overall facial roundness, and forehead fullness. Hairstyle parameters include, but are not limited to, hair type, hair color, length, bangs type, and volume. Skin tone parameters include, but are not limited to, skin color, attention level, and rosiness. Makeup parameters include makeup parameters for various parts of the face, such as, but not limited to, makeup parameters for the eyes, lips, and face. Clothing parameters can include parameters for various wearable garments, such as parameters for hats, gloves, clothing, accessories, and headwear. The parameters for each type of garment may include, but are not limited to, material, color, pattern, and style.
[0040] A replacement image is generated based on the appearance parameters of a first virtual character. This replacement image can be generated by a terminal device or a server. In one case, the appearance parameters of the first virtual character are transmitted to the server, so that the server generates an image based on the appearance parameters of the first virtual character to obtain the replacement image. The terminal device receives the replacement image from the server. In another case, the terminal device generates the replacement image based on the appearance parameters of the first virtual character using a rendering engine or an image compositing module.
[0041] In some embodiments, a replacement image of the overall target object is formed based on the character appearance parameters of the first virtual character; in some embodiments, a replacement image of a partial target object is formed based on the local character appearance parameters of the first virtual character. Optionally, generating a replacement image based on the character appearance parameters of the first virtual character includes: in response to a selection operation for a generated content option, determining target generated content, wherein the generated content option is an option determined based on the character image parameters of the first virtual character; and generating the replacement image based on the character image parameters corresponding to the target generated content.
[0042] The generated content options can be understood as options corresponding to the replaceable parts of the target object. These generated content options are determined based on the character image parameters of the first virtual character, and include at least one of the following: account identifier option, facial appearance option, hairstyle option, and clothing option. Specifically, based on the parameter types included in the character image parameters of the first virtual character, account identifier options and corresponding generated content options can be generated. Parameter types include facial feature parameters, hairstyle parameters, skin tone parameters, makeup parameters, and clothing parameters, etc. At least one of facial feature parameters, skin tone parameters, and makeup parameters can correspond to a facial appearance option, a hairstyle parameter can correspond to a hairstyle option, and a clothing parameter can correspond to a clothing option. For example, if the character image parameters of the first virtual character include hairstyle parameters and clothing parameters, account identifier options, hairstyle options, and clothing options can be generated; if the character image parameters of the first virtual character include hairstyle parameters and facial feature parameters, account identifier options, hairstyle options, and facial appearance options can be generated.
[0043] The generated content options can be selected according to different processing needs of the first target object. The entire first target object can be replaced through the account identification option, and a part of the first target object can be replaced through at least one of the face option, hairstyle option, and clothing option.
[0044] For example, see Figure 4 , Figure 4 This is an example diagram of a user graphical interface provided in an embodiment of this disclosure. See also... Figure 4 , Figure 4The system displays an image display area 10 and a content generation option area 60. The location of the content generation option area 60 within the graphical user interface is not specified here. The content generation option area 60 displays multiple content generation options. In response to a selection operation of at least one content generation option, a target content generation is determined. This target content generation can be a part of a target object to be replaced. For example, the target content generation for the account identifier option is the overall image of the first virtual character; the target content generation for the face option is the face of the first virtual character; the target content generation for the hairstyle option is the hairstyle of the first virtual character; and the target content generation for the clothing option is the clothing of the first virtual character.
[0045] The character image parameters corresponding to the target generated content are read from the character image parameters of the first virtual character, and a replacement image is generated based on these character image parameters. For example, by selecting face and hairstyle options, at least one of the following parameters is determined: hairstyle parameters, facial feature parameters, skin color parameters, makeup parameters, etc., of the first virtual character, and a replacement image including the face and hairstyle of the first virtual character is generated. The face and hairstyle regions of the first target object in the first image are updated using the replacement image composed of the face and hairstyle regions, while keeping the clothing region of the first target object in the first image unchanged.
[0046] By setting the content generation options, targeted image generation can be performed based on the selection of the content generation options mentioned above, which can meet the different processing needs of different users for the first target object and provide flexibility and diversity in image processing.
[0047] In the above embodiments, to improve the matching degree between the substitute image and the first image and to improve the image quality of the second image, the terminal device or server can parse the first target object in the first image to obtain the posture feature information of the first target object. Optionally, the posture feature information of the first target object can be descriptive information such as the action and / or angle of the first target object. Accordingly, the terminal device or server can use the posture feature information of the first target object as auxiliary information to generate a substitute image based on the character image parameters of the first virtual character or the character image parameters corresponding to the target generated content. For example, the first target object is in a left-facing standing posture, and the first virtual character in the substitute image of the first target object is also in a left-facing standing posture. The posture of the first virtual character in the substitute image matches that of the first target object, reducing the sense of incongruity in the second image and improving the image quality of the second image.
[0048] In the above embodiments, the size of the first virtual character in the substitute image matches the size of the first target object. In the above embodiments, the lighting and shadow effects of the first virtual character in the substitute image match the lighting and shadow effects of the first target object. Accordingly, the terminal device or server can parse the first image to obtain the size information and / or image lighting and shadow feature information of the first target object. The terminal device or server can use at least one of the size information, pose feature information, and image lighting and shadow feature information of the first target object as auxiliary information to generate a substitute image based on the character image parameters of the first virtual character or the character image parameters corresponding to the target generated content.
[0049] Based on the above embodiments, the replacement image is combined with the first image to obtain a second image. The image compositing method can be to add the replacement image to the blank area corresponding to the first target object's image area in the first image, or to cover the first target object's image area with the replacement image.
[0050] Optionally, the replacement image and the group photo image are combined to obtain a second image, including: determining the position information of the first target object in the first image; and superimposing the replacement image onto the corresponding position of the first image according to the position information to obtain the second image.
[0051] In one scenario, the positional information of the first target object in the first image can be determined using the object's location identifier. In another scenario, the positional information of the first target object in the first image can be determined based on the coordinates of key points within its image region; these key points can be vertices of the image region. By identifying the positional information of the first target object in the first image, the replacement image and the first image are merged based on this information, thereby improving the image quality of the second image.
[0052] In the above embodiments, the sub-regions corresponding to different parts of the image region of the first target object and the position information of the sub-regions are identified. Based on the target generation content included in the replacement image, the replacement image is added to the corresponding position of the target generation content in the first image to obtain the second image.
[0053] In one scenario, the first image is a composite image of two or more target images. The substitute image for the first target object is merged with the first image to obtain the second image. The substitute image for the second target object in the second image is then merged with the second image to obtain the third image, and so on. The second image, third image, etc., are used here only for image differentiation and can all be used as images for display.
[0054] Based on the above embodiments, when the alternative image is generated based on the character appearance parameters corresponding to the account identifier option, the account identifier of the first virtual character is displayed in the second image. The account identifier of the first virtual character can be set at an associated position of the first target object, which may include, but is not limited to, the position above the head of the first target object.
[0055] Based on the above embodiments, the second image is displayed; in response to a sharing operation on the second image, the second image is sent to a target platform. The target platform here can be the information interaction platform of a game application, or it can be the information interaction platform corresponding to an instant messaging application.
[0056] The technical solution provided in this disclosure involves a terminal device displaying a first image including at least one target object. By generating a replacement image for a first virtual character associated with the first target object in the first image, and merging the replacement image of the first target object with the first image, the automatic updating of the first target object in the first image based on the virtual image of the first virtual character is achieved. The operation is simple, there is no reliance on manual image processing technology, and the image processing efficiency and image processing quality are improved.
[0057] Figure 5 This is a schematic diagram of the structure of an image processing apparatus provided in an embodiment of this disclosure, which can be integrated into a terminal device. Figure 5 As shown, the device includes: an image display module 210, a virtual character determination module 220, a replacement image generation module 230, and an image synthesis module 240.
[0058] Image display module 210 is used to display a first image in a graphical user interface, the first image containing an image area of at least one target object; Virtual role determination module 220 is configured to determine a first virtual role associated with the first target object in response to a marking operation on a first target object among the at least one target object; The replacement image generation module 230 is used to generate a replacement image based on the character appearance parameters of the first virtual character; The image synthesis module 240 is used to synthesize the replacement image with the first image to obtain a second image.
[0059] In this embodiment, the terminal device displays a first image including at least one target object. By generating a replacement image for a first virtual character associated with the first target object in the first image, and merging the replacement image of the first target object with the first image, the automatic updating of the first target object in the first image based on the virtual image of the first virtual character is realized. The operation is simple, there is no reliance on manual image processing technology, and the image processing efficiency and image processing quality are improved.
[0060] Based on the above embodiments, optionally, the replacement image generation module 230 is used to determine the target generated content in response to a selection operation for the generated content option, wherein the generated content option is an option determined based on the character image parameters of the first virtual character; and generate the replacement image according to the character image parameters corresponding to the target generated content.
[0061] Based on the above embodiments, optionally, the virtual character determination module 220 is used to display a character image list in response to a marking operation for a first target object among the at least one target object; and to determine a first virtual character associated with the first target object in response to a selection operation for the character image list.
[0062] Optionally, the virtual character determination module 220 is further configured to determine the account identifier associated with the first virtual character; and obtain the character appearance parameters corresponding to the first virtual character based on the account identifier.
[0063] Optionally, the character appearance parameters include at least one of the following: facial feature parameters, hairstyle parameters, skin color parameters, makeup parameters, and clothing parameters.
[0064] Optionally, the generated content options include at least one of the following: account identifier option, facial appearance option, hairstyle option, and clothing option.
[0065] Based on the above embodiments, optionally, the image synthesis module 240 is used to determine the position information of the first target object in the first image; according to the position information, the replacement image is superimposed on the corresponding position of the first image to obtain the second image.
[0066] Based on the above embodiments, optionally, the virtual character determination module 220 is further configured to mark each target object in the first image so that each target object enters an optional state.
[0067] Optionally, based on the above embodiments, the device further includes an image sharing module for displaying the second image and sending the second image to a target platform in response to a sharing operation on the second image.
[0068] The image processing apparatus provided in this disclosure can execute the image processing method provided in any embodiment of this disclosure, and has the corresponding functional modules and beneficial effects for executing the method.
[0069] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure. The electronic device 10 is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (such as helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0070] like Figure 6 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 may also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0071] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0072] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as image processing methods.
[0073] In some embodiments, the image processing method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or mounted on electronic device 10 via read-only memory (ROM) 12 and / or communication unit 19. When the computer program is loaded into random access memory (RAM) 13 and executed by processor 11, one or more steps of the image processing method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the image processing method by any other suitable means (e.g., by means of firmware).
[0074] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0075] Computer programs for implementing the image processing methods of this disclosure can be written in any combination of one or more programming languages. These computer programs can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The computer programs can be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0076] This disclosure also provides a computer-readable storage medium storing computer instructions for causing a processor to perform an image processing method, the method comprising: A first image is displayed in a graphical user interface, the first image containing an image region of at least one target object; in response to a marking operation on the first target object among the at least one target object, a first virtual character associated with the first target object is determined; a replacement image is generated based on the character appearance parameters of the first virtual character; the replacement image is combined with the first image to obtain a second image.
[0077] In the context of this disclosure, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage 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. Alternatively, a computer-readable storage medium can be a machine-readable signal medium. 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.
[0078] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).
[0079] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or middleware components (e.g., application servers), or frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.
[0080] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.
[0081] It should be understood that the various forms of processes shown above can be used to rearrange, add, or delete steps. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this disclosure can be achieved, and this is not limited herein.
[0082] This disclosure also provides a computer program product, including a computer program that, when executed by a processor, implements the image processing method according to any embodiment of this disclosure.
[0083] In implementing a computer program product, computer program code for performing the operations of this disclosure can be written in one or more programming languages or a combination thereof. Programming languages include object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as C or similar 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).
[0084] The specific embodiments described above do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure should be included within the scope of protection of this disclosure.
Claims
1. An image processing method, characterized in that, include: A first image is displayed in a graphical user interface, the first image containing an image region of at least one target object; In response to a tagging operation on a first target object among the at least one target object, a first virtual character associated with the first target object is determined; Generate a replacement image based on the character appearance parameters of the first virtual character; The replacement image is combined with the first image to obtain the second image.
2. The method according to claim 1, characterized in that, The step of generating a replacement image based on the character appearance parameters of the first virtual character includes: In response to a selection operation for the generated content option, a target generated content is determined, wherein the generated content option is an option determined based on the character image parameters of the first virtual character; The replacement image is generated based on the character image parameters corresponding to the target content.
3. The method according to claim 1, characterized in that, In response to a tagging operation on a first target object among the at least one target object, determining a first virtual character associated with the first target object includes: In response to a tagging operation targeting a first target object among the at least one target object, a list of character images is displayed; In response to a selection operation on the list of character images, a first virtual character associated with the first target object is determined.
4. The method according to claim 3, characterized in that, The method further includes: Determine the account identifier associated with the first virtual character; Based on the account identifier, obtain the character appearance parameters corresponding to the first virtual character.
5. The method according to any one of claims 1, characterized in that, The character appearance parameters include at least one of the following: Facial feature parameters, hairstyle parameters, skin tone parameters, makeup parameters, and clothing parameters.
6. The method according to claim 2, characterized in that... The content generation options include at least one of the following: Account identification options, facial features options, hairstyle options, and clothing options.
7. The method according to claim 1, characterized in that, The step of combining the replaced image with the first image to obtain the second image includes: Determine the location information of the first target object in the first image; Based on the location information, the replacement image is superimposed onto the corresponding position of the first image to obtain the second image.
8. The method according to claim 1, characterized in that, The method further includes: Each target object in the first image is marked so that each target object is made available.
9. The method according to claim 1, characterized in that, The method further includes: Display the second image; In response to a sharing operation for the second image, the second image is sent to the target platform.
10. An image processing apparatus, characterized in that, include: An image display module is used to display a first image in a graphical user interface, wherein the first image contains an image area of at least one target object; A virtual role determination module is configured to determine a first virtual role associated with the first target object in response to a marking operation on a first target object among the at least one target object; The replacement image generation module is used to generate a replacement image based on the character appearance parameters of the first virtual character. An image synthesis module is used to synthesize the replacement image with the first image to obtain a second image.
11. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the image processing method according to any one of claims 1-9.
12. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that cause a processor to execute the image processing method according to any one of claims 1-9.