Image processing method and apparatus, computer device, and storage medium

Through image processing methods, the style information and color configuration of virtual character hairstyles in game applications are obtained, and the pixel position and color are determined, which solves the problem of single dyeing function of traditional dyeing and realizes personalized design and efficient dyeing.

WO2024222185A1PCT designated stage expired Publication Date: 2024-10-31TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/078684
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-04-28
Filing Date
2024-02-27
Publication Date
2024-10-31

AI Technical Summary

Technical Problem

The dyeing function of traditional game applications is relatively simple and cannot meet the personalized dyeing needs of users, resulting in low dyeing efficiency.

Method used

An image processing method is provided that determines the target rendering style, obtains style information and color configuration information, determines the position and color of each pixel on the object to be rendered, and maps it to the display screen to generate diverse image effects.

Benefits of technology

It improves the user's personalized design space for rendering objects, provides a variety of rendering style choices, and improves dyeing diversity and efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024078684_31102024_PF_FP_ABST
    Figure CN2024078684_31102024_PF_FP_ABST
Patent Text Reader

Abstract

An image processing method, executed by a computer device. The method comprises: determining a target rendering style, and acquiring style information of the target rendering style, and color configuration information and color change information of texture partitions in the target rendering style (202); according to the style information, determining first position information of pixels on an object to be rendered in the target rendering style (204); according to the first position information of the pixels in the target rendering style, determining target texture partitions to which the pixels respectively belong (206); according to color configuration information of the target texture partitions, color change information of the target texture partitions, and second position information of the pixels on said object in the target rendering style, determining colors of the pixels on said object (208); and mapping the colors of the pixels on said object to an area on a display screen to generate an image corresponding to said object (210).
Need to check novelty before this filing date? Find Prior Art

Description

Image processing method, device, computer equipment and storage medium

[0001] Related applications

[0002] This application claims priority to Chinese patent application number 2023104873773, entitled “Image processing method, device, computer equipment and storage medium”, filed on April 28, 2023, the entire text of which is incorporated herein by reference. Technical Field

[0003] The present application relates to the field of image processing technology, and in particular to an image processing method, apparatus, computer equipment, storage medium, and computer program product. Background Art

[0004] With the development of smart terminals, the applications that can be installed on smart terminals are becoming more and more abundant. For example, smart terminals can install shopping applications, navigation applications, social applications, and game applications. Among them, the design of virtual characters in game applications is becoming more and more realistic, making the audience of game applications more and more extensive.

[0005] Traditionally, gaming applications have provided a coloring function that allows users to color the rendered image to their preferred color. However, the coloring functions provided by traditional technologies are relatively limited and cannot meet users' personalized coloring needs.

[0006] Summary of the Invention

[0007] The present application provides an image processing method, apparatus, computer device, computer-readable storage medium, and computer program product.

[0008] In one aspect, the present application provides an image processing method. The method comprises:

[0009] Determine a target rendering style, obtain style information of the target rendering style, color configuration information and color change information of each texture partition under the target rendering style;

[0010] Determining first position information of each pixel on the object to be rendered under a target rendering style according to the style information;

[0011] Determining, according to the first position information of each pixel in the target rendering style, a target texture partition to which each pixel belongs;

[0012] determining the color of each pixel on the object to be rendered according to the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style; and

[0013] The color of each pixel on the object to be rendered is mapped to an area on the display screen to generate an image corresponding to the object to be rendered.

[0014] On the other hand, the present application also provides an image processing device. The device includes:

[0015] an acquisition module, configured to determine a target rendering style, and acquire style information of the target rendering style, color configuration information of each texture partition under the target rendering style, and color change information;

[0016] a first determining module, configured to determine, based on the style information, first position information of each pixel on the object to be rendered in a target rendering style; and determine, based on the first position information of each pixel in the target rendering style, a target texture partition to which each pixel belongs;

[0017] a second determining module, configured to determine the color of each pixel on the object to be rendered based on the color configuration information of the target texture partition, the color change information of the target texture partition, and second position information of each pixel on the object to be rendered under the target rendering style;

[0018] The generating module is used to map the color of each pixel on the object to be rendered to an area on the display screen to generate an image corresponding to the object to be rendered.

[0019] On the other hand, the present application further provides a computer device, which includes a memory and a processor, wherein the memory stores a computer program, and the processor implements the above-mentioned image processing method when executing the computer program.

[0020] On the other hand, the present application further provides a computer-readable storage medium having a computer program stored thereon, which implements the above-mentioned image processing method when executed by a processor.

[0021] On the other hand, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, implements the above-mentioned image processing method.

[0022] The details of one or more embodiments of the present application are set forth in the following drawings and description. Other features, objects, and advantages of the present application will become apparent from the description, drawings, and claims. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the conventional technology, the following briefly introduces the drawings required for use in the embodiments or the conventional technology descriptions. Obviously, the drawings described below are merely embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the disclosed drawings without any creative work.

[0024] FIG1 is a diagram illustrating an application environment of an image processing method according to an embodiment;

[0025] FIG2 is a schematic flow chart of an image processing method according to an embodiment;

[0026] FIG3 is a schematic diagram of texture partitioning in one embodiment;

[0027] FIG4 is a schematic diagram of a region division method in one embodiment;

[0028] FIG5 is a schematic diagram of a region division method in another embodiment;

[0029] FIG6 is a schematic diagram of a virtual character hair setting page in one embodiment;

[0030] FIG7 is a schematic diagram of a hue combination configuration area in one embodiment;

[0031] FIG8 is a schematic diagram of a color attribute configuration area in one embodiment;

[0032] FIG9 is a schematic diagram of a color change configuration area in one embodiment;

[0033] FIG10 is a schematic diagram of a hair styling area according to an embodiment;

[0034] FIG11 is a schematic diagram of the color calculation principle in one embodiment;

[0035] FIG12 is a schematic diagram of a process for generating an image corresponding to an object to be rendered in one embodiment;

[0036] FIG13 is a schematic diagram showing the effect of the up-down gradient corresponding to one embodiment;

[0037] FIG14 is a schematic diagram showing the effect of left-right gradient change in one embodiment;

[0038] FIG15 is a schematic diagram showing the principle of updating a rendering material in one embodiment;

[0039] FIG16 is a schematic diagram showing the effect of highlighting in one embodiment;

[0040] FIG17 is a block diagram of the structure of an image processing device according to an embodiment;

[0041] FIG18 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0042] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0043] The image processing method provided in the embodiments of the present application can be applied in the application environment shown in FIG1 . In this embodiment, terminal 102 communicates with server 104 via a network. A data storage system can store data that server 104 needs to process. The data storage system can be integrated with server 104 or placed in the cloud or on another server. The image processing method provided in the embodiment of the present application can be executed independently by the terminal 102 or the server 104, or can be executed collaboratively by the terminal 102 and the server 104. Taking the execution by the terminal 102 alone as an example, the terminal 102 can determine the target rendering style, obtain style information of the target rendering style, color configuration information and color change information of each texture partition under the target rendering style, and then determine the first position information of each pixel on the object to be rendered under the target rendering style based on the style information, and determine the target texture partition to which each pixel belongs based on the first position information of each pixel under the target rendering style. Then, based on the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style, the color of each pixel on the object to be rendered is determined. Finally, the color of each pixel on the object to be rendered is mapped to an area on the display screen to generate an image corresponding to the object to be rendered.

[0044] Terminal 102 may include, but is not limited to, various personal computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices may include smart speakers, smart TVs, smart air conditioners, and smart car devices. Portable wearable devices may include smart watches, smart bracelets, and head-mounted devices. Server 104 may be an independent physical server, a server cluster or distributed system consisting of multiple physical servers, or a cloud server providing cloud computing services.

[0045] In some embodiments, as shown in FIG2 , an image processing method is provided, which is described by taking the method applied to the terminal in FIG1 as an example, including the following steps:

[0046] Step 202 : Determine a target rendering style, obtain style information of the target rendering style, and color configuration information and color change information of each texture partition under the target rendering style.

[0047] Among them, various applications (Application, referred to as APP) with different functions can be installed on the terminal, such as shopping APP, social APP, image processing APP and game APP, etc. The image processing method provided in the embodiment of the present application can be applied to image processing APP and game APP, and the embodiment of the present application does not limit this.

[0048] The target rendering style may be a rendering style specified by the user through the rendering style specification function of the corresponding app. The style information of the target rendering style may be information used to describe the characteristics of the target rendering style. The style information of the target rendering style may include a style identifier, style name, style description, etc. of the target rendering style, which is not limited in this embodiment of the application.

[0049] In a specific implementation, the target rendering style can be the color gradient style of the object to be rendered, specified by the user through the rendering style specification function of the corresponding app. The object to be rendered can be the hairstyle, clothing, etc. of a virtual character, and the virtual character can be the virtual character corresponding to the account used by the user when logging into the corresponding app. The color gradient style is used to represent the method of color gradient. Color gradient styles include left-right gradient, top-down gradient, mixed gradient, and highlighting. This embodiment of the application is not limited to this.

[0050] For example, when the image processing method provided in the embodiment of the present application is applied to a certain game APP, the user can log in to the game APP using an account, open the virtual character hair setting page on the game APP, and the virtual character hair setting page displays the virtual character corresponding to the account used when logging in, and the object to be rendered is the hairstyle of the virtual character. A rendering style specification control is also provided on the virtual character hair setting page, and the user can perform a rendering style specification operation through the control. The game APP can use the specified rendering style corresponding to the rendering style specification operation as the target rendering style of the virtual character's hairstyle, and use the style information of the specified rendering style as the style information of the target rendering style.

[0051] Among them, the texture partition is the area contained in the two-dimensional image editing interface in the model making software. The two-dimensional image editing interface contains a horizontal axis and a vertical axis. The horizontal axis can also be called the texture horizontal axis, and the vertical axis can also be called the texture vertical axis. The two-dimensional image editing interface can be divided into multiple areas according to preset rules.

[0052] In a specific implementation, as shown in Figure 3, the range of the texture's horizontal coordinate axis is [-1, 2]. The area with the texture's horizontal coordinate at (-1, 0) can be used as a texture partition. For convenience, this texture partition can be called a blue partition. The area with the texture's horizontal coordinate at (0, 1) can be used as another texture partition. For convenience, this texture partition can be called a red partition. The area with the texture's horizontal coordinate at (1, 2) can be used as yet another texture partition. For convenience, this texture partition can be called a yellow partition. In this way, the two-dimensional image editing interface can be divided into three texture partitions.

[0053] During the development phase, the object to be rendered can be divided into a number of regions to be rendered that matches the number of texture partitions according to a certain division method, and each region to be rendered can be placed in a different texture partition, thereby obtaining the texture horizontal coordinate and texture vertical coordinate of each pixel on the object to be rendered under this division method. The object to be rendered can also be divided into a number of regions to be rendered that matches the number of texture partitions according to another division method, and each region to be rendered can be placed in a different texture partition, thereby obtaining the texture horizontal coordinate and texture vertical coordinate of each pixel on the object to be rendered under this division method. Each division method corresponds to a rendering style. The texture coordinates of the same pixel are different under different division methods. Style information can be configured for each division method. After obtaining the texture horizontal coordinate and texture vertical coordinate of each pixel on the object to be rendered, the texture horizontal coordinate and texture vertical coordinate of each pixel can be used as texture coordinate data, and the style information and texture coordinate data corresponding to the corresponding division method can be stored as a set of gradient data.

[0054] For example, as shown in FIG4 , the object to be rendered is a virtual character's hairstyle, which consists of left and right braids. During the development phase, the artist can divide the virtual character's hairstyle into a black region 401, a dark gray region 402, and a light gray region 403 according to the left, center, and right divisions. The black region 401 can be placed in the blue partition, the dark gray region 402 in the yellow partition, and the light gray region 403 in the red partition, thereby obtaining the texture abscissa and texture ordinate of each pixel in the hairstyle. Alternatively, as shown in FIG5 , the artist can divide the virtual character's hairstyle into a black region 501, a dark gray region 502, and a light gray region 503 according to the braids. The black region 501 can be placed in the blue partition, the dark gray region 502 in the yellow partition, and the light gray region 503 in the red partition, thereby obtaining the texture abscissa and texture ordinate of each pixel in the hairstyle.

[0055] Among them, the color configuration information of each texture partition under the target rendering style may include the hue combination information of the texture partition specified by the user, and the color attribute information specified by the user for each color in the hue combination information. The color attribute information may include primary and secondary attributes, brightness and saturation, etc., which is not limited in this embodiment of the present application.

[0056] The color change information of each texture partition may include information specified by a user for the texture partition and used to define a gradient area. For example, the information may include a gradient position and a gradient range.

[0057] For example, in conjunction with the above example, after a user performs a rendering style specification operation, the game app may display a hue combination configuration area and a color change configuration area. The hue combination configuration area contains hue combination configuration controls corresponding to each texture partition under the target rendering style. The user can use the hue combination configuration control corresponding to each texture partition to configure a hue combination for that texture partition. The game app obtains the hue combination information for that texture partition based on this configuration operation. After the user completes configuring the hue combination for each texture partition, they can trigger the color attribute configuration area expansion operation in the hue combination configuration area. In response to this expansion operation, the game app expands the color attribute configuration area. The color attribute configuration area contains attribute adjustment areas corresponding to each texture partition. The user can use these attribute adjustment areas to adjust the color attributes of each color included in the corresponding hue combination information. The game app obtains the color attribute information based on this adjustment operation. The color change configuration area contains color change configuration controls corresponding to each texture partition under the target rendering style. The user can use the color change configuration control corresponding to each texture partition to set the color change for that texture partition. The game app obtains the color change information for that texture partition based on this setting operation.

[0058] Step 204 : determining first position information of each pixel on the object to be rendered in the target rendering style according to the style information.

[0059] Step 206 : Determine the target texture partition to which each pixel belongs based on the first position information of each pixel in the target rendering style.

[0060] The terminal stores multiple sets of gradient data, each set of gradient data includes style information and texture coordinate data, and can determine the first position information of each pixel on the object to be rendered under the target rendering style based on the multiple sets of gradient data.

[0061] In a specific implementation, after obtaining the style information of the target rendering style, the terminal can match the obtained style information with the style information in each set of gradient data. After finding the successfully matched style information, the gradient data to which the successfully matched style information belongs is obtained, and the texture coordinate data in the gradient data is obtained. The texture horizontal coordinate of each pixel in the texture coordinate data can be used as the first position information of the corresponding pixel.

[0062] Among them, the terminal can obtain the position range corresponding to each texture partition under the target rendering style. For each pixel on the object to be rendered, the position range in which the first position information of the pixel falls can be obtained, and the texture partition corresponding to the position range is used as the target texture partition to which the pixel belongs.

[0063] For example, there are 3 texture partitions under the target rendering style, the texture horizontal coordinate range of one texture partition is (-1, 0), the texture horizontal coordinate range of another texture partition is (0, 1), and the texture horizontal coordinate range of the third texture partition is (1, 2). After determining the texture horizontal coordinate of each pixel on the object to be rendered under the target rendering style, for each pixel on the object to be rendered, it can be determined in which of the above ranges the texture horizontal coordinate of the pixel falls, and the texture partition corresponding to the range that falls into the range is used as the target texture partition to which the pixel belongs.

[0064] Step 208 : determining the color of each pixel on the object to be rendered according to the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style.

[0065] The color configuration information of the target texture partition may include user-specified hue combination information for the texture partition, as well as user-specified color attribute information for each color in the hue combination information. The color change information of the target texture partition may include user-specified information for defining a gradient region for the texture partition, such as a gradient position and gradient range.

[0066] Among them, the terminal stores multiple groups of gradient data, each group of gradient data includes style information and texture coordinate data. After obtaining the style information of the target rendering style, the terminal can match the obtained style information with the style information in each group of gradient data, obtain the gradient data to which the matched style information belongs, and obtain the texture coordinate data in the gradient data. The texture horizontal coordinate of each pixel in the texture coordinate data can be used as the first position information of the corresponding pixel, and the texture vertical coordinate can be used as the second position information of the corresponding pixel.

[0067] Among them, after obtaining the color configuration information of the target texture partition, the color change information of the target texture partition and the second position information of each pixel on the object to be rendered under the target rendering style, the terminal can calculate the color of each pixel on the object to be rendered through a preset formula.

[0068] Among them, for each pixel on the object to be rendered, the terminal can obtain the partition primary color and partition secondary color of the target texture partition to which the pixel belongs, and determine the color of the pixel based on the partition primary color, the partition secondary color, the second position information of the pixel under the target rendering style, and the color change information of the target texture partition to which the pixel belongs.

[0069] Step 210 : Map the color of each pixel on the object to be rendered to an area on the display screen to generate an image corresponding to the object to be rendered.

[0070] Among them, there is a correspondence between the pixels on the object to be rendered and the pixel points on the area on the display screen used to display the object to be rendered. After obtaining the color of each pixel on the image to be rendered, the color of each pixel on the image to be rendered can be mapped to the pixel points on the above area according to the above correspondence, and the image corresponding to the object to be rendered is generated based on the color of each pixel point on the above area.

[0071] In some embodiments, each pixel on the object to be rendered corresponds to a pixel point on the area on the display screen used to display the object to be rendered. The color of each pixel on the object to be rendered can be used as the color of the corresponding pixel point, and an image corresponding to the object to be rendered is generated based on the color of each pixel point on the above area.

[0072] In some embodiments, each pixel on the object to be rendered corresponds to multiple pixel points on the area on the display screen used to display the object to be rendered. The color of each pixel on the object to be rendered can be used as the color of the corresponding multiple pixel points, and an image corresponding to the object to be rendered is generated based on the color of each pixel point on the above area.

[0073] Among them, after the terminal generates the image corresponding to the object to be rendered, it can display the image on the display screen for the user to view. For example, the object to be rendered can be the hairstyle of a virtual character. After the terminal generates the image corresponding to the hairstyle of the virtual character, it can display the image on the display screen for the user to view, so that the user can preview in real time the effect of the object to be rendered under the above-mentioned style information, color configuration information and color change information.

[0074] In the above embodiment, a target rendering style is determined, style information of the target rendering style, color configuration information of each texture partition under the target rendering style, and color change information are obtained. Based on the style information, first position information of each pixel on the object to be rendered under the target rendering style is determined; based on the first position information of each pixel under the target rendering style, the target texture partition to which each pixel belongs is determined; based on the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style, the color of each pixel on the object to be rendered is determined; and the color of each pixel on the object to be rendered is mapped to an area on the display screen to generate an image corresponding to the object to be rendered. The generated image of the object to be rendered corresponds to the target rendering style, and different rendering styles correspond to different image presentation effects. This method provides a user with a rendering style selection portal, allowing the user to select the most appropriate rendering style from multiple rendering styles, thereby increasing the user's personalized design space for the rendered object, improving coloring diversity, and avoiding the problem of low coloring efficiency caused by multiple coloring adjustments when the coloring function is single.

[0075] In some embodiments, determining a target rendering style, obtaining style information of the target rendering style, and color configuration information and color change information of each texture partition under the target rendering style include: in response to a rendering style specifying operation, using a specified rendering style corresponding to the rendering style specifying operation as the target rendering style, and using the style information of the specified rendering style as the style information of the target rendering style; displaying a rendering configuration area corresponding to the target rendering style, and obtaining color configuration information and color change information of each texture partition under the target rendering style through the rendering configuration area.

[0076] The user may perform a rendering style specification operation on a page including a rendering style specification function. In response to the rendering style specification operation, the terminal may use the specified rendering style corresponding to the rendering style specification operation as the target rendering style and the style information of the specified rendering style as the style information of the target rendering style.

[0077] In a specific implementation, a game APP is installed on the terminal. The image processing method provided in the embodiment of the present application can be applied to the game APP. The user can log in to the game APP using an account and open the virtual character hair setting page on the game APP. The virtual character hair setting page displays the virtual character corresponding to the account used when logging in, and the object to be rendered is the hairstyle of the virtual character. The virtual character hair setting page also provides a rendering style specification control. The user can perform a rendering style specification operation through the rendering style specification control. The game APP can use the specified rendering style corresponding to the rendering style specification operation as the target rendering style of the virtual character's hairstyle, and use the style information of the specified rendering style as the style information of the target rendering style.

[0078] For example, as shown in FIG6 , the object to be rendered can be the hairstyle of a virtual character. The virtual character hair setting page provides a rendering style specification control. The rendering style specification control includes control 1 and control 2. Control 1 is a control corresponding to the up-down gradient, and control 2 is a control corresponding to the left-right gradient. Assuming that the user performs a trigger operation on control 1, the game app uses the up-down gradient as the target rendering style and the style information of the up-down gradient as the style information of the target rendering style. Assuming that the user performs a trigger operation on control 2, the game app uses the left-right gradient as the target rendering style and the style information of the left-right gradient as the style information of the target rendering style.

[0079] Among them, after the user performs the rendering style specification operation on the page containing the rendering style specification function, the terminal can display the rendering configuration area corresponding to the target rendering style on the page, and the user can perform the rendering configuration operation in the rendering configuration area. Based on the rendering configuration operation, the terminal determines the color configuration information and color change information of each texture partition under the target rendering style.

[0080] In the above embodiment, a user is allowed to perform a rendering style specification operation on a specific page. In response to the rendering style specification operation, the terminal uses the specified rendering style corresponding to the rendering style specification operation as the target rendering style, and uses the style information of the specified rendering style as the style information of the target rendering style. The terminal also displays a rendering configuration area corresponding to the target rendering style, and obtains color configuration information and color change information of each texture partition under the target rendering style through the rendering configuration area. This approach provides the user with a rendering style selection entry, allowing the user to select the most appropriate rendering style from multiple rendering styles, thereby enhancing the user's personalized design space for rendering objects.

[0081] In some embodiments, the rendering configuration area includes a hue combination configuration area, a color change configuration area, and a color attribute configuration area; the rendering configuration area corresponding to the target rendering style is displayed, and the color configuration information and color change information of each texture partition under the target rendering style are obtained through the rendering configuration area, including: obtaining the hue combination information of each texture partition under the target rendering style through the hue combination configuration area; obtaining the color attribute information of each color contained in the hue combination information through the color attribute configuration area; determining the color configuration information of each texture partition under the target rendering style based on the hue combination information and the color attribute information; obtaining the color change information of each texture partition under the target rendering style through the color change configuration area.

[0082] Specifically, the terminal may display a hue combination configuration area, a color change configuration area, and a color attribute configuration area on a page that includes a rendering style specification function. Alternatively, the terminal may display a hue combination configuration area on a page that includes a rendering style specification function. After the user performs a hue combination configuration operation in the hue combination configuration area and triggers an area jump operation, the terminal displays a color control and a gradient control. After the user performs a trigger operation on the color control, the terminal displays a color attribute configuration area. After the user performs a trigger operation on the gradient control, the terminal displays a color change configuration area.

[0083] Among them, the hue combination configuration area contains the hue combination configuration controls corresponding to each texture partition under the target rendering style. Users can perform hue combination configuration operations through the hue combination configuration controls corresponding to each texture partition, thereby configuring the hue combination for the texture partition.

[0084] For example, referring to FIG7 , it is assumed that there are three texture partitions, namely texture partition 1, texture partition 2, and texture partition 3. In the hue combination configuration area, texture partition 1, texture partition 2, and texture partition 3 each correspond to a hue combination selection area, and each hue combination area contains multiple hue combination configuration controls, such as a yellow-blue combination control, a red-yellow combination control, a light-blue combination control, etc. The user can click on the hue combination configuration control to configure the hue combination for the corresponding texture partition. For example, if the user clicks on the yellow-blue combination control in the hue combination selection area corresponding to texture partition 1, the terminal can use yellow and blue as the hue combination information of texture partition 1. If the user clicks on the red-yellow combination control in the hue combination selection area corresponding to texture partition 2, the terminal can use red and yellow as the hue combination information of texture partition 2. If the user clicks on the light-blue combination control in the hue combination selection area corresponding to texture partition 3, the terminal can use pink and blue as the hue combination information of texture partition 3.

[0085] After obtaining the hue combination information of each texture partition and the color attribute information of each color included in the hue combination information, the terminal may use the hue combination information and color attribute information as the color configuration information of the corresponding texture partition.

[0086] In the above embodiment, the hue combination configuration area can be used to obtain the hue combination information for each texture partition under the target rendering style; the color attribute information of each color contained in the hue combination information can be obtained through the color attribute configuration area; the color configuration information for each texture partition under the target rendering style can be determined based on the hue combination information and color attribute information; and the color variation configuration area can be used to obtain the color variation information for each texture partition under the target rendering style. This approach provides users with access to parameters such as hue combination, color attribute, and color variation, further expanding the space for personalized design of rendered objects.

[0087] In some embodiments, the color attribute configuration area includes attribute adjustment controls for each color in the hue combination information; the color attribute information of each color included in the hue combination information is obtained through the color attribute configuration area, including: based on the touch operation of the attribute adjustment control, determining the color attribute information of each color included in the hue combination information.

[0088] Among them, the attribute adjustment control can include a brightness adjustment control and a saturation adjustment control. The brightness of the corresponding color can be determined based on the touch operation of the brightness adjustment control, and the saturation of the corresponding color can be determined based on the touch operation of the saturation adjustment control. The color attribute information of the corresponding color can be determined based on the brightness and saturation.

[0089] Among them, the color attribute configuration area may also include a primary and secondary color designation control, through which the user can specify the primary and secondary attributes of each color in the hue combination information. The terminal can use the color obtained through the brightness adjustment control, the saturation obtained through the saturation adjustment control, and the primary and secondary attributes obtained through the primary and secondary color designation control as the color attribute information of the corresponding color.

[0090] The color attribute configuration area includes an attribute designation area corresponding to each texture partition, and each attribute designation area includes an attribute adjustment control for each color in the hue combination information corresponding to the corresponding texture partition.

[0091] Exemplarily, after the user performs the hue combination configuration operation in the hue combination configuration area, the user can click the fine adjustment control in Figure 7 to trigger the area jump operation, as shown in Figure 8. In response to the click operation, the terminal can display the gradient control 801 and the color control 802. After the user clicks the color control 802, the terminal can display the color attribute configuration area. Assume that the number of texture partitions is 3, namely texture partition 1, texture partition 2 and texture partition 3. In the color attribute configuration area, texture partition 1, texture partition 2 and texture partition 3 each correspond to an attribute designation area. The attribute designation area corresponding to texture partition 1 includes a primary and secondary color designation control, a brightness adjustment control and a saturation adjustment control for each color in the hue combination information corresponding to texture partition 1. The user can use the primary and secondary color designation control to specify the primary and secondary attributes of each color in the hue combination information corresponding to texture partition 1, adjust the brightness of each color through the brightness adjustment control of each color, and adjust the saturation of each color through the saturation adjustment control of each color. Similarly, the attribute designation area corresponding to texture partition 2 includes controls for specifying primary and secondary colors, as well as controls for adjusting the brightness and saturation of each color in the hue combination information corresponding to texture partition 2. The user can use the controls to specify the primary and secondary attributes of each color in the hue combination information corresponding to texture partition 2, adjust the brightness of each color using the controls for each color, and adjust the saturation of each color using the controls for each color. Texture partition 3 is similar and will not be further described in detail in this embodiment of the present application.

[0092] In the above embodiment, a property adjustment control is set in the color property configuration area, and the user can adjust the brightness, saturation and other parameters of each color through the property adjustment control. The above method provides the user with a selection entry for parameters such as brightness and saturation, allowing the user to freely set the brightness and saturation of the color, thereby enhancing the user's personalized design space for the rendered object.

[0093] In some embodiments, the color change configuration area includes color change controls for each texture partition under the target rendering style; obtaining color change information for each texture partition under the target rendering style through the color change configuration area includes: determining the color change information for each texture partition under the target rendering style based on a touch operation on the color change control.

[0094] Among them, the color change control includes a gradient position adjustment control and a gradient range adjustment control. Based on the touch operation of the gradient position adjustment control, the gradient position of the corresponding texture partition can be determined, and based on the touch operation of the gradient range adjustment control, the gradient range of the corresponding texture partition can be determined. The terminal can use the gradient position and the gradient range as the color change information of the corresponding texture partition.

[0095] For example, as shown in Figure 9, after the user clicks on the color control 802, the terminal can display the color change configuration area. Assume that the number of texture partitions is 3, namely texture partition 1, texture partition 2 and texture partition 3. In the color change configuration area, texture partition 1, texture partition 2 and texture partition 3 each correspond to a color change designated area. The color change designated area corresponding to texture partition 1 includes a gradient position adjustment control and a gradient range adjustment control. The user can adjust the gradient position corresponding to texture partition 1 through the gradient position adjustment control, and the terminal can determine the gradient position corresponding to texture partition 1 based on the adjustment operation; the user can adjust the gradient range corresponding to texture partition 1 through the gradient range adjustment control, and the terminal can determine the gradient range corresponding to texture partition 1 based on the adjustment operation. Similarly, the color change designated area corresponding to texture partition 2 also includes a gradient position adjustment control and a gradient range adjustment control. The user can use the gradient position adjustment control to adjust the gradient position corresponding to texture partition 2, and the terminal can determine the gradient position corresponding to texture partition 2 based on this adjustment operation. The user can use the gradient range adjustment control to adjust the gradient range corresponding to texture partition 2, and the terminal can determine the gradient range corresponding to texture partition 2 based on this adjustment operation. Texture partition 3 is similar, and the embodiments of this application will not be repeated here.

[0096] Among them, the terminal can save the acquired style information, color configuration information and color change information, and generate a corresponding trigger control in the user design area. When the user clicks the trigger control, the terminal directly generates an image corresponding to the object to be rendered based on the saved data. For example, the object to be rendered is the hairstyle of a virtual character. The terminal can generate a corresponding trigger control in the hairstyle design area. In the case where there are multiple groups of saved data, there are multiple corresponding trigger controls, such as the hair dyeing control 1001, hair dyeing control 1002 and hair dyeing control 1003 in Figure 10. Assuming that the user clicks on the hair dyeing control 1001 and clicks to confirm the replacement, the terminal can generate an image corresponding to the object to be rendered based on the data corresponding to the hair dyeing control 1001 and display it on the display screen.

[0097] In the above embodiment, a color change control is set in the color change configuration area, and the user can use the color change control to adjust the gradient position and gradient range corresponding to the texture partition. The above method provides the user with a selection entry for the gradient position and gradient range, allowing the user to freely set the gradient position and gradient range of the texture partition, thereby enhancing the user's personalized design space for rendering objects.

[0098] In some embodiments, based on the style information, determining the first position information of each pixel on the object to be rendered under the target rendering style includes: searching for texture coordinate data corresponding to the object to be rendered and matching the style information based on the style information; searching for the texture horizontal coordinates of each pixel on the object to be rendered from the texture coordinate data, and using the texture horizontal coordinates of each pixel as the first position information of the corresponding pixel under the target rendering style.

[0099] The style information of the target rendering style may include a style identifier, a style name, and a style description of the target rendering style.

[0100] During the development phase, the artist can divide the image to be rendered according to different division methods. Each division method corresponds to a rendering style, and style information can be configured for each division method. For each division method, after the image to be rendered is divided into different areas using the division method, the different areas can be placed in different texture partitions to obtain the texture horizontal coordinates and texture vertical coordinates of each pixel on the image to be rendered under the division method. The texture horizontal coordinates and texture vertical coordinates of each pixel under the division method can be used as texture coordinate data. The style information corresponding to the division method and the texture coordinate data can be stored as a set of gradient data. In the case of multiple division methods, multiple sets of gradient data can be obtained.

[0101] In some embodiments, the terminal can read the style information in each set of gradient data stored locally, compare the style information of the target rendering style with the style information in each set of gradient data, and when the two are consistent, obtain the texture coordinate data in the gradient data to which the corresponding style information belongs, and use the texture coordinate data as the texture coordinate data that matches the style information of the target rendering style.

[0102] In some embodiments, after obtaining texture coordinate data matching the style information of the target rendering style, the terminal may use the texture horizontal coordinate of each pixel in the texture coordinate data as the first position information of each pixel in the target rendering style.

[0103] In the above embodiment, after obtaining the style information of the target rendering style, the first position information of each pixel on the object to be rendered can be determined based on the style information. Subsequently, the image of the object to be rendered under the target rendering style can be generated based on the first position information. This provides the user with a rendering style selection portal, allowing the user to select the most appropriate rendering style from multiple rendering styles, thereby increasing the personalized design space for the rendered object.

[0104] In some embodiments, the target texture partition to which each pixel belongs is determined based on the first position information of each pixel under the target rendering style, including: obtaining the position range corresponding to each texture partition under the target rendering style; for each pixel on the object to be rendered, matching the first position information of the pixel with each position range, and determining the target texture partition to which the pixel belongs based on the matching result.

[0105] Among them, the two-dimensional image editing interface in the model making software includes a texture horizontal coordinate axis and a texture vertical coordinate axis. The two-dimensional image editing interface can be divided into multiple areas according to preset rules, and each area can be called a texture partition.

[0106] For example, in a two-dimensional image editing interface, the range of the texture horizontal coordinate axis is (-1, 2). The area with the texture horizontal coordinate at (-1, 0) can be used as a texture partition, the area with the texture horizontal coordinate at (0, 1) can be used as another texture partition, and the area with the texture horizontal coordinate at (1, 2) can be used as another texture partition, thus obtaining 3 texture partitions.

[0107] It should be noted that dividing the texture partitions according to -1<texture horizontal coordinate<0, 0<texture horizontal coordinate<1, 1<texture horizontal coordinate<2 is only an example, and other division methods can also be used. The number of texture partitions is not limited to 3, and can be less than 3 or greater than 3. The embodiments of the present application do not limit this.

[0108] Among them, the terminal can obtain the position range corresponding to each texture partition on the two-dimensional image editing interface, and use the position range to determine the target texture partition to which each pixel on the image to be rendered belongs. Exemplarily, when the texture partitions are divided according to -1<texture horizontal coordinate<0, 0<texture horizontal coordinate<1, 1<texture horizontal coordinate<2, the position range of the texture partition corresponding to -1<texture horizontal coordinate<0 is u∈(-1,0), the position range of the texture partition corresponding to 0<texture horizontal coordinate<1 is u∈(0,1), and the position range of the texture partition corresponding to 1<texture horizontal coordinate<2 is u∈(1,2), where u represents the texture horizontal coordinate.

[0109] Among them, after obtaining the first position information of each pixel on the object to be rendered, the terminal matches the first position information of the pixel with the position range corresponding to each texture partition for each pixel, and takes the texture partition corresponding to the successfully matched position range as the target texture partition to which the pixel belongs.

[0110] In a specific implementation, after obtaining the texture horizontal coordinate of each pixel in the texture coordinate data, for each pixel, the texture horizontal coordinate of the pixel can be compared with the position range corresponding to each texture partition to determine the position range in which the texture horizontal coordinate falls, and the position range is used as the target texture partition to which the pixel belongs.

[0111] For example, assume that there are three texture partitions, namely texture partition 1, texture partition 2, and texture partition 3. The position range of the texture partition corresponding to texture partition 1 is u∈(-1, 0), the position range of the texture partition corresponding to texture partition 2 is u∈(0, 1), and the position range of the texture partition corresponding to texture partition 3 is u∈(1, 2), where u represents the texture horizontal coordinate. Assume that the texture coordinate of a pixel on the object to be rendered is (1.5, 2). Since the texture horizontal coordinate 1.5 of the pixel is in (1, 2), texture partition 3 is the target texture partition to which the pixel belongs.

[0112] In the above embodiment, for each pixel on the object to be rendered, the texture horizontal coordinate of the pixel can be matched with the position range of each texture partition to determine the target texture partition of the pixel. Subsequently, the color of the pixel is calculated based on the target texture partition. Finally, based on the color of each pixel on the object to be rendered, an image corresponding to the object to be rendered is generated. The image generated in this way corresponds to the target rendering style. Different rendering styles correspond to different image presentation effects, so that users can choose the rendering style according to their own preferences, meeting the user's personalized design needs.

[0113] In some embodiments, the color of each pixel on the object to be rendered is determined based on the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style, including: for each pixel on the object to be rendered, determining the partition primary color and the partition secondary color of the target texture partition based on the color configuration information of the target texture partition to which the targeted pixel belongs; determining a first pixel value based on the partition primary color, the second position information of the targeted pixel under the target rendering style, and the color change information of the target texture partition to which it belongs; determining a second pixel value based on the partition secondary color, the second position information of the targeted pixel under the target rendering style, and the color change information of the target texture partition to which it belongs; and determining the color of the targeted pixel based on the first pixel value and the second pixel value.

[0114] The color configuration information of the target texture partition includes hue combination information and color attribute information of each color in the hue combination information. The color attribute information of each color includes the primary and secondary attributes, brightness and saturation of the color.

[0115] Among them, the terminal can extract color attribute information of each color from the color configuration information of the target texture partition, extract primary and secondary attributes from the color attribute information of each color, and determine the partition primary color and partition secondary color of the target texture partition based on the primary and secondary attributes of each color.

[0116] The color change information of the target texture partition includes a gradient position and a gradient range. The second position information of a pixel in the target rendering style may be the texture ordinate of the pixel.

[0117] In a specific implementation, the terminal may use the color whose primary and secondary attributes in the hue combination information are primary colors as the primary colors of the partition, and may use the color whose primary and secondary attributes in the hue combination information are secondary colors as the secondary colors of the partition. The terminal may extract the lightness and saturation of the partition primary color, determine the color value of the partition primary color based on the lightness and saturation of the partition primary color, and determine the first pixel value based on the color value of the partition primary color, the second position information of the pixel in the target rendering style, and the color change information of the target texture partition to which it belongs.

[0118] Similarly, the terminal can extract the brightness and saturation of the partitioned secondary color, determine the color value of the partitioned secondary color based on the brightness and saturation of the partitioned secondary color, and determine the second pixel value based on the color value of the partitioned secondary color, the second position information of the pixel under the target rendering style, and the color change information of the target texture partition to which it belongs.

[0119] After obtaining the first pixel value and the second pixel value, the terminal may add the first pixel value and the second pixel value to obtain the color of the corresponding pixel.

[0120] In a specific implementation, for each pixel on the object to be rendered, the first pixel value of the pixel can be calculated using the following formula: the color value of the partition primary color × (1-(texture vertical coordinate-gradient position) × gradient range); the second pixel value of the pixel can be calculated using the following formula: the color value of the partition secondary color × (texture vertical coordinate-gradient position) × gradient range.

[0121] Exemplarily, as shown in FIG11 , for each pixel on the object to be rendered, the texture horizontal coordinate of the pixel and the position range corresponding to each texture partition can be matched to determine the target texture partition to which the pixel belongs. Based on the color configuration information of the target texture partition, the color value of the primary color of the partition and the color value of the secondary color of the partition can be determined, and then the color of the pixel is calculated using the following formula: color value of the secondary color of the partition × (texture vertical coordinate - gradient position) × gradient range + color value of the primary color of the partition × (1 - (texture vertical coordinate - gradient position) × gradient range).

[0122] In the above embodiment, a specific method is provided for determining the color of each pixel on the object to be rendered based on the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style. Subsequently, the color of each pixel on the object to be rendered can be mapped to an area on the display screen to generate an image corresponding to the object to be rendered. The image generated in this way corresponds to the target rendering style. Different rendering styles correspond to different image presentation effects, thereby meeting the user's personalized design needs.

[0123] In some embodiments, as shown in FIG. 12 , determining the color of each pixel on the object to be rendered based on the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style includes:

[0124] Step 1202 : When a tinting configuration identifier of the object to be rendered exists in the locally stored rendering data, a corresponding rendering material is created based on the tinting configuration identifier.

[0125] Step 1204 : Read the dyeing configuration parameters according to the dyeing configuration identifier, and map the dyeing configuration parameters to the rendering material according to the data mapping relationship corresponding to the dyeing configuration identifier.

[0126] Step 1206 , when the locally stored rendering data still contains designated hair dyeing data, the serialized data in the designated hair dyeing data is parsed to obtain a parsing result, where the serialized data includes color configuration information and color change information.

[0127] Step 1208: Update the rendering material based on the analysis result; and determine the color of each pixel on the object to be rendered based on the updated rendering material.

[0128] The rendering data includes an identifier of the object to be rendered, and may also include a dyeing configuration identifier of the object to be rendered, and may also include specified hair dyeing data. The specified hair dyeing data may include a custom hair dyeing identifier and custom configuration data.

[0129] Among them, after obtaining the color configuration information and color change information of each texture partition under the target rendering style, the terminal can serialize the style information of the target rendering style, the color configuration information and the color change information to obtain serialized data, which can be used as custom configuration data.

[0130] Among them, taking the hairstyle as an example of the object to be rendered, during the development stage, the artist can draw multiple hairstyles and configure a unique identifier for each hairstyle. After the drawing is completed, each hairstyle can be divided according to different division methods. For each division method, after the hairstyle is divided into multiple areas according to the division method, the multiple areas can be placed in different texture partitions to obtain the texture horizontal coordinates and texture vertical coordinates of each pixel on the hairstyle under the division method. The texture horizontal coordinates and texture vertical coordinates can be used as texture coordinate data, and the terminal can store the identifier of the hairstyle, the style information corresponding to the division method, and the texture coordinate data as a set of gradient data.

[0131] The terminal can read locally stored rendering data, extract an identifier of the object to be rendered from the rendering data, and based on the extracted identifier of the object to be rendered, search for gradient data that matches the identifier from the stored gradient data. The terminal can parse the serialized data to obtain style information therein, and search for texture coordinate data corresponding to the object to be rendered that matches the style information from the gradient data obtained, and then determine the first position information and second position information corresponding to each pixel on the object to be rendered from the texture coordinate data.

[0132] Among them, the terminal can determine whether there is a dyeing configuration identifier of the object to be rendered in the rendering data. If so, it will search for the rendering material required to create the dyeing configuration identifier in the preset mapping relationship, and create the corresponding rendering material based on the search result; if there is no dyeing configuration identifier of the object to be rendered in the rendering data, the object to be rendered will not be processed.

[0133] Among them, after creating the rendering material, the terminal can read the dyeing configuration parameters according to the dyeing configuration identifier, and map the dyeing configuration parameters to the rendering material according to the data mapping relationship corresponding to the dyeing configuration identifier to obtain the target rendering material.

[0134] Among them, the dyeing configuration parameters include default color configuration information, default color change information, etc. These parameters can be mapped to the rendering material to obtain the target rendering material. The number of rendering materials can be one or more than one, and this embodiment of the application does not limit this.

[0135] The terminal can further determine whether the rendering data contains designated hair dye data. If so, it extracts a custom hair dye identifier from the designated hair dye data. Based on the custom hair dye identifier, it obtains a data parsing table for the serialized data in the designated hair dye data. Based on the parsing table, it parses the serialized data in the designated hair dye data to obtain a parsing result. If the designated hair dye data does not exist, the terminal determines the color of each pixel in the object to be rendered based on the target rendering material.

[0136] After obtaining the parsing result, the terminal may update the rendering material based on the parsing result; and the terminal may determine the color of each pixel on the object to be rendered based on the updated rendering material.

[0137] For each pixel, the updated rendering material includes color configuration information and color change information for the target texture to which the pixel belongs. Based on this color configuration information, color change information, and the texture coordinate of the pixel in the target rendering style, the color of each pixel on the object to be rendered can be determined. The updated rendering material may also include other parameters. After determining the preliminary color of a pixel based on the color configuration information, color change information, and the texture coordinate of a pixel in the target rendering style, the terminal may also optimize the preliminary color using a corresponding formula based on the other parameters to obtain the final color of the pixel.

[0138] For example, FIG13 is a schematic diagram of an image corresponding to an object to be rendered generated by the terminal when the user specifies up and down gradient; FIG14 is a schematic diagram of an image corresponding to an object to be rendered generated by the terminal when the user specifies left and right gradient.

[0139] In the above embodiment, a rendering material may be created based on the rendering data, and corresponding coloring configuration parameters may be filled into the rendering material. Based on the obtained rendering material, the color of each pixel on the object to be rendered is determined.

[0140] In some embodiments, the serialized data in the specified hair dyeing data is parsed to obtain a parsing result, including: obtaining a data parsing table of the serialized data in the specified hair dyeing data, the data parsing table containing the space occupied by different parameters in the serialized data; splitting the serialized data according to the space occupied by different parameters to obtain the parameters contained in the serialized data, and using the parameters contained in the serialized data as the parsing result.

[0141] The data parsing table may include information such as parameter identifiers, parameter types, occupied space, and conversion modes for each parameter. The terminal may extract serialized data from the specified hair dyeing data, and based on the occupied space of the first parameter in the data parsing table, extract the first corresponding number of digits of data from the serialized data as the value of the first parameter; based on the occupied space of the second parameter in the data parsing table, extract the corresponding number of digits of data from the remaining data as the value of the second parameter, and so on, until there is no remaining data. The extracted data may be used as the parameters included in the serialized data, and the parameters included in the serialized data may be used as the parsing results.

[0142] For example, assume that the user sets the hue (H), saturation (S), and value (V) values ​​to 0xAA, 0xBB, and 0xCC, respectively. The user sets the gradient position to 0x32. Serializing this data yields the serialized data 0xAABBCC32, where 0x is a hexadecimal symbol. Assume that the data parsing table for the serialized data in the specified hair dyeing data is as shown in Table 1:

[0143] Table 1

[0144] Among them, based on the analysis table shown in Table 1, it can be seen that the type of the first parameter in the serialized data is color, and the space occupied by this parameter is 3 bytes. Therefore, the first 6 bits of data in AABBCC32 are intercepted to obtain AABBCC, and AABBCC can be used as the value of the first parameter. Based on the analysis table in Table 1, it can be seen that the conversion mode of the first parameter is HSV, and the hue value can be further determined to be AA, the saturation value is BB, and the lightness value is CC. Based on the analysis table shown in Table 1, it can be seen that the type of the second parameter in the serialized data is gradient position, and the space occupied by this parameter is 1 byte. After the interception operation corresponding to the first parameter, two bits of data remain in the serialized data. These two bits of data (32) can be used as the value of the second parameter. Based on the analysis table in Table 2, it can be seen that the type of the second parameter is gradient position, and the gradient position can be determined to be 32.

[0145] In the above embodiment, the color configuration information and color change information are serialized, which can reduce the storage space occupied and facilitate network communication between terminals, servers and other terminals. If the serialized data is not parsed using the corresponding parsing table, the correct display effect cannot be obtained, which can improve security, increase the cost of third-party attacks and tampering during network communication, and reduce the possibility of attacks and tampering.

[0146] In some embodiments, based on the parsing results, the parameters in the rendering material are updated, including: for each parameter in the parsing results, searching for the material identifier corresponding to the parameter in the data mapping relationship; based on the parameter, updating the rendering material corresponding to the material identifier.

[0147] The dyeing configuration parameters include default color configuration information, default color variation information, and other parameters. Different rendering materials may include some or all of these parameters. After parsing the serialized data in the specified hair dyeing data and obtaining the parsing results, the material identifier corresponding to each parameter included in the parsing results can be searched in the data mapping relationship. The parameter values ​​in the rendering material corresponding to the material identifiers are then updated to the values ​​in the parsing results.

[0148] For example, as shown in Figure 15, the serialized data can be parsed according to the data parsing table to obtain parameter data 1, parameter data 2 and parameter data 3. According to the data mapping relationship, parameter data 1 corresponds to material 1 and material 2, parameter data 2 corresponds to material 1 and material 2, and parameter data 3 corresponds to material 1. Parameter data 1, parameter data 2 and parameter data 3 can be updated to material 1, and parameter data 1 and parameter data 2 can be updated to material 2 to obtain updated material 1 and updated material 2.

[0149] After obtaining the updated rendering material, the terminal may optimize the color of each pixel based on the updated rendering material, and generate an image corresponding to the object to be rendered based on the optimized color corresponding to each pixel.

[0150] In the above embodiment, after parsing the serialized data to obtain the parsing result, the parameter value in the rendering material is updated based on the parsing result, thereby obtaining an updated rendering material. The rendering material can be used to optimize the color of each pixel on the rendered object, making the final generated image more realistic and vivid, thereby improving the image presentation effect.

[0151] In some embodiments, the image processing method provided by the embodiments of the present application also includes: determining the random grayscale value of each component of the object to be rendered; obtaining the target component within a preset grayscale range, and updating the pixels contained in the target component to a preset color.

[0152] The object to be rendered may be the hairstyle, clothing, etc. of the virtual character. In the case where the object to be rendered is the hairstyle of the virtual character, the components of the object to be rendered may be the hair strands included in the hairstyle of the virtual character.

[0153] The terminal may randomly assign a grayscale value to each component of the object to be rendered, and use the grayscale value as the random grayscale value of the corresponding component, so that each component of the object to be rendered has a corresponding random grayscale value.

[0154] The terminal may match the grayscale value of each component with a preset grayscale range. If the grayscale value of the component falls within the preset grayscale range, the component is designated as the target component. The terminal may further update the pixels included in each target component to a preset color. The preset color may be user-specified or default, and this embodiment of the application is not limited thereto.

[0155] In a specific implementation, the image processing method provided by the embodiment of the present application can be applied to a certain game APP. The object to be rendered can be the hairstyle of a virtual character, and the various components of the object to be rendered can be the hair strands included in the hairstyle of the virtual character. The user can log in to the game APP using an account and open the virtual character hair setting page on the game APP. The virtual character hair setting page provides a highlighting control. The user can click the highlighting control. In response to the click operation, the game APP can randomly assign a grayscale value to each hair strand included in the hairstyle of the virtual character corresponding to the account used when logging in, and the grayscale value can be used as the random grayscale value of the hair strand. The game APP can match the grayscale value of each hair strand with a preset grayscale range. If the grayscale value of the hair strand falls within the preset grayscale range, the hair strand will be used as the target hair strand, and the terminal can update the pixels included in the target hair strand to a preset color, thereby achieving the highlighting of the virtual character's hairstyle. For example, Figure 16 is a schematic diagram of the image of the object to be rendered generated by the terminal after the user clicks the highlighting control.

[0156] In the above embodiment, the random grayscale values ​​of the components of the object to be rendered are first determined; then the target component within the preset grayscale range is obtained, and the pixels contained in the target component are updated to the preset color, thereby achieving highlighting of the object to be rendered and improving the diversity of image presentation effects.

[0157] In some embodiments, the image processing method provided by the embodiments of the present application further includes: serializing style information, color configuration information and color change information to obtain serialized data; in response to a data synchronization request, sending the serialized data to the server to instruct the server to synchronize the serialized data to the target terminal, and the target terminal has an associated relationship with the terminal corresponding to the object to be rendered.

[0158] Among them, the terminal can serialize the style information, color configuration information and color change information to obtain serialized data; when the user is satisfied with the effect of the image corresponding to the rendered object, a data synchronization request can be triggered, and the terminal can send the serialized data to the server in response to the data synchronization request.

[0159] Among them, the data synchronization request carries the account corresponding to the object to be rendered. After receiving the data synchronization request, the server can obtain the accounts that have an interactive relationship with the account based on the account, use the terminals corresponding to these accounts as target terminals, and send the serialized data to the target terminal. When the target terminal displays the object to be rendered, it generates the corresponding image according to the serialized data, so that the presentation effect of the object to be rendered is synchronized on each terminal.

[0160] Among them, the account that has an interactive relationship with a certain account can be an account that has a friend relationship with the account, or an account that participates in a three-dimensional competitive game together with the account.

[0161] In a specific implementation, the image processing method provided in the embodiment of the present application can be applied to a certain game APP. The object to be rendered can be the hairstyle of a virtual character. If the user is satisfied with the effect of the virtual character's hairstyle, a data synchronization request can be triggered in the game APP. The terminal sends the account and serialized data used when logging in to the server. Based on the account, the server searches for accounts that have an interactive relationship with the account, and sends the serialized data to the terminals corresponding to these accounts, so that the hairstyle effects presented by each terminal are consistent.

[0162] In the above embodiment, when it is determined that the generated image corresponding to the object to be rendered meets the requirements, the user can trigger a data synchronization request, and the serialized data can be synchronized to other terminals with interactive relationships through the server, so that the presentation effect of the object to be rendered is synchronized on each terminal.

[0163] In some embodiments, the image processing method provided by the embodiments of the present application can be applied in a game scene, where the object to be rendered is the hairstyle of a virtual character, the target rendering style is a hair gradient style specified for the hairstyle of the virtual character, the color configuration information includes at least one of hue, brightness or saturation, and the color change information includes at least one of a gradient position and a gradient range.

[0164] Among them, a game APP corresponding to the game scene is installed on the terminal. The user can specify a rendering style for the virtual character's hairstyle on the game APP, specify the hue combination information of the texture partition under the rendering style, specify the primary and secondary attributes, brightness and saturation for each color in the hue combination information, and also specify the gradient position and gradient range of the texture partition. The terminal can determine the texture horizontal coordinates of each pixel on the virtual character's hairstyle under the rendering style based on the style information of the rendering style specified by the user, and determine the target texture partition to which each pixel belongs based on the texture horizontal coordinates of each pixel under the rendering style; determine the color of each pixel on the virtual character's hairstyle based on the hue combination information of the target texture partition, the primary and secondary attributes, brightness, saturation of each color in the hue combination information, the gradient position and gradient range of the target texture partition, and the texture vertical coordinate of each pixel on the virtual character's hairstyle under the rendering style, and generate an image corresponding to the virtual character's hairstyle based on the color of each pixel on the virtual character's hairstyle for the user to view.

[0165] In the above embodiment, a specific implementation process of applying the image processing method provided in the embodiment of the present application in a game scenario is provided. This method allows game players to freely set the hairstyle and dyeing style of the virtual character, thereby increasing the space for personalized play.

[0166] It should be noted that the application scenarios provided above are only used to illustrate the image processing method of this application, and the application of the image processing method provided in this application is not limited to the application scenarios provided above. For example, it can also be applied in image editing scenarios, photo taking scenarios, etc., which are not limited in the embodiments of this application.

[0167] In some embodiments, an image processing method is provided, which is described by taking the application of the method to a terminal as an example, including the following steps:

[0168] In response to a rendering style specification operation, the specified rendering style corresponding to the rendering style specification operation is used as the target rendering style, and the style information of the specified rendering style is used as the style information of the target rendering style; the hue combination information of each texture partition under the target rendering style is obtained through the hue combination configuration area; the color attribute information of each color contained in the hue combination information is determined based on the attribute adjustment controls of each color in the hue combination information contained in the color attribute configuration area. The color configuration information of each texture partition under the target rendering style is determined based on the hue combination information and the color attribute information; and the color change information of each texture partition under the target rendering style is determined based on the color change controls of each texture partition under the target rendering style contained in the color change configuration area.

[0169] According to the style information, texture coordinate data corresponding to the object to be rendered and matching the style information is searched; the texture horizontal coordinates of each pixel on the object to be rendered are searched from the texture coordinate data, and the texture horizontal coordinates of each pixel are used as the first position information of the corresponding pixel under the target rendering style.

[0170] Obtain the position range corresponding to each texture partition under the target rendering style; for each pixel on the object to be rendered, match the first position information of the pixel with each position range, and determine the target texture partition to which the pixel belongs based on the matching result.

[0171] For each pixel on the object to be rendered, determine the partition primary color and the partition secondary color of the target texture partition based on the color configuration information of the target texture partition to which the pixel belongs; determine a first pixel value based on the partition primary color, the second position information of the target pixel under the target rendering style, and the color change information of the target texture partition to which it belongs; determine a second pixel value based on the partition secondary color, the second position information of the target pixel under the target rendering style, and the color change information of the target texture partition to which it belongs; and determine the color of the target pixel based on the first pixel value and the second pixel value.

[0172] The color of each pixel on the object to be rendered is mapped to the area on the display screen to generate an image corresponding to the object to be rendered.

[0173] In the above embodiment, a target rendering style is determined, style information of the target rendering style, color configuration information of each texture partition under the target rendering style, and color change information are obtained. Based on the style information, first position information of each pixel on the object to be rendered under the target rendering style is determined; based on the first position information of each pixel under the target rendering style, the target texture partition to which each pixel belongs is determined; based on the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style, the color of each pixel on the object to be rendered is determined; and the color of each pixel on the object to be rendered is mapped to an area on the display screen to generate an image corresponding to the object to be rendered. The generated image of the object to be rendered corresponds to the target rendering style, and different rendering styles correspond to different image presentation effects. This method provides users with a rendering style selection portal, allowing users to select the most appropriate rendering style from multiple rendering styles, thereby increasing the user's personalized design space for the rendered object and avoiding the problem of low dyeing efficiency caused by multiple dyeing adjustments when the dyeing function is single.

[0174] It should be understood that, although the steps in the flowcharts of the above embodiments are shown in sequence as indicated by the arrows, these steps are not necessarily performed in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and these steps can be performed in other orders. Moreover, at least a portion of the steps in the flowcharts of the above embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily performed at the same time, but can be performed at different times. The execution order of these steps or stages is not necessarily to be performed in sequence, but can be performed in turn or alternately with other steps or at least a portion of steps or stages in other steps.

[0175] Based on the same inventive concept, embodiments of the present application also provide an image processing device for implementing the aforementioned image processing method. The solution provided by this device is similar to the solution described in the aforementioned method. Therefore, the specific limitations in one or more of the following image processing device embodiments can be found in the above-described limitations on the image processing method and will not be further elaborated here.

[0176] In one embodiment, as shown in FIG17 , an image processing apparatus is provided, including:

[0177] An acquisition module 1701 is configured to determine a target rendering style, acquire style information of the target rendering style, and color configuration information and color change information of each texture partition under the target rendering style.

[0178] A first determining module 1702 is configured to determine, based on the style information, first position information of each pixel on the object to be rendered in a target rendering style; and determine, based on the first position information of each pixel in the target rendering style, a target texture partition to which each pixel belongs.

[0179] A second determining module 1703 is configured to determine the color of each pixel on the object to be rendered based on the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered under the target rendering style;

[0180] The generation module 1704 is configured to map the color of each pixel on the object to be rendered to an area on the display screen, and generate an image corresponding to the object to be rendered.

[0181] In some embodiments, the acquisition module 1701 is specifically used to respond to a rendering style specification operation, use the specified rendering style corresponding to the rendering style specification operation as the target rendering style, and use the style information of the specified rendering style as the style information of the target rendering style; display the rendering configuration area corresponding to the target rendering style, and obtain color configuration information and color change information of each texture partition under the target rendering style through the rendering configuration area.

[0182] In some embodiments, the rendering configuration area includes a hue combination configuration area, a color change configuration area, and a color attribute configuration area; the acquisition module 1701 is specifically used to obtain the hue combination information of each texture partition under the target rendering style through the hue combination configuration area; obtain the color attribute information of each color contained in the hue combination information through the color attribute configuration area; determine the color configuration information of each texture partition under the target rendering style based on the hue combination information and the color attribute information; obtain the color change information of each texture partition under the target rendering style through the color change configuration area.

[0183] In some embodiments, the color attribute configuration area includes attribute adjustment controls for each color in the hue combination information; the acquisition module 1701 is specifically used to determine the color attribute information of each color included in the hue combination information based on a touch operation on the attribute adjustment controls.

[0184] In some embodiments, the color change configuration area includes color change controls for each texture partition under the target rendering style; the acquisition module 1701 is specifically used to determine color change information of each texture partition under the target rendering style based on a touch operation on the color change control.

[0185] In some embodiments, the first determination module 1702 is specifically used to search for texture coordinate data corresponding to the object to be rendered and matching the style information based on the style information; search for the texture horizontal coordinates of each pixel on the object to be rendered from the texture coordinate data, and use the texture horizontal coordinates of each pixel as the first position information of the corresponding pixel under the target rendering style.

[0186] In some embodiments, the first determination module 1702 is specifically used to obtain the position range corresponding to each texture partition under the target rendering style; for each pixel on the object to be rendered, the first position information of the pixel is matched with each position range, and the target texture partition to which the pixel belongs is determined based on the matching result.

[0187] In some embodiments, the second determination module 1703 is specifically used to determine, for each pixel on the object to be rendered, the partition primary color and the partition secondary color of the target texture partition based on the color configuration information of the target texture partition to which the targeted pixel belongs; determine a first pixel value based on the partition primary color, the second position information of the targeted pixel under the target rendering style, and the color change information of the target texture partition to which it belongs; determine a second pixel value based on the partition secondary color, the second position information of the targeted pixel under the target rendering style, and the color change information of the target texture partition to which it belongs; and determine the color of the targeted pixel based on the first pixel value and the second pixel value.

[0188] In some embodiments, the generation module 1704 is specifically used to create a corresponding rendering material based on the dyeing configuration identifier when there is a dyeing configuration identifier of the object to be rendered in the locally stored rendering data; read the dyeing configuration parameters according to the dyeing configuration identifier, and map the dyeing configuration parameters to the rendering material according to the data mapping relationship corresponding to the dyeing configuration identifier; when there is also specified hair dyeing data in the locally stored rendering data, parse the serialized data in the specified hair dyeing data to obtain a parsing result, the serialized data including color configuration information and color change information; based on the parsing result, update the rendering material; based on the updated rendering material, determine the color of each pixel on the object to be rendered.

[0189] In some embodiments, the generation module 1704 is also used to obtain a data parsing table of the serialized data in the specified hair dyeing data, where the data parsing table contains the space occupied by different parameters in the serialized data; the serialized data is split according to the space occupied by different parameters to obtain the parameters contained in the serialized data, and the parameters contained in the serialized data are used as the parsing results.

[0190] In some embodiments, the generation module 1704 is further configured to search for a material identifier corresponding to each parameter in the parsing result in the data mapping relationship; and update the rendering material corresponding to the material identifier based on the parameter.

[0191] In some embodiments, the generation module 1704 is further configured to determine random grayscale values ​​of components of the object to be rendered; based on the random grayscale values, obtain a target component within a preset grayscale range, and update the pixels contained in the target component to a preset color.

[0192] In some embodiments, the generation module 1704 is also used to serialize the style information, color configuration information and color change information to obtain serialized data; in response to a data synchronization request, the serialized data is sent to the server to instruct the server to synchronize the serialized data to the target terminal, and the target terminal is associated with the terminal corresponding to the object to be rendered.

[0193] In some embodiments, the object to be rendered is the hairstyle of a virtual character, the target rendering style is a hair gradient style specified for the hairstyle of the virtual character, the color configuration information includes at least one of hue, brightness or saturation, and the color change information includes at least one of a gradient position and a gradient range.

[0194] Each module in the above-mentioned image processing device can be implemented in whole or in part through software, hardware, or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in the computer device in the form of software, so that the processor can call and execute the corresponding operations of each module.

[0195] In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be shown in Figure 18. The computer device includes a processor, memory, an input / output interface, a communication interface, a display unit, and an input device. The processor, memory, and input / output interface are connected via a system bus, and the communication interface, display unit, and input device are connected to the system bus via the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal via wired or wireless communication, and the wireless communication may be implemented via Wi-Fi, a mobile cellular network, NFC (near field communication), or other technologies. When the computer program is executed by the processor, it implements an image processing method. The display unit of the computer device is used to form a visually visible image, and can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device casing, or an external keyboard, touchpad or mouse, etc.

[0196] Those skilled in the art will understand that the structure shown in Figure 18 is merely a block diagram of a portion of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.

[0197] In one embodiment, a computer device is further provided, including a memory and a processor. The memory stores a computer program, and the processor implements the steps in the above method embodiments when executing the computer program.

[0198] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.

[0199] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.

[0200] It should be noted that the user information (including but not limited to the user's account, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions.

[0201] Those skilled in the art will appreciate that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, database or other media used in the embodiments provided in this application may include at least one of non-volatile and volatile memory. Non-volatile memory may include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory may include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in the various embodiments provided herein may include at least one of a relational database and a non-relational database. Non-relational databases may include, but are not limited to, distributed databases based on blockchains. The processor involved in the various embodiments provided herein may be, but are not limited to, a general-purpose processor, a central processing unit, a graphics processing unit, a digital signal processor, a programmable logic unit, a data processing logic unit based on quantum computing, and the like.

[0202] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0203] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present invention. It should be noted that a person skilled in the art could make various modifications and improvements without departing from the spirit of the present application, all of which fall within the scope of protection of the present application. Therefore, the scope of protection of the present patent application shall be determined by the appended claims.

Claims

1. An image processing method, executed by a computer device, comprising: Determine a target rendering style, obtain style information of the target rendering style, color configuration information and color change information of each texture partition under the target rendering style; Determining first position information of each pixel on the object to be rendered in a target rendering style according to the style information; Determine, according to the first position information of each pixel in the target rendering style, the target texture partition to which each pixel belongs; Determining the color of each pixel on the object to be rendered according to the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered in the target rendering style; and The color of each pixel on the object to be rendered is mapped to an area on the display screen to generate an image corresponding to the object to be rendered.

2. According to the method of claim 1, the determining the target rendering style and obtaining the style information of the target rendering style, the color configuration information and the color change information of each texture partition under the target rendering style, comprises: In response to a rendering style specifying operation, taking a specified rendering style corresponding to the rendering style specifying operation as a target rendering style, and taking style information of the specified rendering style as style information of the target rendering style; The rendering configuration area corresponding to the target rendering style is displayed, and the color configuration information and color change information of each texture partition under the target rendering style are obtained through the rendering configuration area.

3. According to the method of claim 2, the rendering configuration area includes a hue combination configuration area, a color change configuration area and a color attribute configuration area; The rendering configuration area corresponding to the target rendering style is displayed, and the color configuration information and color change information of each texture partition under the target rendering style are obtained through the rendering configuration area, including: Obtaining hue combination information of each texture partition under the target rendering style through the hue combination configuration area; Obtaining color attribute information of each color included in the hue combination information through the color attribute configuration area; Determining color configuration information of each texture partition under a target rendering style based on the hue combination information and the color attribute information; The color change information of each texture partition under the target rendering style is obtained through the color change configuration area.

4. The method according to claim 3, wherein the color attribute configuration area includes attribute adjustment controls for each color in the hue combination information; The step of obtaining the color attribute information of each color included in the hue combination information through the color attribute configuration area includes: Based on the touch operation on the property adjustment control, the color property information of each color included in the hue combination information is determined.

5. The method according to claim 3, wherein the color change configuration area comprises color change controls for each texture partition under a target rendering style; The obtaining, through the color change configuration area, color change information of each texture partition under the target rendering style includes: Based on the touch operation on the color change control, color change information of each texture partition under the target rendering style is determined.

6. The method according to any one of claims 1 to 5, wherein determining, according to the style information, first position information of each pixel on the object to be rendered in a target rendering style comprises: According to the style information, searching for texture coordinate data corresponding to the object to be rendered and matching the style information; The texture abscissa of each pixel on the object to be rendered is searched from the texture coordinate data, and the texture abscissa of each pixel is used as the first position information of the corresponding pixel in the target rendering style.

7. The method according to any one of claims 1 to 6, wherein determining the target texture partition to which each pixel belongs according to the first position information of each pixel in the target rendering style comprises: Get the position range corresponding to each texture partition under the target rendering style; For each pixel on the object to be rendered, the first position information of the targeted pixel is matched with each position range, and the target texture partition to which the targeted pixel belongs is determined based on the matching result.

8. The method according to any one of claims 1 to 7, wherein determining the color of each pixel on the object to be rendered according to the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered in the target rendering style comprises: For each pixel on the object to be rendered, determine the partition primary color and the partition secondary color of the target texture partition according to the color configuration information of the target texture partition to which the pixel belongs; Determine a first pixel value according to the partition main color, second position information of the targeted pixel in the target rendering style, and color change information of the target texture partition; Determine a second pixel value according to the partition secondary color, second position information of the targeted pixel in the target rendering style, and color change information of the target texture partition; Based on the first pixel value and the second pixel value, a color of the targeted pixel is determined.

9. The method according to any one of claims 1 to 8, wherein determining the color of each pixel on the object to be rendered according to the color configuration information of the target texture partition, the color change information of the target texture partition, and the second position information of each pixel on the object to be rendered in the target rendering style comprises: When there is a dyeing configuration identifier of the object to be rendered in the locally stored rendering data, creating a corresponding rendering material based on the dyeing configuration identifier; Reading dyeing configuration parameters according to the dyeing configuration identifier, and mapping the dyeing configuration parameters to the rendering material according to the data mapping relationship corresponding to the dyeing configuration identifier; If the locally stored rendering data still contains designated hair dyeing data, parsing the serialized data in the designated hair dyeing data to obtain a parsing result, wherein the serialized data includes the color configuration information and the color change information; Based on the analysis result, updating the rendering material; Based on the updated rendering material, the color of each pixel on the object to be rendered is determined.

10. The method according to claim 9, wherein parsing the serialized data in the specified hair dyeing data to obtain the parsing result comprises: Obtaining a data parsing table of serialized data in the specified hair dyeing data, wherein the data parsing table includes the occupied space size of different parameters in the serialized data; The serialized data is split according to the sizes of the spaces occupied by the different parameters to obtain the parameters included in the serialized data, and the parameters included in the serialized data are used as parsing results.

11. The method according to claim 9 or 10, wherein updating the parameters in the rendering material based on the parsing result comprises: For each parameter in the analysis result, searching the data mapping relationship for a material identifier corresponding to the parameter; Based on the targeted parameters, the rendering material corresponding to the material identifier is updated.

12. The method according to any one of claims 1 to 11, further comprising: Determining a random grayscale value of each component of the object to be rendered; Based on the random grayscale value, a target component in a preset grayscale range is obtained, and pixels included in the target component are updated to a preset color.

13. The method according to any one of claims 1 to 12, further comprising: Performing serialization processing on the style information, the color configuration information and the color change information to obtain serialized data; In response to the data synchronization request, the serialized data is sent to the server to instruct the server to synchronize the serialized data to a target terminal, where the target terminal is associated with a terminal corresponding to the object to be rendered.

14. According to the method described in any one of claims 1 to 13, the object to be rendered is the hairstyle of a virtual character, the target rendering style is a hair gradient style specified for the hairstyle of the virtual character, the color configuration information includes at least one of hue, brightness or saturation, and the color change information includes at least one of a gradient position and a gradient range.

15. An image processing device, comprising: An acquisition module, used to determine a target rendering style, acquire style information of the target rendering style, color configuration information of each texture partition under the target rendering style, and color change information; A first determination module, configured to determine first position information of each pixel on the object to be rendered in a target rendering style according to the style information; Determine, according to the first position information of each pixel in the target rendering style, the target texture partition to which each pixel belongs; A second determination module is used to determine the color of each pixel on the object to be rendered according to the color configuration information of the target texture partition, the color change information of the target texture partition and the second position information of each pixel on the object to be rendered in the target rendering style; The generation module is used to map the color of each pixel on the object to be rendered to an area on the display screen to generate an image corresponding to the object to be rendered.

16. A computer device comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the method according to any one of claims 1 to 14 when executing the computer program.

17. A computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the method according to any one of claims 1 to 14.

18. A computer program product, comprising a computer program, which, when executed by a processor, implements the steps of the method according to any one of claims 1 to 14.

Citation Information

Patent Citations

  • Color rendering method and device for virtual image, terminal and storage medium

    CN110796721A

  • Image rendering method and device, computer readable storage medium and electronic equipment

    CN113450440A

  • Hair rendering method and device and electronic equipment

    CN113888398A

  • Image rendering method and device, equipment, storage medium and program product

    CN114067042A

  • Generating textured polygon strip hair from strand-based hair for a virtual character

    WO2019226494A1