Saturday, July 23, 2011

Maya - Skinning

To bind the skin to the bones (joints) select skeleton, shift select geometry - Skin - Bind Skin - Smooth Bind.

Paint Weights (Animation menu - Skin - Edit Smooth Skin - Paint Skin Weights Tool).
Under Influences (by Hierarchy) you can select the joints you want to paint the weights. Carefull with that tool, because it tends to mess the model (if you sometimes undo).
When holding "B" you can scale your brush.
Paint Weights:
Paint Operation - Replace, Add, Scale, Smooth
Value is important it changes the brush from Black (0) to White (1).

Mirror Skin Weights - if your model is symetrical and you worked on one side of it, you can mirror the skin weights to the other symetrical side - XY, YZ or XZ. Leave at Closest point on surface.
Important - when miroring the skin weights - remember to bring back the model to its default (if you have set any kind of keys or animation - revert to pose 0 - or key 1, to apply the mirror).

IF YOU CHANGE your geometry WHILE your geo is skinned - its very possible your skin weights to get skrewed!!! so:
Export Skin Weight Maps.
You can export the painted weights into a map and then import it back onto the model. (that can be done for safekeeping) :)
Select the geo mesh, (Animation) Skin> Edit Smooth Skin> Export Skin Weight Maps Options.
In the options you can choose export Value (Alpha or Luminance*)
Map size for example 1024px. Image format - i choose Tiff because it doesnt lose quality and supports alphas (for example JPG doesnt).
Tip* - when you click Export button it will ask you to save your file, name it and it will write as many maps as joints you have. I think ALpha or Luminance is the same if you choose TIFF format, because when you open the file you can see the painted weights on the layer and an alpha chanel with your UVS. It will also make a new folder for all the tiff files, but the main file you can re-import is (whatevename).weightMap.
Prune Small Weights - takes away any weight thats below the number put in "Prune below". Good for getting rid of minor influences.
**TIP - if you have Game UVs (mirrored on top of each other) - export skin weights might be NOT the best solution. Instead use the command copy skin weights (you must have OLD skin weights model saved on a separate file, import that maya file select first model with GOOD skin weights, shift select the second model you want to paste the weights over and hit command - Copy skin weights (under (Animation) Skin> Edit Smooth Skin.)

Reset Weights to Default - just reset and start from scratch.

Skinning with Clothing
How to skin a model with separate cloths.
1 method: You can create cloth (Maya Cloth, nCloth), so when the model is set as a collision, once the model is moved the clothes will respond to that movement.

2 method: You have to bind cloths to their appropriate joints. Do not bind clothing to the entire mesh, just select the respective joints to bind them. So first bind the character (mesh) to the skeleton (the whole skeleton) then select the base mesh (the one with weights painted) and select cloths, then copy skin weights. It takes the weights from the base mesh and adds them to the clothing mesh.


-Once you bind/skin the mesh to your skeleton - you can no longer scale the mesh (as you can see the scale tool is disabled).
-if you need to UNBINED the mesh from your skeleton
   1. select the mesh then go into (Animation) Skin>Detach Skin
   OR 2. select your mesh and EDIT - Delete by Type - History - so there no longer a conencion between both.

Select the mesh (you want to add an influence/joint to be bind) - select the desired joint (Animation) SKin > Edit Smooth Skin > Add Influence.

- MOVE JOINT While Skin is binded
Select the Joint you want to move, go (Animation) Skin - Edit Smooth Skin - Move Skinned Joints Tool (and move your joint)

Exclude Joints from binded skin:
Select the mesh (geometry) - SHIFT select a joint, go to (Animation) Skin - Edit Smooth Skin - Remove Influence.

Manipulate the IK Pole Vector
Select the IK rotate plane handle, click the "Show Manipulator Tool" on ( T key). The IK handle's pole vector, twist disc, and rotation disc are displayed.

No comments:

Post a Comment