PDA

View Full Version : Transferring skin cluster values from one joint to another


JasonOsipa
12-18-2003, 01:33 PM
I've got the need to after-the-fact insert some joints into a model I'm building. Now, I know, for 100% sure exactly what needs to be done witht he weighting once those are in, but I am a lazy, lazy bastard (ok, not that lazy, but I really need to spend my time on other things -deadline!)

So what I need is this, and my knowledge of component-level mel does not exist:

If a vert has:
0.2 to jnt1
0.4 to jnt2
0.4 to jnt3

I want to simply tell it "Take anything assigned to jnt1 and drop it onto jnt4 instead", making it:

0.2 to jnt4
0.4 to jnt2
0.4 to jnt3

This makes everything I have to modify ONE button instead of a few hours of work, as this "transfer" of weights is all I'll need to do. -One better, I'd prefer to only have it happen on selected verts, but I'll take what I can get!

I'm assuming that breaks down to some sort of simple if/then/else thing inside a for-loop or two with a vert/joint list, but I just have no idea how to do mel on the vert level.

Please Obi-Wan, you're my only hope. -J.

macaroniKazoo
12-18-2003, 09:30 PM
you can kinda do that with maya "as-is"... if you hold weights on all joints, except for (using your example) jnt1 and jnt4. then all you have to do is flood your mesh on "replace" mode at a value of 1. because the weights on everything else are held, maya can only trasfer the weights that jnt1 has to jnt4. so its effectively a transfer.

its kinda cool, and works a charm. i use it all the time. :)

oh and PS, beacuse you have to hold weights on a single joint at a time, i wrote a script that allows you to select heaps of joints at once, and hold weights on them. download it if you need it:

zooWeightTools (http://www.macaronikazoo.com/mel/download/zooWeightTools.mel)

CGTalk Moderation
01-16-2006, 11:00 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.