CN112090082A - Facial skeleton processing method and device, electronic equipment and storage medium - Google Patents
Facial skeleton processing method and device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN112090082A CN112090082A CN202011036179.8A CN202011036179A CN112090082A CN 112090082 A CN112090082 A CN 112090082A CN 202011036179 A CN202011036179 A CN 202011036179A CN 112090082 A CN112090082 A CN 112090082A
- Authority
- CN
- China
- Prior art keywords
- adjusting
- facial
- skeleton
- facial skeleton
- determining
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 230000001815 facial effect Effects 0.000 title claims abstract description 168
- 238000003672 processing method Methods 0.000 title abstract description 13
- 210000003054 facial bone Anatomy 0.000 claims abstract description 41
- 238000000034 method Methods 0.000 claims abstract description 34
- 238000004891 communication Methods 0.000 claims description 19
- 238000004590 computer program Methods 0.000 claims description 9
- 210000000988 bone and bone Anatomy 0.000 abstract description 84
- 230000001360 synchronised effect Effects 0.000 abstract description 4
- 210000001508 eye Anatomy 0.000 description 41
- 210000003128 head Anatomy 0.000 description 14
- 238000010586 diagram Methods 0.000 description 12
- 210000004279 orbit Anatomy 0.000 description 11
- 210000001331 nose Anatomy 0.000 description 9
- 210000000744 eyelid Anatomy 0.000 description 6
- 230000004048 modification Effects 0.000 description 6
- 238000012986 modification Methods 0.000 description 6
- 210000000624 ear auricle Anatomy 0.000 description 5
- 230000000694 effects Effects 0.000 description 5
- 239000011324 bead Substances 0.000 description 2
- 238000004364 calculation method Methods 0.000 description 2
- 210000004087 cornea Anatomy 0.000 description 2
- 238000006073 displacement reaction Methods 0.000 description 2
- 230000004418 eye rotation Effects 0.000 description 2
- 210000004709 eyebrow Anatomy 0.000 description 2
- 210000001061 forehead Anatomy 0.000 description 2
- 210000000216 zygoma Anatomy 0.000 description 2
- 230000002159 abnormal effect Effects 0.000 description 1
- 210000005252 bulbus oculi Anatomy 0.000 description 1
- 230000002301 combined effect Effects 0.000 description 1
- 230000001276 controlling effect Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 210000003205 muscle Anatomy 0.000 description 1
- 210000000537 nasal bone Anatomy 0.000 description 1
- 230000000149 penetrating effect Effects 0.000 description 1
- 230000002093 peripheral effect Effects 0.000 description 1
- 230000001105 regulatory effect Effects 0.000 description 1
- 210000003625 skull Anatomy 0.000 description 1
Images
Classifications
-
- A—HUMAN NECESSITIES
- A63—SPORTS; GAMES; AMUSEMENTS
- A63F—CARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
- A63F13/00—Video games, i.e. games using an electronically generated display having two or more dimensions
- A63F13/60—Generating or modifying game content before or while executing the game program, e.g. authoring tools specially adapted for game development or game-integrated level editor
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Processing Or Creating Images (AREA)
Abstract
The application relates to a facial bone processing method, a facial bone processing device, an electronic device and a storage medium, wherein the method comprises the following steps: acquiring a first adjusting operation of a first adjusting control corresponding to the current facial skeleton; determining an adjusted facial skeleton corresponding to the current facial skeleton; determining a second adjusting operation of a second adjusting control corresponding to the facial skeleton according to the first adjusting operation; determining an adjusting parameter corresponding to the adjusting facial skeleton according to the second adjusting operation; and adjusting the adjusted facial skeleton according to the adjusting parameters. The technical scheme realizes synchronous adjustment of the facial skeleton and the related facial skeleton thereof, and quickly and accurately adjusts the facial effect of the animation model according to the user requirement. Meanwhile, the user does not need to manually adjust each bone one by one, and other related face pinching bones can be synchronously adjusted only by adjusting one face pinching bone, so that the complexity of face pinching operation is reduced.
Description
Technical Field
The present application relates to the field of computer technologies, and in particular, to a facial bone processing method and apparatus, an electronic device, and a storage medium.
Background
In the relevant game scene, there are two main ways of pinching face: modifying model vertices and modifying model bones. The manner of modifying the model vertices requires fine control over each vertex of the face model, which makes the modification amount huge and the modification process complicated. In the mode of modifying the model skeleton, the number of modified skeletons is controllable, but in order to ensure the expression capability of the game character, the mode of modifying the model skeleton still has more modification items, and the total number of 45 facial skeletons is more than 100 facial parameter modification items. When pinching face, the number of required adjustment and modification items is large, the operation is complex, the adjustment effect on the face model is poor, and more computing resources and network bandwidth are occupied.
Disclosure of Invention
In order to solve the technical problem or at least partially solve the technical problem, embodiments of the present application provide a facial skeleton processing method, apparatus, electronic device and storage medium.
According to an aspect of an embodiment of the present application, there is provided a facial bone processing method including:
acquiring a first adjusting operation of a first adjusting control corresponding to the current facial skeleton;
determining an adjusted facial skeleton corresponding to the current facial skeleton;
determining a second adjusting operation of a second adjusting control corresponding to the facial skeleton according to the first adjusting operation;
determining an adjusting parameter corresponding to the adjusting facial skeleton according to the second adjusting operation;
and adjusting the adjusted facial skeleton according to the adjusting parameters.
Optionally, the determining an adjusted facial bone corresponding to the current facial bone includes:
acquiring a control state of the associated adjusting control;
when the control state is an on state, determining that the adjusted facial skeleton comprises the current facial skeleton and an associated facial skeleton of the current facial skeleton;
when the control state is an off state, determining that the adjusted facial bone is the current facial bone.
Optionally, when the control state is the open state, the control state further includes an association range level;
the determining an adjusted facial bone corresponding to the current facial bone further comprises:
determining an associated facial skeleton of the current facial skeleton according to the association range level.
Optionally, when the control state is an open state, the determining, according to the first adjusting operation, a second adjusting operation on a second adjusting control corresponding to the adjusted facial skeleton includes:
determining a first adjusting gear corresponding to the first adjusting operation;
acquiring a first weight corresponding to the current facial skeleton, and acquiring a second weight corresponding to the related facial skeleton;
calculating a second adjusting gear corresponding to the second adjusting control according to the first adjusting gear, the first weight and the second weight;
and determining a second adjusting operation corresponding to the related facial skeleton according to the second adjusting gear.
Optionally, the determining a second adjustment parameter corresponding to the associated facial skeleton according to the second adjustment operation includes:
acquiring a middle gear and a parameter adjusting range corresponding to the associated facial skeleton, wherein the current facial skeleton is the same as the middle gear of the associated facial skeleton;
and determining a second adjusting parameter corresponding to the second adjusting gear according to the intermediate gear and the parameter adjusting range.
Optionally, the method further includes:
acquiring a first parameter adjusting range of the current facial skeleton, a second parameter adjusting range of the related facial skeleton and the gear number of the first adjusting assembly and the second adjusting assembly;
determining a first original gear corresponding to the current facial skeleton original skeleton data according to the first parameter adjusting range and the gear number, and determining a second original gear corresponding to the associated facial skeleton original skeleton data according to the second parameter adjusting range and the gear number;
and calculating the intermediate gear according to the first original gear, the second original gear, the first weight and the second weight.
Optionally, the method further includes:
obtaining a first skinning weight corresponding to a head skeleton and a second skinning weight corresponding to a face skeleton, wherein the first skinning weight is greater than or equal to a preset value;
and binding the facial skeleton with a facial model according to the first skinning weight and the second skinning weight.
According to another aspect of an embodiment of the present application, there is provided a facial bone treatment device including:
the acquisition module is used for acquiring a first adjustment operation of a first adjustment control corresponding to the current facial skeleton;
a skeleton determination module for determining an adjusted facial skeleton corresponding to the current facial skeleton;
the operation determining module is used for determining a second adjusting operation of a second adjusting control corresponding to the adjusting facial skeleton according to the first adjusting operation;
a parameter determining module, configured to determine, according to the second adjustment operation, an adjustment parameter corresponding to the adjusted facial skeleton;
and the adjusting module is used for adjusting the facial skeleton according to the adjusting parameters.
According to another aspect of the embodiments of the present application, there is also provided a storage medium including a stored program that executes the above steps when the program is executed.
According to another aspect of an embodiment of the present application, there is provided an electronic device including: the system comprises a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory complete mutual communication through the communication bus;
the memory is used for storing a computer program;
the processor is configured to implement the above method steps when executing the computer program.
According to another aspect of embodiments of the present application, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the above-mentioned method steps.
Compared with the prior art, the technical scheme provided by the embodiment of the application has the following advantages:
when a user adjusts the adjusting control of one facial skeleton, the adjusting control corresponding to the adjusting facial skeleton corresponding to the facial skeleton is controlled to perform corresponding adjusting operation, so that synchronous adjustment of the facial skeleton and the related facial skeleton is realized, and the facial effect of the animation model is quickly and accurately adjusted according to the user requirement. Meanwhile, the user does not need to manually adjust each bone one by one, and other related face pinching bones can be synchronously adjusted only by adjusting one face pinching bone, so that the complexity of face pinching operation is reduced.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
In order to more clearly illustrate the embodiments or technical solutions in the prior art of the present invention, the drawings used in the description of the embodiments or prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained based on these drawings without creative efforts.
FIG. 1 is a schematic diagram of a facial skeleton hierarchy provided in an embodiment of the present application;
FIG. 2a is a schematic diagram of an embodiment of the present application before eye rotation;
FIG. 2b is a schematic view of an eye after rotation according to an embodiment of the present application;
fig. 3 is a flowchart of a facial skeleton processing method according to an embodiment of the present application;
fig. 4 is a schematic view of an adjustment control of a facial skeleton according to an embodiment of the present application;
FIG. 5a is a schematic diagram illustrating an associated adjustment control provided by an embodiment of the present application when closed;
fig. 5b is a schematic diagram of an association adjustment control provided in the embodiment of the present application when being turned on;
FIG. 5c is a schematic diagram of an associated adjustment control provided in accordance with another embodiment of the present application;
fig. 6 is a flowchart of a facial skeleton processing method according to another embodiment of the present application;
fig. 7 is a flowchart of a facial skeleton processing method according to another embodiment of the present application;
FIG. 8 is a block diagram of an animated skeleton processing device according to an embodiment of the present disclosure;
fig. 9 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In the embodiment of the application, the pinching face bones belong to the head bone subset. Fig. 1 is a schematic view of a facial skeleton hierarchy provided in an embodiment of the present application. As shown in fig. 1, the subset bone of the Head bone Head includes a Head adjustment bone Head _ Adjust, each pinching face bone A, B, C … … N as a sub-bone of the Head adjustment bone Head _ Adjust.
The facial related bones are specifically as follows:
(1) eye part
Right left eye orbital integrity: eye _ Socket _ R, Eye _ Socket _ L;
right left eye external canthus: eye _ Corner _ R _02, Eye _ Corner _ L _ 02;
right left eye upper eyelid: eyelid _ R _01 and Eyelid _ L _ 01;
right left eye inner canthus: eye _ Corner _ R _01, Eye _ Corner _ L _ 01;
right left eye lower eyelid: the Eyelid _ R _02 and the Eyelid _ L _ 02;
right left eye ball: eye _ R, Eye _ L;
right and left eyebrows: brow _ R, Brow _ L;
right left brow: brow _ R _01, Brow _ L _ 01;
right left eyebrow: brow _ R _02, Brow _ L _ 02;
right left brow: brow _ R _03, Brow _ L _ 03.
The bones of the eye region all use bone bones, the left and the right sides of the bones need to be aligned in parallel, all the bones are parallel to the head, the bone coordinates inherit the root bone coordinates, and the bones do not have scaling values.
(2) Nose part
Mountain root: nose _ root;
bridge of the nose: nose _ bridge;
nose head: nose _ tip;
a nasal wing: nose _ wing.
The bones of the nose area all use bone bones, all parallel subsets of which are in the head, the bone coordinates inherit the root bone coordinates, and the bones do not have scaling values.
(3) Mouth part
Upper lip: mouth _ Lip _ 01; lower lip: mouth _ Lip _ 02;
and (3) putting on a lip bead: mouth _ Lip _01_ bump; lower lip bead: mouth _ Lip _02_ bump;
left and right mouth angles: mouth _ Corner _ L, Mouth _ Corner _ R;
the mouth is zoomed as a whole: and Mouth.
The bones of the mouth area are all bone bones, the bones of the left and right mouth corners are aligned in parallel, and all bones are parallel and are subset to the head. The bone coordinates inherit the root bone coordinates, the bone having no scaling value.
(4) Cheek
Cheek: face; cheekbones: cheekbone; apple muscle: cheek _ RCheek _ L;
lower jaw: a readable; the chin: jaw _ compressible; the lower base: jaw;
forehead: forehead;
ear: pinna _ R/Pinna _ L; ear lobe: EarLobe _ R/EarLobe _ L.
The bones in the cheek regions all use bone bones, all parallel subsets are in the head, the bone coordinates inherit the root bone coordinates, the bones have no scaling values.
FIG. 2a is a schematic diagram of an embodiment of the present application before eye rotation; fig. 2b is a schematic diagram of the eye after rotation according to the embodiment of the present application. There is a certain relationship between the pinching face bones, for example, as shown in fig. 2a and fig. 2b, when the eyes are to be rotated, in addition to the right Eye Socket bone Eye _ Socket _ R rotation, the combined effect of the displacement and rotation of the right inner and outer Eye Corner bones Eye _ Corner _ R _02 and Eye _ Corner _ R _01 is also adjusted; meanwhile, the left Eye orbital bone Eye _ Socket _ L, the left inner and outer Eye angular bones Eye _ cornea _ L _02 and Eye _ cornea _ L _01 are also adjusted correspondingly to ensure the symmetrical adjustment of the left Eye and the right Eye.
In this embodiment, can adjust facial face bone of holding between the fingers through adjusting the controlling part, like slide bar, knob etc. other face bones of holding between the fingers of face bone relevance are controlled simultaneously and are carried out corresponding regulation to the realization is adjusted animation model's facial effect according to user's needs fast accurately, and simultaneously, the user need not manually to adjust each skeleton one by one, only through adjusting one hold between the fingers face skeleton just can synchronous adjustment other face bones of holding between the fingers of relevance, reduces and holds between the fingers face operation complexity.
First, a facial skeleton processing method according to an embodiment of the present invention will be described.
Fig. 3 is a flowchart of a facial skeleton processing method according to an embodiment of the present application. As shown in fig. 3, the method comprises the steps of:
step S11, acquiring a first adjusting operation of a first adjusting control corresponding to the current facial skeleton;
step S12, determining an adjusted facial skeleton corresponding to the current facial skeleton;
step S13, according to the first adjusting operation, determining a second adjusting operation on a second adjusting control corresponding to the adjusting face skeleton;
step S14, determining adjusting parameters corresponding to the facial skeleton according to the second adjusting operation;
and step S15, adjusting the facial skeleton according to the adjusting parameters.
Fig. 4 is a schematic view of an adjustment control of a facial skeleton according to an embodiment of the present application. As shown in fig. 4, when a user wants to rotate the eyes, the slider on the "right eye socket" slide bar is manually moved, and meanwhile, the sliders on the "right inner canthus", "right outer canthus", "left eye socket", "left inner canthus" and "left outer canthus" slide bars automatically and correspondingly, so that the eyes are rotated, and a normal facial effect is obtained.
In this embodiment, when the user adjusts the adjustment control of one of the facial bones, the adjustment control corresponding to the adjustment facial bone corresponding to the facial bone is controlled to perform a corresponding adjustment operation, so that the facial bones and the related facial bones thereof are synchronously adjusted, and the facial effect of the animation model is quickly and accurately adjusted according to the user's needs. Meanwhile, the user does not need to manually adjust each bone one by one, and other related face pinching bones can be synchronously adjusted only by adjusting one face pinching bone, so that the complexity of face pinching operation is reduced.
In step S12 of the above embodiment, the adjustment facial bone range corresponding to the current facial bone may be determined according to the on or off of the associated adjustment control. The step S12 includes: acquiring a control state of the associated adjusting control; when the control state is an opening state, determining that the adjusted facial skeleton comprises a current facial skeleton and an associated facial skeleton of the current facial skeleton; and when the control state is the closing state, determining to adjust the facial skeleton to be the current facial skeleton.
Fig. 5a and 5b are schematic diagrams of the associated adjustment control provided in the embodiment of the present application when the associated adjustment control is turned off and turned on, respectively. The associated adjustment control may be a knob switch. As shown in fig. 5a, when the knob 51 is upright, the associated adjustment control is in an off state, where the adjustment facial bone is only the current facial bone itself. As shown in fig. 5b, when the knob 51 is horizontal, the associated adjustment control is in an on state, and the adjustment facial skeleton process includes the current facial skeleton itself and its associated facial skeleton.
For example, for the bones corresponding to the eyes, when the associated condition control is closed, as shown in fig. 4, when the user moves the slider of "right eye socket", the sliders of the other bones "right inner corner of the eye", "right outer corner of the eye", "left eye socket", "left inner corner of the eye", and "left outer corner of the eye" do not slide in association. Only when the associated condition control is on will the associated bone of the "right eye socket" adjust synchronously.
Optionally, when the control state is the open state, the control state further includes an association range level; the step S12 further includes: and determining the related facial skeleton of the current facial skeleton according to the related range level.
Fig. 5c is a schematic diagram of an associated adjustment control according to another embodiment of the present application. As shown in fig. 5c, in addition to being turned on and off, the associated adjustment control is provided with a shift position 52, which shift position 52 is used to control the selection of the associated facial skeleton. For example, for the bones corresponding to the eyes, when the knob 51 is rotated to the shift position 52, the user moves the slider of the "right eye socket", only the sliders of the "right inner corner of the eye" and the "right outer corner of the eye" follow the sliding movement, and the sliders of the "left eye socket", the "left inner corner of the eye" and the "left outer corner of the eye" do not slide in association.
Optionally, a plurality of gears may be further set on the associated adjustment control, and associated facial skeleton ranges corresponding to different gears are different. For example, for the bones of the eye, the associated facial bones corresponding to the gear 1 are all bones of the eye; the related facial bones corresponding to the gear 2 comprise nasal bones besides all bones of the eyes; the associated facial bones corresponding to gear 2 include the mouth bones in addition to all the bones of the eye and the nose bones.
In the above embodiment, each gear of the association adjustment control is associated with a tree-shaped facial skeleton data selection range. When the associated adjusting control is started, reading all sub-skeletons of the current facial skeleton; when the associated adjustment control is closed, only the current facial skeleton is read; when the associated regulating control is in a certain gear, reading the sub-skeleton corresponding to the range of the gear. In the process of adjusting the facial skeleton, the father skeleton of the current facial skeleton is generally not affected, but according to the requirement, the father skeleton can be controlled to carry out corresponding following adjustment when the specific facial skeleton is adjusted.
Since there are multiple associated bones involved in the adjustment, the position of the adjustment control for each bone at the time of the associated adjustment is difficult to determine. Fig. 6 is a flowchart of a facial skeleton processing method according to another embodiment of the present application. As shown in fig. 6, in an alternative embodiment, when the control state is the on state, the step S13 includes the following steps:
step S21, determining a first adjusting gear corresponding to the first adjusting operation;
step S22, acquiring a first weight corresponding to the current facial skeleton, and associating a second weight corresponding to the facial skeleton;
step S23, calculating a second adjusting gear corresponding to the second adjusting control according to the first adjusting gear, the first weight and the second weight;
and step S24, determining a second adjusting operation corresponding to the related facial skeleton according to the second adjusting gear.
For the mutually related bones, each bone has a corresponding weight, and the weight represents the corresponding adjustment relation of each bone in the adjustment process. For example, each skeleton is divided into 31 gears of-15 to 15 according to original skeleton data, the weight of the current facial skeleton A is 0.6, and the weight of the associated facial skeleton B is 1.2, and then each time the current facial skeleton A is adjusted by 0.6 gear, the associated facial skeleton B is adjusted by 1.2 gear. If the current facial bone a is adjusted by 3 steps from the initial position, the associated facial bone B is adjusted by 3 × 1.2 ÷ 0.6 ═ 6 steps.
Optionally, the weight may also be an adjustment relationship between actual skeleton data, including a relationship between adjustment parameters such as a rotation angle and a displacement distance, that is, the adjustment parameter is directly calculated according to the skeleton data of the current facial skeleton, and the adjustment parameter corresponding to the associated facial skeleton is calculated according to the weight of each skeleton.
In an alternative embodiment, when adjusting multiple associated bones, each bone needs a uniform initial state, i.e. multiple bones are adjusted from the same initial state. The step S24 includes: acquiring a middle gear and a parameter adjusting range corresponding to the related facial skeleton, wherein the current facial skeleton is the same as the middle gear of the related facial skeleton; and determining a second adjusting parameter corresponding to the second adjusting gear according to the intermediate gear and the parameter adjusting range.
When a plurality of associated bones are adjusted, the initial state of each bone, namely the intermediate state of each bone, needs to be synchronized, so that each associated bone can be uniformly adjusted subsequently. Fig. 7 is a flowchart of a facial skeleton processing method according to another embodiment of the present application. As shown in fig. 7, the method further includes the step of determining the intermediate gear, which is as follows:
step S31, acquiring a first parameter adjusting range of the current facial skeleton, a second parameter adjusting range of the associated facial skeleton and the gear number of the first adjusting assembly and the second adjusting assembly;
step S32, determining a first original gear corresponding to the original skeleton data of the current facial skeleton according to the first parameter adjusting range and the gear number, and determining a second original gear corresponding to the original skeleton data of the associated facial skeleton according to the second parameter adjusting range and the gear number;
in step S33, an intermediate gear is calculated according to the first original gear, the second original gear, the first weight and the second weight.
The process of determining the intermediate gear will be described in detail below by way of a specific example.
Each facial skeleton is divided into 30 gears of-15 to 15 according to original skeleton data.
The associated three pinching face bones A, B, C, whose original gears are calculated as-10, 7, 1, respectively, from their original bone data.
If the weights corresponding to the pinching face bones A, B, C are the same, the intermediate gear is
If the weights corresponding to the pinching face skeleton A, B, C are 0.6, 1.2, and 0.8, respectively, the intermediate gear is set as
In this way, the pinching face skeleton A, B, C is adjusted with the same intermediate gear as a starting point, and although the initial state is different from the original face effect, the error is relatively small, so that the subsequent multi-skeleton correlation adjustment is facilitated.
In this embodiment, the difference between the maximum value and the minimum value of the bone data of each bone and the original bone data can be set according to requirements, if an exaggerated effect is required, the difference between the maximum value and the minimum value and the original bone data can be adjusted to be larger, and if a more natural effect is desired, the difference between the maximum value and the minimum value and the original bone data can be adjusted to be smaller. In order to obtain a more exaggerated effect, the adjustment threshold value can be wholly enlarged to accept a slight upper penetrating phenomenon.
In another alternative embodiment, in skinning, the method further comprises, in view of the facial bone requirement to be affected by the cranial bone: obtaining a first skinning weight corresponding to a head skeleton and a second skinning weight corresponding to a face skeleton, wherein the first skinning weight is greater than or equal to a preset value; and binding the facial skeleton and the facial model according to the first skinning weight and the second skinning weight.
The preset value may be 30%, that is, the weight of the skull Head is greater than or equal to 30% when skinning.
In the embodiment, in order to adjust the bones more freely, the user can pinch an exaggerated and abnormal face shape, the user can exert the face shape freely, and the facial bones are allowed to be adjusted in at least a single axial direction when the face bones are zoomed in and zoomed out in the face pinching process.
The following are embodiments of the apparatus of the present application that may be used to perform embodiments of the method of the present application.
Fig. 8 is a block diagram of an animation model skeleton processing apparatus provided in an embodiment of the present application, which may be implemented as part of or all of an electronic device through software, hardware, or a combination of the two. As shown in fig. 8, the animation model skeleton processing apparatus includes:
the system comprises an acquisition module 1, a control module and a control module, wherein the acquisition module is used for acquiring a first adjustment operation of a first adjustment control corresponding to a current facial skeleton;
a skeleton determining module 2, configured to determine an adjusted facial skeleton corresponding to the current facial skeleton;
the operation determining module 3 is used for determining a second adjusting operation of a second adjusting control corresponding to the adjusting facial skeleton according to the first adjusting operation;
and the adjusting module 4 is used for adjusting the adjusted facial skeleton according to the adjusting parameters.
Optionally, the skeleton determining module 2 is configured to obtain a control state of the associated adjusting control; when the control state is an on state, determining that the adjusted facial skeleton comprises the current facial skeleton and an associated facial skeleton of the current facial skeleton; when the control state is an off state, determining that the adjusted facial bone is the current facial bone.
Optionally, when the control state is the open state, the control state further includes an association range level; the skeleton determining module 2 is further configured to determine an associated facial skeleton of the current facial skeleton according to the association range level.
Optionally, when the control state is the open state, the operation determining module 3 includes:
the gear determining unit is used for determining a first adjusting gear corresponding to the first adjusting operation;
the weight acquisition unit is used for acquiring a first weight corresponding to the current facial skeleton and a second weight corresponding to the related facial skeleton;
the gear calculation unit is used for calculating a second adjusting gear corresponding to the second adjusting control according to the first adjusting gear, the first weight and the second weight;
and the operation determining unit is used for determining a second adjusting operation corresponding to the related facial skeleton according to the second adjusting gear.
Optionally, the operation determining unit is configured to obtain an intermediate gear and a parameter adjustment range corresponding to the associated facial skeleton, where the intermediate gear of the facial skeleton to be adjusted is the same as the intermediate gear of the associated facial skeleton; and determining a second adjusting parameter corresponding to the second adjusting gear according to the intermediate gear and the parameter adjusting range.
Optionally, the apparatus further comprises:
a range obtaining module 5, configured to obtain a first parameter adjustment range of the current facial skeleton, a second parameter adjustment range of the associated facial skeleton, and the number of gears of the first adjustment component and the second adjustment component;
an original gear determining module 6, configured to determine a first original gear corresponding to the current facial skeleton original bone data according to the first parameter adjustment range and the number of gears, and determine a second original gear corresponding to the associated facial skeleton original bone data according to the second parameter adjustment range and the number of gears;
and the intermediate gear calculation module 7 is configured to calculate the intermediate gear according to the first original gear, the second original gear, the first weight, and the second weight.
Optionally, when the second adjustment operation is a zoom operation, the adjusting module 4 is configured to determine an adjustment skeleton corresponding to the adjustment facial skeleton, where the adjustment skeleton is bound with the face model and inherits coordinates of the adjustment facial skeleton; reversely obtaining a second scaling multiple of the adjusting facial bone in a first coordinate axis direction according to the first scaling multiple of the adjusting facial bone in the first coordinate axis direction, wherein the first coordinate axis direction comprises one coordinate axis direction or two coordinate axis directions of the adjusting facial bone, and the scaling operation of the adjusting facial bone and the adjusting bone in the first coordinate axis direction is opposite; obtaining an auxiliary adjusting parameter of the adjusting skeleton according to the first coordinate axis and the second scaling factor; performing an adjustment of the adjustment skeleton according to the auxiliary adjustment parameter.
Optionally, the apparatus further comprises:
the weight obtaining module 8 is used for obtaining a first skinning weight corresponding to a head skeleton and a second skinning weight corresponding to a face skeleton, wherein the first skinning weight is greater than or equal to a preset value;
and a binding module 9, configured to bind the facial skeleton and the facial model according to the first skinning weight and the second skinning weight.
An embodiment of the present application further provides an electronic device, as shown in fig. 9, the electronic device may include: the system comprises a processor 1501, a communication interface 1502, a memory 1503 and a communication bus 1504, wherein the processor 1501, the communication interface 1502 and the memory 1503 complete communication with each other through the communication bus 1504.
A memory 1503 for storing a computer program;
the processor 1501, when executing the computer program stored in the memory 1503, implements the steps of the method embodiments described below.
The communication bus mentioned in the electronic device may be a Peripheral Component Interconnect (pci) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The Memory may include a Random Access Memory (RAM) or a Non-Volatile Memory (NVM), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component.
The present application also provides a computer-readable storage medium having stored thereon a computer program which, when being executed by a processor, carries out the steps of the method embodiments described below.
It should be noted that, for the above-mentioned apparatus, electronic device and computer-readable storage medium embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and for the relevant points, reference may be made to the partial description of the method embodiments.
It is further noted that, herein, relational terms such as "first" and "second," and the like, may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The foregoing are merely exemplary embodiments of the present invention, which enable those skilled in the art to understand or practice the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims (10)
1. A method of facial bone treatment, comprising:
acquiring a first adjusting operation of a first adjusting control corresponding to the current facial skeleton;
determining an adjusted facial skeleton corresponding to the current facial skeleton;
determining a second adjusting operation of a second adjusting control corresponding to the facial skeleton according to the first adjusting operation;
determining an adjusting parameter corresponding to the adjusting facial skeleton according to the second adjusting operation;
and adjusting the adjusted facial skeleton according to the adjusting parameters.
2. The method of claim 1, wherein said determining an adjusted facial bone to which the current facial bone corresponds comprises:
acquiring a control state of the associated adjusting control;
when the control state is an on state, determining that the adjusted facial skeleton comprises the current facial skeleton and an associated facial skeleton of the current facial skeleton;
when the control state is an off state, determining that the adjusted facial bone is the current facial bone.
3. The method of claim 2, wherein when the control state is an on state, the control state further comprises an associated scope level;
the determining an adjusted facial bone corresponding to the current facial bone further comprises:
determining an associated facial skeleton of the current facial skeleton according to the association range level.
4. The method of claim 2, wherein when the control state is an on state, the determining a second adjustment operation for a second adjustment control corresponding to the adjusted facial skeleton according to the first adjustment operation comprises:
determining a first adjusting gear corresponding to the first adjusting operation;
acquiring a first weight corresponding to the current facial skeleton, and acquiring a second weight corresponding to the related facial skeleton;
calculating a second adjusting gear corresponding to the second adjusting control according to the first adjusting gear, the first weight and the second weight;
and determining a second adjusting operation corresponding to the related facial skeleton according to the second adjusting gear.
5. The method of claim 4, wherein said determining a second adjustment parameter corresponding to said associated facial skeleton according to said second adjustment operation comprises:
acquiring a middle gear and a parameter adjusting range corresponding to the associated facial skeleton, wherein the current facial skeleton is the same as the middle gear of the associated facial skeleton;
and determining a second adjusting parameter corresponding to the second adjusting gear according to the intermediate gear and the parameter adjusting range.
6. The method of claim 5, further comprising:
acquiring a first parameter adjusting range of the current facial skeleton, a second parameter adjusting range of the related facial skeleton and the gear number of the first adjusting assembly and the second adjusting assembly;
determining a first original gear corresponding to the current facial skeleton original skeleton data according to the first parameter adjusting range and the gear number, and determining a second original gear corresponding to the associated facial skeleton original skeleton data according to the second parameter adjusting range and the gear number;
and calculating the intermediate gear according to the first original gear, the second original gear, the first weight and the second weight.
7. The method of claim 1, further comprising:
obtaining a first skinning weight corresponding to a head skeleton and a second skinning weight corresponding to a face skeleton, wherein the first skinning weight is greater than or equal to a preset value;
and binding the facial skeleton with a facial model according to the first skinning weight and the second skinning weight.
8. A facial bone treatment device, comprising:
the acquisition module is used for acquiring a first adjustment operation of a first adjustment control corresponding to the current facial skeleton;
a skeleton determination module for determining an adjusted facial skeleton corresponding to the current facial skeleton;
the operation determining module is used for determining a second adjusting operation of a second adjusting control corresponding to the adjusting facial skeleton according to the first adjusting operation;
a parameter determining module, configured to determine, according to the second adjustment operation, an adjustment parameter corresponding to the adjusted facial skeleton;
and the adjusting module is used for adjusting the facial skeleton according to the adjusting parameters.
9. An electronic device, comprising: the system comprises a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory complete mutual communication through the communication bus;
the memory is used for storing a computer program;
the processor, when executing the computer program, implementing the method steps of any of claims 1-7.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the method steps of any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011036179.8A CN112090082A (en) | 2020-09-27 | 2020-09-27 | Facial skeleton processing method and device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011036179.8A CN112090082A (en) | 2020-09-27 | 2020-09-27 | Facial skeleton processing method and device, electronic equipment and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112090082A true CN112090082A (en) | 2020-12-18 |
Family
ID=73782393
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011036179.8A Pending CN112090082A (en) | 2020-09-27 | 2020-09-27 | Facial skeleton processing method and device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112090082A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113658307A (en) * | 2021-08-23 | 2021-11-16 | 北京百度网讯科技有限公司 | Image processing method and device |
CN115690282A (en) * | 2022-12-30 | 2023-02-03 | 海马云(天津)信息技术有限公司 | Virtual role adjusting method and device |
Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104268921A (en) * | 2014-09-12 | 2015-01-07 | 上海明穆电子科技有限公司 | 3D face expression control method and system |
CN106504309A (en) * | 2016-11-24 | 2017-03-15 | 腾讯科技(深圳)有限公司 | A kind of method of image synthesis and image synthesizer |
KR101757642B1 (en) * | 2016-07-20 | 2017-07-13 | (주)레벨소프트 | Apparatus and method for 3d face modeling |
CN109191570A (en) * | 2018-09-29 | 2019-01-11 | 网易(杭州)网络有限公司 | Method of adjustment, device, processor and the terminal of game role facial model |
CN109621419A (en) * | 2018-12-12 | 2019-04-16 | 网易(杭州)网络有限公司 | The generating means method and device of game role expression, storage medium |
CN109829971A (en) * | 2019-01-18 | 2019-05-31 | 恒信东方文化股份有限公司 | A kind of method and device thereof of the physically weak analog model of founder |
CN110111417A (en) * | 2019-05-15 | 2019-08-09 | 浙江商汤科技开发有限公司 | Generation method, device and the equipment of three-dimensional partial body's model |
CN110263617A (en) * | 2019-04-30 | 2019-09-20 | 北京永航科技有限公司 | Three-dimensional face model acquisition methods and device |
CN110689604A (en) * | 2019-05-10 | 2020-01-14 | 腾讯科技(深圳)有限公司 | Personalized face model display method, device, equipment and storage medium |
CN111292427A (en) * | 2020-03-06 | 2020-06-16 | 腾讯科技(深圳)有限公司 | Bone displacement information acquisition method, device, equipment and storage medium |
-
2020
- 2020-09-27 CN CN202011036179.8A patent/CN112090082A/en active Pending
Patent Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104268921A (en) * | 2014-09-12 | 2015-01-07 | 上海明穆电子科技有限公司 | 3D face expression control method and system |
KR101757642B1 (en) * | 2016-07-20 | 2017-07-13 | (주)레벨소프트 | Apparatus and method for 3d face modeling |
CN106504309A (en) * | 2016-11-24 | 2017-03-15 | 腾讯科技(深圳)有限公司 | A kind of method of image synthesis and image synthesizer |
CN109191570A (en) * | 2018-09-29 | 2019-01-11 | 网易(杭州)网络有限公司 | Method of adjustment, device, processor and the terminal of game role facial model |
CN109621419A (en) * | 2018-12-12 | 2019-04-16 | 网易(杭州)网络有限公司 | The generating means method and device of game role expression, storage medium |
CN109829971A (en) * | 2019-01-18 | 2019-05-31 | 恒信东方文化股份有限公司 | A kind of method and device thereof of the physically weak analog model of founder |
CN110263617A (en) * | 2019-04-30 | 2019-09-20 | 北京永航科技有限公司 | Three-dimensional face model acquisition methods and device |
CN110689604A (en) * | 2019-05-10 | 2020-01-14 | 腾讯科技(深圳)有限公司 | Personalized face model display method, device, equipment and storage medium |
CN110111417A (en) * | 2019-05-15 | 2019-08-09 | 浙江商汤科技开发有限公司 | Generation method, device and the equipment of three-dimensional partial body's model |
CN111292427A (en) * | 2020-03-06 | 2020-06-16 | 腾讯科技(深圳)有限公司 | Bone displacement information acquisition method, device, equipment and storage medium |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113658307A (en) * | 2021-08-23 | 2021-11-16 | 北京百度网讯科技有限公司 | Image processing method and device |
CN115690282A (en) * | 2022-12-30 | 2023-02-03 | 海马云(天津)信息技术有限公司 | Virtual role adjusting method and device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109063560B (en) | Image processing method, image processing device, computer-readable storage medium and terminal | |
US11270489B2 (en) | Expression animation generation method and apparatus, storage medium, and electronic apparatus | |
US10171729B2 (en) | Directional adjustment for a camera based on exposure quality information | |
CN106295533B (en) | A kind of optimization method, device and the camera terminal of self-timer image | |
CN112090082A (en) | Facial skeleton processing method and device, electronic equipment and storage medium | |
TWI752419B (en) | Image processing method and apparatus, image device, and storage medium | |
CN106295476A (en) | Face key point localization method and device | |
CN109952594A (en) | Image processing method, device, terminal and storage medium | |
TW202046249A (en) | Method and apparatus for generating virtual avatar, and storage medium | |
CN109063539A (en) | The virtual usual method of glasses, device, computer equipment and storage medium | |
CN110390632A (en) | Image processing method, device, storage medium and terminal based on dressing template | |
WO2021062998A1 (en) | Image processing method, apparatus and electronic device | |
CN106709886A (en) | Automatic image retouching method and device | |
CN110276308A (en) | Image processing method and device | |
WO2021120626A1 (en) | Image processing method, terminal, and computer storage medium | |
US20220375150A1 (en) | Expression generation for animation object | |
CN106846240A (en) | A kind of method for adjusting fusion material, device and equipment | |
CN104167196A (en) | Backlight brightness adjusting method and device and electronic device | |
CN110377201A (en) | Terminal equipment control method, device, computer installation and readable storage medium storing program for executing | |
CN108921798A (en) | The method, apparatus and electronic equipment of image procossing | |
US11216918B2 (en) | Method and device, and storage medium for processing an image | |
JP7102554B2 (en) | Image processing methods, equipment and electronic devices | |
CN115424308A (en) | Intelligent cosmetic mirror and method for displaying auxiliary makeup | |
CN112102453B (en) | Animation model skeleton processing method and device, electronic equipment and storage medium | |
CN113450444B (en) | Method and device for generating illumination map, storage medium and electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |