Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the present invention's part embodiment, rather than whole embodiment.Embodiment based in the present invention, those of ordinary skills, not making the every other embodiment obtaining under creative work prerequisite, belong to the scope of protection of the invention.
Please refer to Fig. 1, is a kind of process flow diagram that changes the embodiment of figural method in web game provided by the invention, and described method comprises:
Step S11, is divided into different figure layers by the current figural position that changes the outfit; Wherein, comprise can modification figure layer for described different figure layer;
Wherein, a complete figure image, comprises a plurality of positions that change the outfit.For example, figure image can be divided into 7 positions that change the outfit, be respectively: weapon position, cap position, clothes position, face decorations position, hair position, glasses position, face position.Certainly, the division methods at the figural position that changes the outfit is not limited to the above-mentioned mode of enumerating.
In this step, the described figural position that changes the outfit is divided into different figure layers, refers to the picture at the same position that changes the outfit is divided into different figure layers.Different figure layers specifically comprise can modification figure layer and fixing figure layer.Wherein, can comprise article figure layer and skin figure layer by modification figure layer, fixing figure layer comprises original graph layer.Wherein, skin figure layer refers to figure layer corresponding to skin that in this position that changes the outfit, user can see.Article figure layer, refers to figure layer corresponding to other changeable colour article of removing skin in this position that changes the outfit.Wherein, original graph layer, refers to a figure layer that the complete position that changes the outfit is corresponding.Wherein, a complete position that changes the outfit comprises: the skin that user can see, remove skin other changeable colour article, remove skin other can not variable color article.
Step S12, receives the information that changes the outfit from the position that changes the outfit described in the change of client; The described information of changing the outfit comprises the described colouring information that can modification figure layer correspondence of being inputted by client;
Wherein, can revise the corresponding a kind of colouring information of figure layer for one.Therefore can understand like this, the information of changing the outfit comprises one or more colouring informations that can modification figure layer correspondence.Wherein, the colouring information that the difference at the same position that changes the outfit can modification figure layer correspondence is inputted respectively by client.
For example, as described above can comprise article figure layer and skin figure layer by modification figure layer, so correspondingly, client is when the information that changes the outfit at the position that changes the outfit described in input changes, can input respectively the colouring information of article figure layer correspondence and/or the colouring information of skin figure layer correspondence, this colouring information is specially and can be color value.Like this, client can select to change the same one or more colouring informations that can modification figure layer correspondence that change the outfit in position.For the same position that changes the outfit, what client was inputted becomes many for changing the combination of the colouring information at this position that changes the outfit; Correspondingly, receive how also having become for changing the combination of the colouring information at this position that changes the outfit from client.
Step S13, by storage current figural figure image information with described in the information of changing the outfit compare, obtain the information of changing the outfit;
Wherein, current figural figure image information, the colouring information and the style information that comprise the difference figure layer correspondence at a plurality of positions that change the outfit in whole figure image, specifically comprise the colouring information of fixedly figure layer correspondence at a plurality of positions that change the outfit and style information, a plurality of positions that change the outfit can modification figure layer correspondence colouring information and style information.
In specific implementation, by current figural figure image information with described in the information of changing the outfit while comparing, specifically by a plurality of positions that change the outfit in current figure image information can modification figure layer correspondence colouring information with described in can the modification figure layer corresponding colouring information that comprises of the information of changing the outfit compare, to determine the described replacement information that changes the outfit.The described replacement information of changing the outfit comprises the colouring information of replacement figure layer correspondence, is used to indicate the colouring information of variation diagram layer correspondence in current figural figure image information.Wherein, the colouring information of variation diagram layer correspondence refers to the colouring information that needs the figure layer correspondence of modification in figure image information.Variation diagram layer must be can modification figure layer.Owing to receiving how having become for changing the combination of the colouring information at this position that changes the outfit from client in step S12, the change the outfit combination of information of the replacement of determining in this step so has also become many, the information of changing the outfit can be indicated the colouring information of a variation diagram layer correspondence, also can indicate the colouring information of a plurality of variation diagram layer correspondence.
It should be noted that, in this step, if do not obtain the information of changing the outfit relatively, show not need in current figure image information the colouring information of the figure layer correspondence of modification, exit flow process.
Step S14, the corresponding colouring information of revising variation diagram layer correspondence in described figure image information, and draw new figure image, and provide described new figure image to this client; Wherein, the colouring information of described variation diagram layer correspondence is that the described replacement information that changes the outfit is indicated.
In this step, according to the indication of the information that changes the outfit described in step S13, the corresponding colouring information that needs variation diagram layer correspondence of revising.Because of client input can revise the corresponding a kind of colouring information of figure layer, a variation diagram layer of determining is so corresponding a kind of colouring information also, therefore in this step, can revise respectively the colouring information of different variation diagram layer correspondences.
And, because the change the outfit combination of information of the replacement relatively obtaining in step S13 becomes many, correspondingly, it is many that the combination of colouring information that can modification figure layer correspondence in the figure image information obtaining after modification has also become, and the new figure image of finally drawing out and providing to client according to this figure image information is also abundanter.
In the present embodiment, by the same position that changes the outfit being divided into a plurality of different figure layers, and the colouring information that receives the revised figure layer correspondence of client input, thereby determine and the corresponding colouring information of revising variation diagram layer correspondence in current figure image, obtain amended figure image information.Because client can be inputted one or more colouring informations that can modification figure layer correspondence, what therefore make to receive becomes many for changing the combination of the colouring information at this position that changes the outfit; Correspondingly, after correspondence is revised the colouring information of variation diagram layer correspondence, the combination of colouring information that can modification figure layer correspondence in the figure image information obtaining has also increased, finally draw and the new figure image that provides to client also abundanter, meet better user's individual sexual demand.Meanwhile, owing to only need to revising the colouring information of variation diagram layer correspondence in the same position that changes the outfit, and other figure layer that this is changed the outfit in position does not process, like this request of customer in response end has fast reduced time delay.
It should be noted that the present embodiment only relates to the one or more colouring informations that can modification figure layer correspondence that change the same position that changes the outfit in same figure image.Be understandable that, utilize the method in the present embodiment, also can change in same figural other position that changes the outfit simultaneously can modification figure layer correspondence colouring information.
Please refer to Fig. 2, is the corresponding colouring information of revising variation diagram layer correspondence in described figure image information described in the embodiment shown in invention Fig. 1, and draws the process flow diagram of the embodiment of new figural method, and described method comprises:
Step S21, the color value of the article replacement figure layer comprising according to the described replacement information of changing the outfit and/or the color value of skin replacement figure layer, search the variation article figure layer in described figure image information and/or change skin figure layer;
When the described position that changes the outfit can modification figure layer comprise article figure layer and skin figure layer time, the described replacement information of changing the outfit comprises the color value of article replacement figure layer and/or the color value of skin replacement figure layer.The color value of this article replacement figure layer and/or the color value of skin replacement figure layer are indicated the color value of variation diagram layer correspondence in current figure image information.Therefore, color value and/or the skin of according to these article, replacing figure layer are replaced the color value of scheming layer, can find out the variation article figure layer in current figure image information and/or change skin figure layer (the article figure layer and/or the skin figure layer that need modification in figure image information).
Step S23, builds new article figure layer and/or new skin figure layer; Wherein, described new article figure layer and/or new skin figure layer are replaced described variation article figure layer and/or are changed skin figure layer for corresponding;
Step S24, replaces the color value of figure layer and/or the color value that skin is replaced figure layer according to described article, sets the color value of described new article figure layer and/or the color value of new skin figure layer;
In specific implementation, be that the color value correspondence of the color value of the new article figure layer constructing and/or new skin figure layer is set as to the color value of described article replacement figure layer and/or the color value of skin replacement figure layer, specifically comprise:
The color value of the color value of described article replacement figure layer and/or skin replacement figure layer is converted to respectively to corresponding color matrix;
The corresponding assignment of the described color matrix converting to is given to the color matrix attribute of described new article figure layer and/or new skin figure layer.
Step S25, sequentially superpose described new article figure layer and/or new skin figure layer and described in the change the outfit original graph layer at position, obtain new figure image.
In this step, specifically according to the original graph layer at the position that first changes the outfit, the overlay order of skin figure layer, last article figure layer secondly, superpose described new article figure layer and/or skin figure layer and described in the change the outfit original graph layer at position.
Further, before described structure new article figure layer and/or new skin figure layer, also comprise:
Step S22, destroys the variation article figure layer in described figure image information and/or changes skin figure layer.So, need not store the variation article figure layer in this figure image information and/or change skin figure layer, having saved storage space.
In the present embodiment, the color value of the article replacement figure layer comprising according to the replacement information of changing the outfit and/or the color value of skin replacement figure layer, by step S21-step S25, reached figural object in reconstruct web game.Because different colouring informations that can modification figure layer correspondence in the same position that changes the outfit are modified respectively, therefore when revising, only need to revise the colouring information of variation diagram layer correspondence in this position that changes the outfit, and other figure layer that this is changed the outfit in position does not process, so, the consumption of resource can be reduced, meanwhile, the figure image making new advances can also be built rapidly.
Above-mentioned Fig. 1-Fig. 2 introduces figural method in a kind of change web game provided by the invention, below in conjunction with Fig. 3-Fig. 4, to having adopted said method to change figural device in web game, describes in detail.
Please refer to Fig. 3, is figural device in a kind of change web game provided by the invention, comprising:
Figure layer is divided module 31, for the current figural position that changes the outfit being divided into different figure layers; Wherein, comprise can modification figure layer for described different figure layer;
Wherein, a complete figure image, comprises a plurality of positions that change the outfit.For example, described device can be divided into figure image 7 positions that change the outfit, and is respectively: weapon position, cap position, clothes position, face decorations position, hair position, glasses position, face position.Certainly, the division methods at the figural position that changes the outfit is not limited to the above-mentioned mode of enumerating.
In the present embodiment, figure layer is divided module 31 the described figural position that changes the outfit is divided into different figure layers, refers to the picture at the same position that changes the outfit is divided into different figure layers.For example, scheming layer division module 31 can be divided into the position that changes the outfit and can scheme layer with fixing by modification figure layer.Wherein, can specifically comprise article figure layer and skin figure layer by modification figure layer, fixing figure layer comprises original graph layer.Wherein, skin figure layer refers to figure layer corresponding to skin that in this position that changes the outfit, user can see.Article figure layer, refers to figure layer corresponding to other changeable colour article of removing skin in this position that changes the outfit.Wherein, original graph layer, refers to a figure layer that the complete position that changes the outfit is corresponding.Wherein, a complete position that changes the outfit comprises: the skin that user can see, remove skin other changeable colour article, remove skin other can not variable color article.
Transceiver module 32, for receiving the information that changes the outfit from the position that changes the outfit described in the change of client; Wherein, described in the information of changing the outfit comprise the described colouring information that can modification figure layer correspondence of being inputted by client, describedly can modification figure layer by described figure layer, divide module 31 and divide;
Wherein, can revise the corresponding a kind of colouring information of figure layer for one.Therefore can understand like this, the information of changing the outfit comprises one or more colouring informations that can modification figure layer correspondence.Wherein, the colouring information that the difference at the same position that changes the outfit can modification figure layer correspondence is inputted respectively by client.
For example, as described above can comprise article figure layer and skin figure layer by modification figure layer, so correspondingly, client is when the information that changes the outfit at the position that changes the outfit described in input changes, can input respectively the colouring information of article figure layer correspondence and/or the colouring information of skin figure layer correspondence, this colouring information is specially and can be color value.Like this, client can select to change same figure layer in position or a plurality of colouring information that can modification figure layer correspondence of changing the outfit.That is to say, for the same position that changes the outfit, what client can be inputted becomes many for changing the combination of the colouring information at this position that changes the outfit; Correspondingly, transceiver module 32 receives how also having become for changing the combination of the colouring information at this position that changes the outfit from client.
Comparison module 33, for by storage current figural figure image information and described transceiver module 32 receive described in the information of changing the outfit compare, obtain the information of changing the outfit;
Wherein, current figural figure image information, the colouring information and the style information that comprise the difference figure layer correspondence at a plurality of positions that change the outfit in whole figure image, specifically comprise the colouring information of fixedly figure layer correspondence at a plurality of positions that change the outfit and style information, a plurality of positions that change the outfit can modification figure layer correspondence colouring information and style information.
In specific implementation, by current figural figure image information with described in the information of changing the outfit while comparing, specifically by a plurality of positions that change the outfit in current figure image can modification figure layer correspondence colouring information with described in can the modification figure layer corresponding colouring information that comprises of the information of changing the outfit compare, to determine the described replacement information that changes the outfit, the described replacement information of changing the outfit comprises the colouring information of replacement figure layer correspondence, is used to indicate the colouring information of variation diagram layer correspondence in current figural figure image information.Wherein, the colouring information of variation diagram layer correspondence refers to the colouring information that needs the figure layer correspondence of modification in figure image information.Variation diagram layer must be can modification figure layer.Because transceiver module 31 receives how having become for changing the combination of the colouring information at this position that changes the outfit from client, the change the outfit combination of information of the replacement that comparison module 33 is determined so has also become many, the information of changing the outfit can be indicated the colouring information of a variation diagram layer correspondence, also can indicate the colouring information of a plurality of variation diagram layer correspondence.
Processing module 34, revises the colouring information of described people information variation diagram layer correspondence, and draws new figure image for correspondence; Wherein, the colouring information of described variation diagram layer correspondence is that the described replacement information that changes the outfit that described comparison module 33 relatively obtains is indicated;
The change the outfit indication of information of the described replacement that processing module 34 relatively obtains according to described comparison module 33, the corresponding colouring information of revising variation diagram layer correspondence.Because of client input can revise the corresponding a kind of colouring information of figure layer, a variation diagram layer of determining is so corresponding a kind of colouring information also, so 34 of processing modules can be revised respectively the colouring information of different variation diagram layer correspondences.
And, the change the outfit combination of information of the replacement relatively being obtained by comparison module 33 becomes many, correspondingly, the combination of colouring information that can modification figure layer correspondence in the figure image information that processing module 34 obtains after revising has also become many, and the new figure image of finally drawing out according to this figure image information is also abundanter.
Described transceiver module 32, also sends to client for described processing module 34 is processed to the new figure image obtaining.
In this device, by the same position that changes the outfit being divided into a plurality of different figure layers, and the colouring information that receives the revised figure layer correspondence of client input, thereby determine and the corresponding colouring information of revising variation diagram layer correspondence in current figure image information, obtain amended figure image information.Because client can be inputted one or more colouring informations that can modification figure layer correspondence, what therefore make to receive becomes many for changing the combination of the colouring information at this position that changes the outfit; Correspondingly, after correspondence is revised the colouring information of variation diagram layer correspondence, the combination of colouring information that can modification figure layer correspondence in the figure image information obtaining has also increased, finally draw and the new figure image that provides to client also abundanter, meet better user's individual sexual demand.Meanwhile, owing to only need to revising the colouring information of variation diagram layer correspondence in this position that changes the outfit, other figure layer changing the outfit in position for this does not process, like this request of customer in response end has fast reduced time delay.
It should be noted is that the device in the embodiment of the present invention can be the server in web game.
Need explanation on the other hand, the present embodiment, only relates to the one or more colouring informations that can modification figure layer correspondence that change the same position that changes the outfit in same figure image.Be understandable that, utilize the device in the present embodiment, also can change in same figural other position that changes the outfit simultaneously can modification figure layer correspondence colouring information.
Please refer to Fig. 4, is the structural representation of the embodiment of processing module 34 in Fig. 4 embodiment of the present invention, comprising:
Search unit 41, for the color value of article replacement figure layer and/or the color value of skin replacement figure layer comprising according to the described replacement information of changing the outfit, search the variation article figure layer in described figure image information and/or change skin figure layer;
When the described position that changes the outfit can modification figure layer comprise article figure layer and skin figure layer time, the described replacement information of changing the outfit comprises the color value of article replacement figure layer and/or the color value of skin replacement figure layer.The color value of this article replacement figure layer and/or the color value of skin replacement figure layer are indicated the color value of variation diagram layer correspondence in current figure image information.Therefore, search unit 41 according to the color value of the color value of this article replacement figure layer and/or skin replacement figure layer, can find out the variation article figure layer in current figure image information and/or change skin figure layer (the article figure layer and/or the skin figure layer that need modification in figure image information).
Construction unit 42, for building new article figure layer and/or new skin figure layer, described new article figure layer and/or new skin figure layer are for the variation article figure layer searching unit 41 described in corresponding replacement and find out and/or change skin figure layer;
Setup unit 43, for replace the color value of figure layer and/or the color value that skin is replaced figure layer according to described article, sets the color value of new article figure layer and/or the color value of new skin figure layer that described construction unit 42 builds;
In specific implementation, setup unit 43 is that the color value of new article figure layer and/or the color value correspondence of new skin figure layer that construction unit 42 is constructed are set as the color value of described article replacement figure layer and/or the color value of skin replacement figure layer, specifically comprises:
The color value of the color value of described article replacement figure layer and/or skin replacement figure layer is converted to respectively to corresponding color matrix;
The corresponding assignment of the described color matrix converting to is given to the color matrix attribute of described new article figure layer and/or new skin figure layer.
Superpositing unit 44, new article figure layer and/or the new skin figure layer for the original graph layer at position that changes the outfit described in sequentially stack, described setup unit 3, set, obtain new figure image.
Wherein, superpositing unit 44 is specifically according to the original graph layer at the position that first changes the outfit, the overlay order of skin figure layer, last article figure layer secondly, superpose described new article figure layer and/or skin figure layer and described in the change the outfit original graph layer at position.
Further, before described construction unit 42 builds new article figure layer and/or new skin figure layer, also comprise:
Destroy unit 45, for searching the variation article figure layer of the described figure image information that unit 41 finds out described in destroying and/or changing skin figure layer.Described construction unit 42, after described destruction unit 45 is destroyed described variation article figure layers and/or changed skin figure layer, then builds new article figure layer and/or new skin figure layer.So, need not store the variation article figure layer in this figure image information and/or change skin figure layer, having saved storage space.
In this enforcement, the color value of the article replacement figure layer comprising according to the replacement information of changing the outfit and/or the color value of skin replacement figure layer, by the processing of processing module, reached the figural object in reconstruct web game.Because different colouring informations that can modification figure layer correspondence in the same position that changes the outfit are modified respectively, therefore, when revising, only need to revise the colouring information of variation diagram layer correspondence in this position that changes the outfit, and other figure layer that this is changed the outfit in position does not process.So design, can reduce the consumption of resource, can also build rapidly the figure image making new advances simultaneously.
One of ordinary skill in the art will appreciate that all or part of flow process realizing in above-described embodiment method, to come the hardware that instruction is relevant to complete by computer program, described program can be stored in a computer read/write memory medium, this program, when carrying out, can comprise as the flow process of the embodiment of above-mentioned each side method.Wherein, described storage medium can be magnetic disc, CD, read-only store-memory body (Read-Only Memory, ROM) or random store-memory body (Random Access Memory, RAM) etc.
Above disclosed is only preferred embodiment of the present invention, certainly can not limit with this interest field of the present invention, one of ordinary skill in the art will appreciate that all or part of flow process that realizes above-described embodiment, and the equivalent variations of doing according to the claims in the present invention, still belong to the scope that invention is contained.