Mastering Autodesk Maya 2011 phần 5 ppt

105 259 0
Mastering Autodesk Maya 2011 phần 5 ppt

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

skInnIng geoMetry | 391 Broken-Joint Skeletons Keep in mind that you also have the option of binding only selected joints. In some circumstances, this can be quite useful. For example, if you set up what is known as a broken-joint skeleton, which uses additional bones outside the main skeleton hierarchy as deformers, these additional joints are usually constrained to the main hierarchy using parent constraints. By using parent constraints, the joints “float” outside the main hierarchy, giving them a level of freedom of movement to create special deformation effects. (Sometimes floating joints are used for facial animation instead of or in addition to blendshape deformers.) When skinning a broken rig to the skeleton, select the floating joints along with the joints in the main hierarchy when the smooth bind operation is performed. The following are the relevant settings: Bind method The bind method determines how joints influence vertices, by either fol- lowing the skeleton’s hierarchy or simply using whichever joint is the closest. The hier- archy of the giraffe is complete and calls for every bone to be weighted; however, for the tips, use Closest In Hierarchy. Include method The include method dictates which vertices are included in the initial volumes. Your options are Closest Volume and Minimum Weight. Choosing Minimum Weight opens an additional option to set the length of the volume. By default this is .25, causing each volume to be 25 percent longer than the bone to which it is attached. Most characters will have a different area of influence based on its location. For instance, the gi- raffe’s knee needs to have a smaller falloff compared to the torso. Choose Closest Volume. There are two types of volumes you can use, a cylinder or a capsule: A cylinder will deliver a hard edge. •u The capsule is rounded at its ends, providing a smoother falloff. •u Keep the capsule turned on. Skinning method The skinning method has the greatest impact on your bind. You can use Classic Linear, Dual Quaternion, or a blend of both. Dual Quaternion provides the most suitable deformations for realistic characters. It •u preserves the volume of a mesh when a joint is twisted or rotated. Classic Linear does not preserve volume and produces a visible shrinking of the •u geometry. Take a look at Figure 7.34 to see the differences between the two. The last two settings relate to how many influences a single vertex can have. It is important to remember that joints are not the only nodes that can be bound to geometry. Other geom- etry can also be used and is therefore considered an influence as well. Most weighted objects do not require more than four influences per vertex, which is Maya’s default. In addition, a lot of game engines have a hard limit of four influences on a single vertex. After binding, you can keep the influences locked to four by selecting Maintain Max Influences. 392 | CHAPTER 7 rIggIng and MusCle systeMs This is particularly useful when weighting geometry for an environment outside of Maya, such as a game engine. Keep the default settings for the giraffe (see Figure 7.35). 4. Choose Bind Skin. Keep in mind that all the weighting can be altered after the bind has been applied. These settings merely give you a place to start and typically require a lot of fine tuning. Furthermore, you can change these settings through the skinCluster node that is attached to the bound geometry (see Figure 7.36). Figure 7.34 The Classic Linear skinning method is applied to the joints on the left and Dual Quater- nion on the right. Figure 7.35 Bind the giraffe geometry to its skeleton. Figure 7.36 The skinCluster node holds all the settings from the initial binding options. skInnIng geoMetry | 393 The giraffe’s initial bind is established; now it’s time to finetune its weighting. Traditionally, modifying weighted geometry has been like feeling your way around in the dark. Maya’s interactive skin tool not only sheds light on each and every vertex but does so with preci- sion and ease of use. The Interactive Skin Bind tool allows you to quickly massage the weights to an acceptable level. 5. Start with the giraffe’s front legs to get used to the controls. Select L_upperarm_jnt. If it isn’t active already, choose Skin  Edit Smooth Skin  Interactive Skin Bind Tool. By default two volumes are displayed. The only interactive one is the volume on the selected joint. The second volume is a reflection that is attached to r_upperarm_jnt. The reflection is displayed based on the reflection tool settings and operates the same way as it does with the transformation tools (see Figure 7.37). Figure 7.37 The interactive vol- umes are reflected by default. 394 | CHAPTER 7 rIggIng and MusCle systeMs Each volume can be translated, rotated, and shaped. A heat-style color graph is used to illustrate the joint’s influence, with red being the highest amount of influence and blue being the least. A few color presets are provided along with the ability to change the color graph any way you would like. The capsule’s manipulator is also color coded. Red, green, and blue are used to repre- sent the three axes, respectively. Depending on which part of the manipulator you grab, the shape of the capsule is altered. For the most part, each axis scales the selected ring uniformly. 6. Use the LMB and grab the top, red, horizontal ring. 7. Resize it to decrease the amount of influence. 8. Repeat this operation for the lower ring. 9. In addition to changing the capsule’s shape, you can also use the traditional Move And Rotate manipulator (scale is based on the volume) to fit the capsule better to the geom- etry. The manipulator is located in the center of the capsule. Looking at the front of the giraffe, translate and rotate the capsule for a better fit. Do the same for its profile. Figure 7.38 shows the adjusted capsule. Figure 7.38 Translate and rotate the capsule to encompass the leg geometry. skInnIng geoMetry | 395 10. Visible interactivity has been limited so far because the giraffe is in its original bind pose position. Translate the leg 1.0 in the Z and 0.5 in the Y. 11. Select l_upperarm_jnt. Notice that the geometry in the middle of the bone appears to be sagging (Figure 7.39). This is an indication that the geometry is not weighted to 1 at those particular vertices. However, the heat map shows full influence. Use the up arrow to go to the preceding joint, L_shoulder_jnt. 12. L_shoulder_jnt overlaps the L_upperarm_jnt, obviously causing the problem. Use the down arrow to return to L_shoulder_jnt. Maya is displaying the non-normalized weight of the joint; therefore, the color displayed is red. What you are actually seeing is the combined weight value of both joints. 13. In the tool settings for Interactive Skin Bind, find Display Weights. It is located above the color graph. Change it to Normalized. You can now see the true weight value of the joint. 14. Use the up arrow to go back to L_shoulder_jnt. Figure 7.39 The geometry in the middle of the bone is sagging even though the volume shows the hottest influence. 396 | CHAPTER 7 rIggIng and MusCle systeMs 15. Modify the volume to fit its bone better. You can hold Shift while moving the red rings to uniformly scale the entire volume. If you hold Shift while adjusting the green or blue rings, the effects are local to that ring. Figure 7.40 shows the results of the new volume shape. 16. Save the scene as giraffe_v12.ma. To see a version of the scene, open the giraffe_v12.ma scene from the chapter7\scenes directory on the DVD. Painting Skin Weights The Interactive Skin Bind tool takes you really far into the weighting process. However, the weights still need work. To make the skin move properly, you need to edit the weight values of the vertices; this can be done with the Paint Weights tool. To maximize the benefits of painting Figure 7.40 Modifying the L_shoulder_jnt’s volume fixes the upper arm. skInnIng geoMetry | 397 weights, your geometry should have good UVs. These are explained in Chapter 11. This exercise demonstrates techniques for painting weights on various parts of the giraffe: 1. Continue with the scene from the previous section, or open the giraffe_v12.ma scene from the chapter7\scenes directory on the DVD. 2. Move the giraffe leg up again to interactively see the effects of painting weights. 3. Translate the leg 1.0 in the Z and 0.5 in the Y.2. 4. In the viewport, switch to smooth-shaded mode (hot key = 6). 5. Select the giraffe geometry, and choose Skin  Edit Smooth Skin  Paint Skin Weights Tool. Make sure the Tool Options window is open. The geometry turns black except for the area around the joint listed in the Influence sec- tion of the Paint Skin Weights Tool window. The geometry is color coded. White indicates a joint weight value of 1 (100 percent). •u Black indicates a joint weight value of 0. •u Shades of gray indicate values between 0 and 1 (see Figure 7.41). •u You can also switch to use the same gradient color ramp used in the Interactive Skin Bind tool. Figure 7.41 The Paint Skin Weights tool color codes the geom- etry based on the amount of weight influence each joint has for each ver- tex of the skinned geometry. 398 | CHAPTER 7 rIggIng and MusCle systeMs The Paint Skin Weights tool uses the Artisan brush interface. As you paint on the model, the operation selected in the Paint Weights section determines how the brush edits the weights. You can replace, add, smooth, or scale weights in the areas you paint on the model. The easiest way to approach weight painting is to stick to only the Add and Smooth operations. Each vertex on the model receives up to a value of 1 from all the joints on the model. The total weight values must equal 1, so if a selected vertex receives a value of 0.8 from a par- ticular joint, the remaining weight value (0.2) must come from another joint in the chain. Usually this remaining weight value comes from a joint close by the vertex as determined by Maya. This is where things can get tricky. If you paint on a vertex using the Replace operation with a value of 0.5 for a particular joint, the remaining 0.5 weight value is distrib- uted among the other joints in the chain, which can lead to some strange and unpredict- able results. If instead you use the Add operation with very low values, you can carefully increase a joint’s influence over a vertex without worrying about Maya assigning the remaining weight values to other joints in the chain. 6. The area you want to paint is the armpit of the front left leg. To expedite the process, force the Paint Weights tool to only display the joints you want to paint influence for. To do this, hold Ctrl and pick each joint you want to work with in the Influences section of the Paint Weights tool. You can also use Shift to select the first and last joints to highlight a group. 7. With your joints selected, click the tack icon in the upper-right corner of the Influences section (see Figure 7.42). 8. Choose L_upperarm_jnt from the influences. 9. Set Paint Operation to Replace and Value to 0.0. 10. Paint the area being pulled by the arm that belongs to the torso. To resize your brush, use the b key. Use Figure 7.43 for reference. 11. Once you have separated the torso skin from arm skin, use the Smooth operation to clean the weights. The giraffe has a bone jutting out in this location. A lot of the weights are still being used by the torso. Figure 7.42 Reduce the num- ber of joints dis- played in the Paint Weights tool by pinning them. skInnIng geoMetry | 399 12. Set the paint value to 0.1. 13. Use the Add operation to move the weights more onto the upper arm. 14. When finished, go back over it with the Smooth operation again. Figure 7.44 shows the progress so far. Figure 7.43 Paint a weight of 0 to remove the influence of the arm. Figure 7.44 The skin weight- ing has been smoothed. 400 | CHAPTER 7 rIggIng and MusCle systeMs There are still a few vertices that are being unruly. 15. Change Paint Tool Mode to Select, and choose two or three of the worst vertices. You can also choose Paint Select. Toward the top of the Paint Skin Weights window is a Tools section. The middle icon is the Weight Hammer tool. This tool assigns an average of the weights around the selected vertices. Figure 7.45 shows the same area from Figure 7.44 after the Weight Hammer tool was applied. 16. You can continue to paint the skin weights with the joints posed. This is an excellent way to get visual feedback as you edit the weights. 17. Save the scene as giraffe_v13.ma. To see a version of the scene to this point, open the giraffe_v13.ma scene from the chapter7\ scenes directory on the DVD. Figure 7.45 The skin weights have been cleaned up with the Weight Hammer tool. [...]... the glutes 14 Set Weight to 0.1 and Operation to Add 15 Paint over the area of the glute to start adding weights •u Low-weight values are blue •u Higher-weight values are green, orange, and red You can also set the Paint Skin Weights tool to paint in Gray 16 Paint L_glute2 as well Figure€7 .55 shows the results of painting the weights Figure€7 .55 Paint weight values for the glute muscles | Chapter... that when you use the Maya Muscle system, the character’s skin geometry must be bound to objects that have the cMuscleObject shape node In other words, you must either replace or convert any existing joints with capsules or Maya Muscle bones You can also transfer any existing skin weights created for Maya joints to the muscle system In the following exercises, you’ll add the Maya Muscle system to the... objects, but they offer better control for deforming the skinned geometry surface Much of the purpose and functionality of influence objects are replaced by Maya Muscle, so this edition of Mastering Maya does not discuss influence objects The Maya Muscle deformer is actually a surface that can be manipulated while connected to the deformed geometry The muscle objects can create complex deformation... of the model Mirror the weights to the other side Use Maya Muscle╇╉ Maya Muscle is a series of tools designed to create more believable ╇╉ deformations and movement for objects skinned to joints Capsules are used to replace Maya joints Muscles are NURBS surfaces that squash, stretch, and jiggle as they deform geometry Master it╇╉ Use Maya Muscle to create muscles for the hind leg of the... but the capsules do not To change this, select each capsule of the legs, and change its capsule axis in the Channel Box to Neg X-Axis Figure€7.48 Maya asks you to specify the axis that points down the length of the joint | The Maya Muscle System â•… 4 05 You can edit the attributes of the capsule in the SHAPES section of the capsule’s Channel Box At the bottom of the Channel Box, you can determine... (for right) on the mirrored objects 4 Click the Convert To Muscle button to create the deformer 5 In the pop-up box, you will be warned that further changes cannot be made to the muscle using the interface controls You’ll also be prompted to name the muscle Name it L_legbicep (see Figure€7 .52 ) Figure€7 .52 You are prompted to name the muscle when you click the Convert To Muscle button Changing Muscles... objects can slide beneath the deformed geometry to create special effects, and muscles also have properties that allow movement such as jiggle, force, and collision | The Maya Muscle System â•… 403 Understanding the Maya Muscle System The Maya Muscle system is a collection of deformation tools that can work independently or in concert to deform geometry so it looks like muscles are bulging and stretching... Options In the options, you can choose which axis the weights are mirrored across The Maya Muscle System Maya Muscle tools deform the surface of geometry much like other types of deformers They simulate the behavior of actual muscles and can be driven by the rotation of joints or expressions Muscles are similar to Maya s influence objects, but they offer better control for deforming the skinned geometry... MayaMuscle.mll (see Figure€7.47) Figure€7.47 Load the Maya Muscle plug-in using the Plug-in Manager Once the plug-in is loaded, you should see the Muscle menu in the Animation menu set (the Muscle menu actually appears in all the menu sets; for the moment, though, you should be using the Animation menu set) 4 Choose Edit  Select All By Type  Joints 5 Go through the selection, and deselect all the tip... been converted from regular polygon geometry ╇╉ Because of this, bones can be almost any shape you need The term bones in this sense should not be confused with Maya s standard bones, which are the shapes that connect joints The reason the Maya Muscle system uses the term bones is because these deformers are useful for simulating the movement of specially shaped bones—such as the scapula—beneath skin . Load the Maya Muscle plug-in using the Plug-in Manager. Figure 7.48 Maya asks you to specify the axis that points down the length of the joint. the Maya MusCle systeM | 4 05 You can. of influence objects are replaced by Maya Muscle, so this edition of Mastering Maya does not discuss influence objects. The Maya Muscle deformer is actually a surface that can be manipulated while. that allow movement such as jiggle, force, and collision. the Maya MusCle systeM | 403 Understanding the Maya Muscle System The Maya Muscle system is a collection of deformation tools that can

Ngày đăng: 09/08/2014, 11:21

Từ khóa liên quan

Tài liệu cùng người dùng

Tài liệu liên quan