Virtual head model construction method, device, computer equipment and storage medium

By receiving the user's head size and images, using the cascaded linear regression model to locate key pixel points, and combining the virtual head model for rendering and adjustment, the problem of low efficiency and high professionalism requirements in the existing technology of virtual head model construction is solved. , realizes efficient and fast virtual facial model generation.

CN110751717BActive Publication Date: 2024-12-17PING AN TECH (SHENZHEN) CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN201910851204.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-09-10
Publication Date
2024-12-17
Estimated Expiration
2039-09-10

AI Technical Summary

Technical Problem

The existing three-dimensional model construction technology for virtual users is difficult to achieve high reduction degree, and it also requires high professionalism and low efficiency for modeling personnel.

Method used

By receiving the user's head size and images, a three-dimensional model is built, and a cascading linear regression model is used to locate key pixel points, and the virtual head model is rendered, supporting customization and automatic adjustment, and a virtual facial model is generated.

Benefits of technology

It realizes the rapid construction of virtual facial models based on user head size and images, reducing operation difficulty and improving efficiency and restoration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN110751717B_ABST
    Figure CN110751717B_ABST
Patent Text Reader

Abstract

The present invention discloses a method, device, computer equipment and storage medium for constructing a virtual head model. The method includes receiving the input user head size; constructing a three-dimensional model according to the user head size to obtain the user head model; receiving the uploaded user head image; according to the one-to-one mapping relationship between the key pixel points of the user head image and the key nodes in the user head model, rendering the user head image and adding it to the user head model to obtain the user virtual face model; receiving the uploaded face model adjustment instruction, parsing the adjustment parameters corresponding to the face model adjustment instruction; and adjusting the user virtual face model accordingly according to the adjustment parameters to obtain the adjusted user virtual face model. The method realizes the rapid construction of the user virtual face model based on the user head size and the user head image, and can adjust the model in a customized or automatic manner, reducing the operational difficulty of constructing the virtual head model, and can generate the virtual head model more quickly.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image recognition technology, and in particular to a method, device, computer equipment and storage medium for constructing a virtual head model. Background Art

[0002] At present, with the development of computer technology and the advancement of multimedia technology, three-dimensional models are becoming more and more popular due to their strong sense of space and realism. In the field of virtual reality, such as virtual fitting and virtual beauty, the existing three-dimensional head model of virtual user characters does not completely restore the user's head model, that is, it is impossible to adjust the three-dimensional head model based on the user's real head parameters to obtain a more intuitive effect. If the user's head model needs to be restored to a high degree of three-dimensional modeling, it not only requires high professionalism of the modeler, but also leads to low efficiency due to the high difficulty of modeling. Summary of the invention

[0003] The embodiments of the present invention provide a method, apparatus, computer equipment and storage medium for constructing a virtual head model, aiming to solve the problem in the prior art of three-dimensional modeling and restoration of a user's head model, which not only requires high professionalism of the modeling personnel, but also leads to low efficiency due to the high difficulty of modeling.

[0004] In a first aspect, an embodiment of the present invention provides a method for constructing a virtual head model, which includes:

[0005] Receiving the user head size entered by the user terminal;

[0006] Constructing a three-dimensional model according to the user's head size to obtain a user's head model; wherein the user's head size includes head width, head length, head height, and head circumference;

[0007] Receiving the user head image uploaded by the user terminal;

[0008] According to a one-to-one mapping relationship between key pixels of the user head image and key nodes in the user head model, the user head image is rendered and added to the user head model to obtain a user virtual face model;

[0009] Receiving a facial model adjustment instruction uploaded by a user terminal, and parsing an adjustment parameter corresponding to the facial model adjustment instruction; wherein the facial model adjustment instruction is a custom manual adjustment instruction or a one-key automatic adjustment instruction;

[0010] According to the adjustment parameters, the user virtual facial model is adjusted accordingly to obtain an adjusted user virtual facial model; and

[0011] The adjusted user virtual face model is sent to the user terminal for display.

[0012] In a second aspect, an embodiment of the present invention provides a virtual head model construction device, which includes:

[0013] A size receiving unit, used to receive the user head size entered by the user terminal;

[0014] A head model initial construction unit, used to construct a three-dimensional model according to the user's head size to obtain the user's head model; wherein the user's head size includes head width, head length, head height, and head circumference;

[0015] A head image receiving unit, used to receive a user head image uploaded by a user terminal;

[0016] A virtual facial model construction unit, configured to render and add the user head image to the user head model according to a one-to-one mapping relationship between key pixels of the user head image and key nodes in the user head model, so as to obtain a user virtual facial model;

[0017] An adjustment instruction receiving unit, used for receiving a facial model adjustment instruction uploaded by a user terminal, and parsing an adjustment parameter corresponding to the facial model adjustment instruction; wherein the facial model adjustment instruction is a custom manual adjustment instruction or a one-key automatic adjustment instruction;

[0018] A facial model adjustment unit, configured to adjust the user virtual facial model accordingly according to the adjustment parameters to obtain an adjusted user virtual facial model; and

[0019] The current facial model sending unit is used to send the adjusted user virtual facial model to the user terminal for display.

[0020] In a third aspect, an embodiment of the present invention further provides a computer device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the virtual head model construction method described in the first aspect when executing the computer program.

[0021] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor executes the virtual head model construction method described in the first aspect above.

[0022] The embodiment of the present invention provides a method, device, computer equipment and storage medium for constructing a virtual head model. The method includes receiving the user head size entered by the user terminal; constructing a three-dimensional model according to the user head size to obtain the user head model; wherein the user head size includes head width, head length, head height and head circumference; receiving the user head image uploaded by the user terminal; according to the one-to-one mapping relationship between the key pixel points of the user head image and the key nodes in the user head model, rendering the user head image and adding it to the user head model to obtain the user virtual face model; receiving the face model adjustment instruction uploaded by the user terminal, parsing the adjustment parameters corresponding to the face model adjustment instruction; wherein the face model adjustment instruction is a custom manual adjustment instruction or a one-key automatic adjustment instruction; adjusting the user virtual face model accordingly according to the adjustment parameters to obtain the adjusted user virtual face model; and sending the adjusted user virtual face model to the user terminal for display. The method realizes the rapid construction of the user virtual face model based on the user head size and the user head image, and can adjust the model in a custom or automatic manner, which reduces the difficulty of constructing the virtual head model and can generate the virtual head model more quickly. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying any creative work.

[0024] Figure 1 A schematic diagram of an application scenario of the method for constructing a virtual head model provided by an embodiment of the present invention;

[0025] Figure 2 A schematic diagram of a flow chart of a method for constructing a virtual head model provided by an embodiment of the present invention;

[0026] Figure 3 A schematic diagram of a sub-process of a method for constructing a virtual head model provided by an embodiment of the present invention;

[0027] Figure 4 A schematic block diagram of a virtual head model construction device provided by an embodiment of the present invention;

[0028] Figure 5 A schematic block diagram of subunits of a virtual head model construction device provided by an embodiment of the present invention;

[0029] Figure 6 A schematic block diagram of a computer device provided in an embodiment of the present invention. DETAILED DESCRIPTION

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

[0031] It should be understood that when used in this specification and the appended claims, the terms "include" and "comprises" indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.

[0032] It should also be understood that the terms used in this specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the specification of the present invention and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.

[0033] It should be further understood that the term "and / or" used in the present description and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0034] See also Figure 1 and Figure 2 , Figure 1 A schematic diagram of an application scenario of the method for constructing a virtual head model provided by an embodiment of the present invention; Figure 2 A schematic flow chart of a method for constructing a virtual head model provided in an embodiment of the present invention. The method for constructing a virtual head model is applied in a server and is executed by application software installed in the server.

[0035] like Figure 2 As shown, the method includes steps S110 to S170.

[0036] S110. Receive the user head size entered by the user terminal; wherein the user head size includes head width, head length, head height, and head circumference.

[0037] In this embodiment, before the user needs to view his or her virtual avatar (i.e., render the user's real facial image onto the virtual head model), the user can first enter the user's head size (for example, the user's head size includes key parameters such as head width, head length, head height, and head circumference) on the user interaction interface of the server corresponding to the user end according to the user's head size measured by himself or herself. After completing the entry of the head width, head length, head height, and head circumference, the user end sends the above-mentioned user head size to the server.

[0038] S120: construct a three-dimensional model according to the user's head size to obtain a user's head model.

[0039] In this embodiment, after the user enters the above-mentioned user head size and uploads it to the server from the user end, the server can quickly adjust the size of the public head virtual model pre-stored in the server according to the above-mentioned user head size to achieve three-dimensional modeling, so as to quickly obtain the user head model.

[0040] In one embodiment, before step S120, the method further includes:

[0041] Determine whether there is a null value among the multiple size parameter values ​​included in the user head size;

[0042] If there is a null value among the multiple size parameter values ​​included in the user head size, sending prompt information for prompting the user terminal to supplement the corresponding null value;

[0043] If the supplementary value of the size parameter value corresponding to the corresponding empty value sent by the user terminal is not received within the preset time threshold, the corresponding empty value is filled with the average value of the size parameter value to obtain an updated user head size.

[0044] In this embodiment, after the user end uploads the user head size to the server, the server will perform a null value detection on the multiple size parameter values ​​included in the user head size uploaded by the user to determine whether there is a null value in the multiple size parameter values ​​included in the user head size. If there is no null value in the multiple size parameter values ​​included in the user head size, it means that the user head model can be directly constructed in the server according to the user head size and in combination with the pre-stored public head virtual model. If there is a null value in the multiple size parameter values ​​included in the user head size, it means that there is an unfilled size parameter value in the user head size uploaded by the user. At this time, it is necessary to prompt the user to complete the blank value in the user head size in time and re-upload the supplemented user head size. If the server feeds back the prompt information to the user end, the user does not complete the user head size within the preset time threshold and re-upload it to the server, then the server fills it according to the average value of the parameter item corresponding to the blank value stored in the user head size to obtain the updated user head size. In the above manner, it can be ensured that there is no blank value in the user head parameter.

[0045] S130: Receive the user head image uploaded by the user terminal.

[0046] In this embodiment, after the user completes editing and uploading the user head size on the user terminal, the current user head image can be obtained through the camera on the user terminal and uploaded to the server, or the user head image of the user himself can be selected and uploaded to the server. In this way, the user head image can be quickly obtained to serve as an image material for simulating the user head portrait with high restoration.

[0047] In one embodiment, after step S130, the method further includes:

[0048] The key pixel points in the user head image are obtained through a cascade linear regression model.

[0049] In this embodiment, after the server receives the user head image uploaded by the user, in order to render the user head image to the user head model to obtain the user virtual facial model, it is necessary to obtain key pixel points in the user head image, such as the eyes, nose tip, mouth corners, eyebrows, and contour points of various facial parts.

[0050] In one embodiment, obtaining key pixel points in the user head image by using a cascaded linear regression model includes:

[0051] The eye key point set, nose key point set, mouth key point set and eyebrow key point set in the user's head image are obtained through a cascade linear regression model, so that the core key pixel points are composed of the eye key point set, nose key point set, mouth key point set and eyebrow key point set.

[0052] In specific implementation, a cascade linear regression model can be used to locate key pixels in the user's head image. The facial feature point location problem can be regarded as learning a regression function F, which takes the image I as input and outputs θ as the location of the feature point (face shape):

[0053] θ=F(I)=f n (f n-1 (...f1(θ0,I),I),I);

[0054] θ i =f i (θ i-1 ,I),i=1,...,n;

[0055] The so-called cascade, that is, the current function f i The input depends on the previous function f i-1 The output θ i , and each f i The learning goal is to approximate the true position θ of the feature point, where θ0 is the initial shape.

[0056] After locating the key pixel points in the user's head image through the cascade linear regression model, the core key points among the above key pixel points can be screened again (for example, the four pixel points at the left end of the left eyelid, the right end of the left eyelid, the top of the left eyelid, and the bottom of the left eyelid can outline the shape of the user's left eye). At least the eye key point set, nose key point set, mouth key point set, and eyebrow key point set in the user's head image must be obtained through the cascade linear regression model, and the key point sets of the above parts constitute the core key pixel points.

[0057] S140. According to a one-to-one mapping relationship between key pixels of the user head image and key nodes in the user head model, the user head image is rendered and added to the user head model to obtain a user virtual facial model.

[0058] In this embodiment, since the key point sets of various facial organs (such as eye key point set, nose key point set, mouth key point set, eyebrow key point set) are set in advance for the user head model, the core key points obtained by screening the key pixel points in the user head image are mapped one by one with the key point sets of various facial organs in the user head model, and the user head image can be rendered to the user head model to obtain the user virtual facial model.

[0059] S150, receiving a facial model adjustment instruction uploaded by the user terminal, and parsing an adjustment parameter corresponding to the facial model adjustment instruction; wherein the facial model adjustment instruction is a custom manual adjustment instruction or a one-key automatic adjustment instruction.

[0060] In this embodiment, when the user selects to adjust the generated user virtual facial model on the user interaction interface for facial model adjustment provided by the server, two methods are generally used, namely, customized manual adjustment and one-key automatic adjustment. In the customized manual adjustment mode, the user can adjust the user virtual facial model in the edit box or key points of the user virtual facial model displayed on the user interaction interface.

[0061] S160: Adjust the user virtual facial model accordingly according to the adjustment parameters to obtain an adjusted user virtual facial model.

[0062] In this embodiment, when the server obtains the adjustment parameters corresponding to the facial model adjustment instruction and the type corresponding to the facial model adjustment instruction, the user virtual facial model can be quickly adjusted accordingly to update the user virtual facial model. Since the user only needs to manually input parameters to determine the adjustment parameters, or select an adjustment template to automatically determine the adjustment parameters, the adjustment process is simplified, and only the model adjustment is required more quickly and simply.

[0063] In one embodiment, if Figure 3 As shown, step S160 includes:

[0064] S161: If the adjustment mode corresponding to the facial model adjustment instruction is a custom manual adjustment instruction, obtain corresponding adjustment parameters to adjust the user virtual facial model accordingly to obtain an adjusted user virtual facial model;

[0065] S162. If the adjustment mode corresponding to the facial model adjustment instruction is a one-key automatic adjustment instruction, obtain the selected adjustment template, and make corresponding adjustments to the user virtual facial model according to the adjustment parameters corresponding to the adjustment template to obtain the adjusted user virtual facial model.

[0066] In this embodiment, for example, the width of the eyelid from left to right is input into the edit box on the user interaction interface for facial model adjustment as any value of 30-34 mm, or the key point on the right end of the eyelid is directly pulled to directly adjust the width of the eyelid from left to right to any value of 30-34 mm. In the one-click automatic adjustment mode, the adjustment template selected by the user (for example, template A formed by the size parameters of the facial organs of celebrity A) is obtained, and the user virtual facial model is adjusted accordingly according to the adjustment template to obtain the adjusted user virtual facial model. Through the above two methods, the model adjustment process is simplified and the professional requirements for users are reduced.

[0067] S170: Send the adjusted user virtual facial model to the user terminal for display.

[0068] In this embodiment, after the adjusted user virtual face model is generated in the server, it can be sent to the user terminal for the user to view in the display area of ​​the user interaction interface of the user terminal.

[0069] If the user needs to continue adjusting the currently generated adjusted user virtual facial model, the process returns to step S150. That is, after step S170, the process also includes: if a readjustment instruction is detected, the user virtual facial model is acquired, and the process returns to step S150. In this way, if the user is not satisfied with the current model adjustment result (that is, the adjustment result of the adjusted user virtual facial model does not achieve the effect expected by the user), the user can quickly return to readjust.

[0070] The method realizes the rapid construction of a user virtual face model based on the user's head size and the user's head image, and can adjust the model in a customized or automatic manner, thereby reducing the operational difficulty of constructing a virtual head model and generating a virtual head model more quickly.

[0071] The embodiment of the present invention further provides a virtual head model construction device, which is used to execute any embodiment of the aforementioned virtual head model construction method. Figure 4 , Figure 4 1 is a schematic block diagram of a virtual head model construction device provided by an embodiment of the present invention. The virtual head model construction device 100 may be configured in a server.

[0072] like Figure 4 As shown, the virtual head model construction device 100 includes a size receiving unit 110, a head model initial construction unit 120, a head image receiving unit 130, a virtual face model construction unit 140, an adjustment instruction receiving unit 150, a face model adjustment unit 160, and a current face model sending unit 170.

[0073] The size receiving unit 110 is used to receive the user head size entered by the user terminal; wherein the user head size includes head width, head length, head height, and head circumference.

[0074] In this embodiment, before the user needs to view his or her virtual avatar (i.e., render the user's real facial image onto the virtual head model), the user can first enter the user's head size (for example, the user's head size includes key parameters such as head width, head length, head height, and head circumference) on the user interaction interface of the server corresponding to the user end according to the user's head size measured by himself or herself. After completing the entry of the head width, head length, head height, and head circumference, the user end sends the above-mentioned user head size to the server.

[0075] The head model initial construction unit 120 is used to construct a three-dimensional model according to the user's head size to obtain a user's head model.

[0076] In this embodiment, after the user enters the above-mentioned user head size and uploads it to the server from the user end, the server can quickly adjust the size of the public head virtual model pre-stored in the server according to the above-mentioned user head size to achieve three-dimensional modeling, so as to quickly obtain the user head model.

[0077] In one embodiment, the virtual head model construction apparatus 100 further includes:

[0078] a null value judging unit, used for judging whether there is a null value in the multiple size parameter values ​​included in the user head size;

[0079] A null value prompting unit, configured to send prompt information for prompting the user terminal to supplement the corresponding null value if there is a null value among the multiple size parameter values ​​included in the user head size;

[0080] The null value filling unit is used to fill the corresponding null value with the average value of the size parameter value if the supplementary value of the size parameter value corresponding to the corresponding null value sent by the user terminal is not received within a preset time threshold to obtain an updated user head size.

[0081] In this embodiment, after the user end uploads the user head size to the server, the server will perform a null value detection on the multiple size parameter values ​​included in the user head size uploaded by the user to determine whether there is a null value in the multiple size parameter values ​​included in the user head size. If there is no null value in the multiple size parameter values ​​included in the user head size, it means that the user head model can be directly constructed in the server according to the user head size and in combination with the pre-stored public head virtual model. If there is a null value in the multiple size parameter values ​​included in the user head size, it means that there is an unfilled size parameter value in the user head size uploaded by the user. At this time, it is necessary to prompt the user to complete the blank value in the user head size in time and re-upload the supplemented user head size. If the server feeds back the prompt information to the user end, the user does not complete the user head size within the preset time threshold and re-upload it to the server, then the server fills it according to the average value of the parameter item corresponding to the blank value stored in the user head size to obtain the updated user head size. In the above manner, it can be ensured that there is no blank value in the user head parameter.

[0082] The head image receiving unit 130 is used to receive the user head image uploaded by the user terminal.

[0083] In this embodiment, after the user completes editing and uploading the user head size on the user terminal, the current user head image can be obtained through the camera on the user terminal and uploaded to the server, or the user head image of the user himself can be selected and uploaded to the server. In this way, the user head image can be quickly obtained to serve as an image material for simulating the user head portrait with high restoration.

[0084] In one embodiment, the virtual head model construction apparatus 100 further includes:

[0085] The key pixel point acquisition unit is used to acquire the key pixel points in the user head image through a cascade linear regression model.

[0086] In this embodiment, after the server receives the user head image uploaded by the user, in order to render the user head image to the user head model to obtain the user virtual facial model, it is necessary to obtain key pixel points in the user head image, such as the eyes, nose tip, mouth corners, eyebrows, and contour points of various facial parts.

[0087] In one embodiment, the key pixel point acquisition unit is further used for:

[0088] The eye key point set, nose key point set, mouth key point set and eyebrow key point set in the user's head image are obtained through a cascade linear regression model, so that the core key pixel points are composed of the eye key point set, nose key point set, mouth key point set and eyebrow key point set.

[0089] In specific implementation, a cascade linear regression model can be used to locate key pixels in the user's head image. The facial feature point location problem can be regarded as learning a regression function F, which takes the image I as input and outputs θ as the location of the feature point (face shape):

[0090] θ=F(I)=f n (f n-1 (...f1(θ0,I),I),I);

[0091] θ i =f i (θ i-1 ,I),i=1,...,n;

[0092] The so-called cascade, that is, the current function f i The input depends on the previous function f i-1 The output θ i , and each f i The learning goal is to approximate the true position θ of the feature point, where θ0 is the initial shape.

[0093] After locating the key pixel points in the user's head image through the cascade linear regression model, the core key points among the above key pixel points can be screened again (for example, the four pixel points at the left end of the left eyelid, the right end of the left eyelid, the top of the left eyelid, and the bottom of the left eyelid can outline the shape of the user's left eye). At least the eye key point set, nose key point set, mouth key point set, and eyebrow key point set in the user's head image must be obtained through the cascade linear regression model, and the key point sets of the above parts constitute the core key pixel points.

[0094] The virtual facial model building unit 140 is used to render the user head image and add it to the user head model according to the one-to-one mapping relationship between the key pixels of the user head image and the key nodes in the user head model to obtain a user virtual facial model.

[0095] In this embodiment, since the key point sets of various facial organs (such as eye key point set, nose key point set, mouth key point set, eyebrow key point set) are set in advance for the user head model, the core key points obtained by screening the key pixel points in the user head image are mapped one by one with the key point sets of various facial organs in the user head model, and the user head image can be rendered to the user head model to obtain the user virtual facial model.

[0096] The adjustment instruction receiving unit 150 is used to receive the facial model adjustment instruction uploaded by the user terminal and parse the adjustment parameters corresponding to the facial model adjustment instruction; wherein the facial model adjustment instruction is a custom manual adjustment instruction or a one-click automatic adjustment instruction.

[0097] In this embodiment, when the user selects to adjust the generated user virtual facial model on the user interaction interface for facial model adjustment provided by the server, two methods are generally used, namely, customized manual adjustment and one-key automatic adjustment. In the customized manual adjustment mode, the user can adjust the user virtual facial model in the edit box or key points of the user virtual facial model displayed on the user interaction interface.

[0098] The facial model adjustment unit 160 is used to adjust the user virtual facial model accordingly according to the adjustment parameters to obtain an adjusted user virtual facial model.

[0099] In this embodiment, when the server obtains the adjustment parameters corresponding to the facial model adjustment instruction and the type corresponding to the facial model adjustment instruction, the user virtual facial model can be quickly adjusted accordingly to update the user virtual facial model. Since the user only needs to manually input parameters to determine the adjustment parameters, or select an adjustment template to automatically determine the adjustment parameters, the adjustment process is simplified, and only the model adjustment is required more quickly and simply.

[0100] In one embodiment, if Figure 5 As shown, the facial model adjustment unit 160 includes:

[0101] A custom adjustment unit 161 is used to obtain corresponding adjustment parameters to adjust the user virtual facial model accordingly to obtain an adjusted user virtual facial model if the adjustment mode corresponding to the facial model adjustment instruction is a custom manual adjustment instruction;

[0102] The automatic adjustment unit 162 is used to obtain the selected adjustment template if the adjustment mode corresponding to the facial model adjustment instruction is a one-key automatic adjustment instruction, and to make corresponding adjustments to the user virtual facial model according to the adjustment parameters corresponding to the adjustment template to obtain the adjusted user virtual facial model.

[0103] In this embodiment, for example, the width of the eyelid from left to right is input into the edit box on the user interaction interface for facial model adjustment as any value of 30-34 mm, or the key point on the right end of the eyelid is directly pulled to directly adjust the width of the eyelid from left to right to any value of 30-34 mm. In the one-click automatic adjustment mode, the adjustment template selected by the user (for example, template A formed by the size parameters of the facial organs of celebrity A) is obtained, and the user virtual facial model is adjusted accordingly according to the adjustment template to obtain the adjusted user virtual facial model. Through the above two methods, the model adjustment process is simplified and the professional requirements for users are reduced.

[0104] The current facial model sending unit 170 is used to send the adjusted user virtual facial model to the user terminal for display.

[0105] In this embodiment, after the adjusted user virtual face model is generated in the server, it can be sent to the user terminal for the user to view in the display area of ​​the user interaction interface of the user terminal.

[0106] If the user needs to continue adjusting the currently generated adjusted user virtual face model, the process returns to the step of receiving the face model adjustment instruction uploaded by the user terminal and parsing the adjustment parameters corresponding to the face model adjustment instruction. That is, the virtual head model construction device 100 also includes:

[0107] The readjustment instruction detection unit is used to obtain the user virtual facial model if a readjustment instruction is detected, return to execute the facial model adjustment instruction uploaded by the receiving user end, and parse the adjustment parameters corresponding to the facial model adjustment instruction.

[0108] In this way, when the user is not satisfied with the current model adjustment result (ie, the adjustment result of the user's virtual facial model after adjustment does not achieve the effect expected by the user), the user can quickly return to readjust.

[0109] The device can quickly build a user virtual face model based on the user's head size and the user's head image, and can adjust the model in a customized or automatic manner, which reduces the operational difficulty of building a virtual head model and can generate a virtual head model more quickly.

[0110] The virtual head model construction device can be implemented in the form of a computer program. Figure 6 Runs on the computer device shown.

[0111] See also Figure 6 , Figure 65 is a schematic block diagram of a computer device provided by an embodiment of the present invention. The computer device 500 is a server, which may be an independent server or a server cluster composed of multiple servers.

[0112] See also Figure 6 The computer device 500 includes a processor 502 , a memory and a network interface 505 connected via a system bus 501 , wherein the memory may include a non-volatile storage medium 503 and an internal memory 504 .

[0113] The non-volatile storage medium 503 may store an operating system 5031 and a computer program 5032. When the computer program 5032 is executed, the processor 502 may execute a virtual head model construction method.

[0114] The processor 502 is used to provide computing and control capabilities to support the operation of the entire computer device 500 .

[0115] The internal memory 504 provides an environment for the operation of the computer program 5032 in the non-volatile storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can execute the virtual head model construction method.

[0116] The network interface 505 is used for network communication, such as providing data information transmission, etc. Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present invention, and does not constitute a limitation on the computer device 500 to which the solution of the present invention is applied. The specific computer device 500 may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0117] The processor 502 is used to run a computer program 5032 stored in the memory to implement the virtual head model construction method disclosed in the embodiment of the present invention.

[0118] Those skilled in the art will understand that Figure 6 The embodiments of the computer device shown in the figure do not constitute a limitation on the specific composition of the computer device. In other embodiments, the computer device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently. For example, in some embodiments, the computer device may only include a memory and a processor. In such embodiments, the structure and function of the memory and the processor are the same as those of the embodiment of the present invention. Figure 6 The embodiments shown are consistent and will not be described again here.

[0119] It should be understood that in the embodiment of the present invention, the processor 502 may be a central processing unit (CPU), and the processor 502 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.

[0120] In another embodiment of the present invention, a computer-readable storage medium is provided. The computer-readable storage medium may be a non-volatile computer-readable storage medium. The computer-readable storage medium stores a computer program, wherein when the computer program is executed by a processor, the virtual head model construction method disclosed in the embodiment of the present invention is implemented.

[0121] Those skilled in the art can clearly understand that, for the convenience and simplicity of description, the specific working process of the above-described equipment, devices and units can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here. Those of ordinary skill in the art can appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented with electronic hardware, computer software or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to the function. Whether these functions are executed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present invention.

[0122] In the several embodiments provided by the present invention, it should be understood that the disclosed equipment, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. Units with the same function may also be combined into one unit. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interfaces, devices or units, or may be an electrical, mechanical or other form of connection.

[0123] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiments of the present invention.

[0124] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0125] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), disk or optical disk and other media that can store program codes.

[0126] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.

Claims

1. A method for constructing a virtual head model, characterized in that: include: Receiving the user's head size entered by the user terminal; wherein the user's head size includes head width, head length, head height, and head circumference; Constructing a three-dimensional model according to the size of the user's head to obtain a user's head model; Receiving a user head image uploaded by a user terminal, wherein the user head image includes a current user head portrait acquired by a camera or a user head image of the user himself / herself at the user terminal; According to a one-to-one mapping relationship between key pixels of the user head image and key nodes in the user head model, the user head image is rendered and added to the user head model to obtain a user virtual face model; Receiving a facial model adjustment instruction uploaded by a user terminal, and parsing an adjustment parameter corresponding to the facial model adjustment instruction; wherein the facial model adjustment instruction is a custom manual adjustment instruction or a one-key automatic adjustment instruction; According to the adjustment parameters, the user virtual facial model is adjusted accordingly to obtain an adjusted user virtual facial model; and Sending the adjusted user virtual face model to the user terminal for display; After receiving the user head image uploaded by the user terminal, the method further includes: Acquire key pixel points in the user head image through a cascade linear regression model; The key pixel points include eyes, nose tip, mouth corners, eyebrows and contour points of face parts; Before constructing the three-dimensional model according to the user's head size to obtain the user's head model, the method further includes: Determine whether there is a null value among the multiple size parameter values ​​included in the user head size; If there is a null value among the multiple size parameter values ​​included in the user head size, sending prompt information for prompting the user terminal to supplement the corresponding null value; If the supplementary value of the size parameter value corresponding to the corresponding empty value sent by the user terminal is not received within the preset time threshold, the corresponding empty value is filled with the average value of the size parameter value to obtain an updated user head size.

2. The method for constructing a virtual head model according to claim 1, characterized in that: The step of obtaining key pixel points in the user head image by using a cascaded linear regression model includes: The eye key point set, nose key point set, mouth key point set and eyebrow key point set in the user's head image are obtained through a cascade linear regression model, so that the core key pixel points are composed of the eye key point set, nose key point set, mouth key point set and eyebrow key point set.

3. The method for constructing a virtual head model according to claim 1, characterized in that: The step of adjusting the user virtual facial model accordingly according to the adjustment parameters to obtain an adjusted user virtual facial model comprises: If the adjustment mode corresponding to the facial model adjustment instruction is a custom manual adjustment instruction, obtaining corresponding adjustment parameters to adjust the user virtual facial model accordingly to obtain an adjusted user virtual facial model; If the adjustment mode corresponding to the facial model adjustment instruction is a one-button automatic adjustment instruction, the selected adjustment template is obtained, and the user virtual facial model is adjusted accordingly according to the adjustment parameters corresponding to the adjustment template to obtain the adjusted user virtual facial model.

4. A virtual head model construction device, characterized in that: include: A size receiving unit, used to receive the user head size entered by the user terminal; wherein the user head size includes head width, head length, head height, and head circumference; A head model initial construction unit, used to construct a three-dimensional model according to the user's head size to obtain a user's head model; A head image receiving unit, used to receive a user head image uploaded by a user terminal, wherein the user head image includes a head portrait of the current user acquired by a camera or a user head image of the user himself at the user terminal; a virtual facial model construction unit, configured to render and add the user head image to the user head model according to a one-to-one mapping relationship between key pixels of the user head image and key nodes in the user head model, so as to obtain a user virtual facial model; An adjustment instruction receiving unit, used for receiving a facial model adjustment instruction uploaded by a user terminal, and parsing an adjustment parameter corresponding to the facial model adjustment instruction; wherein the facial model adjustment instruction is a custom manual adjustment instruction or a one-key automatic adjustment instruction; A facial model adjustment unit, configured to adjust the user virtual facial model accordingly according to the adjustment parameters to obtain an adjusted user virtual facial model; and A current face model sending unit, used for sending the adjusted user virtual face model to a user terminal for display; The virtual head model construction device also includes: A key pixel point acquisition unit, used for acquiring key pixel points in the user head image through a cascade linear regression model; The key pixel points include eyes, nose tip, mouth corners, eyebrows and contour points of face parts; The virtual head model construction device also includes: a null value detection unit, used to determine whether there is a null value in the multiple size parameter values ​​included in the user head size; A null value prompting unit, configured to send prompt information for prompting the user terminal to supplement the corresponding null value if there is a null value among the multiple size parameter values ​​included in the user head size; The null value automatic filling unit is used to fill the corresponding null value with the average value of the size parameter value if the supplementary value of the size parameter value corresponding to the corresponding null value sent by the user terminal is not received within a preset time threshold to obtain an updated user head size.

5. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the virtual head model construction method according to any one of claims 1 to 3 is implemented.

6. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, which, when executed by a processor, causes the processor to perform the virtual head model construction method according to any one of claims 1 to 3.

Citation Information

Patent Citations

  • Virtual three-dimensional human body modeling method and modeling system

    CN106250573A

  • Multi-modal interactive processing method and system based on virtual human

    CN107679519A

  • Facial animation mapping system and method

    CN108062783A

  • Face virtual facelift method and apparatus

    CN108447017A

  • Action expression editing method of a virtual character, device, apparatus, system and medium

    CN109272566A