How to make clothing armature follow the main mesh armature without merging rigs?

Issue #638 resolved
Aaron J. Olson created an issue

I am a bit new at managing multiple sets of clothing plus a body rig so bear with me.
If I have a main model body armature and mesh, and several sets of clothing. I want to be able to swap between the sets of clothing. The clothing items can have fairly different rig setups in the case of jackets, dresses, etc with their own individual bones. I COULD merge all of those rigs together into the main armature, and then move the odd bones onto different bone layers, one layer per outfit or something like that. That setup seems a bit messy to me though.
Is there an alternative? Is it possible NOT to merge the clothing rigs with the main rig and instead just have the clothing rigs follow the main rig? I have seen models where things like skirts or ties or capes have their own armatures, but they follow the parent/main character armature around. Do you know how I might go about accomplishing this?

Thank you,

-Aaron

Comments (10)

  1. Thomas Larsson repo owner

    I guess you could set up copy transform constraints for all bones in the clothes rigs. You don’t want to do that manually, but it should be rather simple to write a script that does this. But wouldn’t it be difficult to select the right armature in the viewport, if you have several overlapping ones?

  2. Alessandro Padovani

    Having multiple rigs for a figure is quite common. Especially parented rigs for weapons or accessories. But if the rig needs to follow the main figure it is probably easier to merge than to setup constraints.

  3. engetudouiti

    I may not recommend to keep rigs for each clothing even though they have individual bones.

    but simply merge all for base rig. then for some scene if I need not the mesh (usually it happen) I remove the dressA, or dressB mesh or append and retarget armature and driver. (so some bones never used, untill you attach the clothing mesh again,, so the more you merged many clothing first, the more the main rig compatible with those clothings. (though you need to retarget driver, and armature everytime you swap or add clothing)

    but I suppose when the 2 dress have same pose bone , then merged 2 skirt rig for one main rig do not know this add on how manage them. blender auto change bone name when merged. and I suppose bone name change for dress B if they have same name custom pose bones. though basically it can keep driver.. I suppose.. not test it.

    so I usually try to avoid to use those clothing (or I rename bone untill merge) at same time.

    And if you use constrain and clean up un-necessary bone, basically it work. you need to set copy transform for same pose bone which include in the clothing. target bone = main rig bone.

    eg spine bones and leg bones etc.. then set the rig as child of main rig (without armature deform).

    then you can keep each clothing with the clothing rig. but if you have installed morphs for individual rigs. it may make things difficult I suppose.

    So I only keep hair rig and mesh, (without merge) and of course when you swap clothing rig and mesh set, by append etc,, each rig need to set constrain taget correctly (if main rig change name for current scene)

  4. engetudouiti

    As I mentioned before, try with some pony tail hairs (or hair which have pose bones) and set constrain is good start point. After you confirm and clear understand the way, (you can free atach or swap hair with rig), go ahead for some type dress. If you do not know how to set constrain , ask again. it is almost same how we retarget rig manually (though I do not like to set each bones, so for retarget use free add on)

  5. engetudouiti

    And one more,, the demerit of the way, untill you change dirver target, transfered morphs never move along with the body mesh shape keys. = not auto follow jcms or shape morphs.

    though it may be good for jcm and clothings about skirt etc,, but sometimes it make things more difficult, and change driver target manually is not so easy anymore. without you understand how each property work correctly and can edit dirver target correctly.

    eg,, clothing A original pose morph need to be driven A rig, but some transfered shape keys (eg abdoman jcm) you may hope it auto change with main body shape , and the main body shape morph driven by main body rig… so it not auto-follow (auto drive the clothing morph which transfered)

    So I only use the copy constrain. for prop type clothing like armor plate etc... (actually I currently use it for the character armor, keep individual rig and attach it with constrain for skirt armor) if you hope to get auto-follow for the clothing , you may better merge rigs and transfer morphs.

  6. engetudouiti

    Most simple case of add constrain for the clothing rig is like this.

    I now have hand made side skirt plate with rig. the rig only have pelivis bone + separate pose bones.

    Then I hope this skirt as individual rig, but hope to move along with character rig pelvis (as this case I use MHX, so please change it as you need)

    1. set the plate rig as child of the main rig (though it need not, but to manage easy I prefer) (not armature modifer deform)
    2. select the armor pelvis bone, and add bone constrain > copy transform then set up like this.

    So the armor pelvis bone just move along with the main rig pelivis bone. (can pose as if it attached by armature modifer with main rig)

    but can pose with each bone, and easy move around in the scene. (put off etc) though it may change how the dress is made,,

    But it not auto follow any morph (though about this case I usually need not, but many dress may need to follow base shape morph, I suppose.. then recommend test with simple case like hair first. actually I keep 4 pony tail and 2 tail in library with keep original rig ^^; and swap it when I need.

  7. Aaron J. Olson reporter

    Thomas, thank you for the tip on the copy transform constraint! That is good to know. I was thinking of taking all of the overlapping clothing bones and putting them on their their own rig layer after setting them up to follow the main rig (since I would rarely need to use them, at least in theory).

    Thank you for all of the info engetudouiti! That case for the constrain clothing rig looks like exactly what I am trying to do. Maybe you are right and I should merge the rigs to cover the overlapping parts and then just split the special parts off onto their own rigs. I will try the copy transform constrain setup for hair as well.

  8. engetudouiti

    Aaron just to confirm (though I feel you understand well what you need), I means I may merge rigs (so all clothing pose bone will be merged as one character rig) then only keep each mesh as library.

    I afraid, you can not separate the special part off onto their own rig (I do not think it work well) for dress etc.. (though like this type armor, it may work?) but merge layered part only. it may need to use 2 armature modifer for one mesh. (and I seldom try it,,)

    So I means, option A (merge rigs then keep the rig witch can attach many clothing = it may need to keep many clothing pose bones as character rig , then you exchange clothing mesh only and (you described as OP topic , it is what I usually set up for long dress etc)

    option B (not merge rigs but keep separate clothing rig and only use constrain for clothing bones which need to follow main rig bone = layered part bones, but move free clothing pose bones

    both have pro and con. option B may keep clean character rig, but to transfer morphs and controll driver, it is not easy (or sometimes you may find morph not work as you expected, because constrain pose bones not get real rotation values = transfered JCM not work correctly when you pose those bone.

    option A need to keep each clothing pose bone so if your rig wear 4 clothing you need to keep all clothing pose bone as one rig (even though you do not use it for current scene) but it make stable how JCM (transfered morph) drive with rig pose. (because it not use constrain = all pose bone rotation value = real value and you can control by same rig bone, then you need not tweak driver etc.

    Anyway I think you know what you need, then may notice case when it not work well.. at same time I suppose Thomas will offer such function if he like the way. (though do not know it can work transferred JCM drive and how he manage them)

  9. engetudouiti

    Though it is close topic, but now I get new idea to use 2 armature modifer from your comment ^^

    If it work,, we need not merge rig, but simply remove same name bone from clothing. (I plan only remain hip bone ) then attach 2 armature modifer. and keep defualt character rig without attach new bone.

    so it pose with default rig, then pose with clothing rig (it can move manually)

    I may test later with some clothing… thanks.

  10. Log in to comment