Home Technical Talk

Rigging Question.

M3anBONE_sj_
polycounter lvl 18
Offline / Send Message
M3anBONE_sj_ polycounter lvl 18
Okay, i've got my model here and my question is: How do you mirror the rig from one side of the model to another on Maya? This including the binds with the verticies and bones.I did the binding on one side and now I want to mirror those binds to the other side. Any help would be appreciated. THX mad.gif

rig.jpg

Replies

  • FunkaDelicDass
    Options
    Offline / Send Message
    FunkaDelicDass polycounter lvl 18
    Your workflow is a little backwards. You need to mirror the skeleton first, bind it to your mesh, weight one side, then mirror the weights over to the other side. You can't really add bones to a skeleton after binding it to a model, but someone correct me if I'm wrong...

    For the skeleton, use the mirror joint tool and for mirroring the weights go to Edit Smooth Skin - mirror skin weights. Choose your mirror axis and you're good to go.
  • thomasp
    Options
    Offline / Send Message
    thomasp hero character
    there's definitely a script that allows you to add new influences to a skincluster. i have it somewhere on my machine but never actually tested it, so - it might work - or not at all. wink.gif you should be able to find it on highend3d and if not, gimme a call.

    another solution for this problem might be to save weights based on world coordinates with a tool such as aeTransferSkinWeights, then get rid of your skincluster, work on your skeleton, bind and load in those weights again, ready to mirror.

    whatever you decide, do test it out with a less complex scene first. i often create some tiny dummy scene prior to applying some scripted tool to my project. there's just so much that can go wrong...
  • Rakile
    Options
    Offline / Send Message
    Rakile polycounter lvl 18
    Maya certainly isn't my strong point, but from what I remember of my limited rigging work in it, you can add bones to a mesh that already has weights... although I might be confusing Max and Maya here. Ah, wait, I remeber why this wouldn't work very well. If you try to mirror bones that are attached to mesh, the process will make the mesh go nuts. Maybe there's a script or something that can change that, or perhaps Maya 6 doesn't have that problem.

    While is may be annoying to have to redo the weights, I think your best solution is to get rid of the skin, mirror the bones, and then redo the weights. I know that Maya has an excellent system for mirroring weights, so that shouldn't be too bad.
  • Whargoul
    Options
    Offline / Send Message
    Whargoul polycounter lvl 18
    There is no need to redo any weights, you just need to mirror the skeleton parts, add them as influences, then mirror weights.

    1. Select the root of each skeleton structure you need mirrored, and do a "mirror joint". ie select the thigh bone, clavicle, etc. Don't select the whole skeleton, just the part you want a mirrored copy of. A little unintuitive at first.

    2. (these next two parts can be tedious) Select the mesh, then one of the new, unbound bones, and use the skin -> Add Influence.

    3. Repeat for each bone.

    (I wrote a script some time ago for selecting multiple bones & a mesh and it adds all the influenes for you. I'm not sure why they limited it to one at a time though frown.gif Maya 7 fixes this. )

    4. After all the bones are bound, use the skin -> mirror skin weihgts tool.

    Done!
  • Whargoul
    Options
    Offline / Send Message
    Whargoul polycounter lvl 18
    Here's the script for adding multiple bones to multiple meshes:

    <font class="small">Code:</font><hr /><pre>
    //global proc CRaddMultiInfluence()
    {
    string $sel[]=`ls -sl`;
    string $objects[];
    string $bones[];
    for ($node in $sel)
    {
    if (`nodeType $node`=="joint") $bones[`size($bones)`]=$node;
    if (`nodeType $node`=="transform") $objects[`size($objects)`]=$node;
    }
    for ($obj in $objects)
    {
    string $cons[] = `listHistory $obj`;
    string $clusters[] = `ls -typ skinCluster $cons`;
    for ($bone in $bones)
    {
    print ("adding bone:"+$bone+" to object "+$obj+"\n");
    skinCluster -e -dr 0.5 -lw true -wt 0 -ai $bone $clusters[0];
    }
    }
    select -r $sel;
    }
    </pre><hr />

    Ripped out of a much larger, comprehensive set of skin tools, so I hope it works smile.gif

    All you do is select the bones you want added & the meshes you want them added to and run it. Done!
  • FunkaDelicDass
    Options
    Offline / Send Message
    FunkaDelicDass polycounter lvl 18
    Ah, I knew it could be done. Thanks for clearing that up Whargoul.
  • M3anBONE_sj_
    Options
    Offline / Send Message
    M3anBONE_sj_ polycounter lvl 18
    Wow, thanks for all the help guys, I appreciate it very much. I decided to save time and just have a good friend of mine who is proficient in character rigging to just do it all for me while I continue working on the textures and other tweeks that need to be done with the model. Again, thank you all for your help, I really appreciate it.
Sign In or Register to comment.