Home Technical Talk

Morph Transfer from a custom character to clothes

polycounter lvl 5
Offline / Send Message
GeeksGoneBad polycounter lvl 5
Hey - I am looking for any advice / recommendations on what software might be easiest to transfer morph targets to clothes. We have a character mesh with hundreds of morphs (overall body, muscles, facial features, etc..) and we want to have a variety of clothes (thousands of them) but they need to be able to conform to the morphs that are altered for the body.... What options do I have for transferring the morphs from the base character mesh to the clothes? TIA for ANY ideas :)

Replies

  • CheeseOnToast
    Offline / Send Message
    CheeseOnToast greentooth
    I've done this manually using the wrap deformer in maya. We only had a few shapes to transfer, although it's probably not too hard to automate the process. Max has the skinwrap modifier, and Blender has the mesh deform modifier. Any of those should get you a result, at least as far as making the various morphs shapes you need.
  • GeeksGoneBad
    Offline / Send Message
    GeeksGoneBad polycounter lvl 5
    Thanks I'll start checking those out - I use Maya now and couldn't find a way to transfer the hundred or so morphs - I'll take a solid look at the wrap deformer - thanks
  • CheeseOnToast
    Offline / Send Message
    CheeseOnToast greentooth
    It's pretty straightforward to do. Make sure the blendshapes are zeroed on your character. Select the clothing mesh(s) followed by the character mesh. Then do create deformer>wrap. Now when you adjust the blendshape sliders, the clothing will be deformed by the character mesh. How successful it is will depend on how complex the clothing is and how extreme the blends are. Some manual cleanup might be needed.

    You'll need to duplicate and delete history from the deformed clothing mesh. This will now be a single blendshape target. Repeat until done (this'll be where you'll want to automate).
  • Mark Dygert
    Yep CheeseOnToast nailed it, "Wrap" and then automate.

    About automation, if you animate the blendshapes, one shape per key, you can advance the timeline one frame, duplicate the wrapped mesh to make the blendshape. Repeat that process over the course of the timeline and you're done, plus clean up of course...

    You can also speed up and smooth out that process with a little scripting. I'm not sure how familiar you are with it but here is some quick code to get you started.

    import maya.cmds as cmds ##Import maya commands
    curFrame = cmds.currentTime (q=True) ##Store the current frame
    curSel = cmds.ls(sl=True,long=True) ##Store the current selected object
    cmds.currentTime ((curFrame + 1)) ##Advance the timeline 1 frame
    cmds.duplicate (st=True) ##Duplicate the mesh
    cmds.select (curSel) ##Select the original object again so we don't dupe the duplicate
    If you drag that code from this window into your shelf and select Python, you'll have a button that advances the timeline one frame and duplicates whatever you have selected.
Sign In or Register to comment.