Hi, apologies if this is a really obvious question. I've spent a couple hours scouring through google and the Autodesk forums with not much luck on a solution.
I'm trying to change the position of a skeleton that is currently bound to an existing mesh (with the end results being that it matches another mesh I made so I can transfer the weights and bind the skeleton to that mesh). My previous solution was that I would create a copy of the skeleton and then delete the limbs that weren't moved into position and then mirror the limbs that were in the correct position. I would then create an animation key for that limb and copy it. I would go back to the original skeleton and paste the animation key for that skeleton causing it to go into the right place without me having to manually edit the transforms for each joint. I am having an issue now where this method does not work very well anymore as the hand joints get messed up when pasting the animation key on to the other limb.
I was wondering if I'm missing something or if there's an easier way to match a skeleton to another mesh to transfer the weights, etc?
I've posted a video showing how I went about it down below!
I'm assuming you created the skeleton symmetry by mirroring the joints along with behavior. Meaning that if you grabbed both shoulder joints and rotated on the Y axis, you would end up with a mirrored pose. If that is the case, all you have to do is write yourself a little script that grabs the rotation values of the left side joints and apply those values to the right side joints. No duplicating or mirroring of joints needed. Or setting keyframes. Much cleaner way to go.
I noted your naming convention. So first, grab all left side joints from the clavicle down. Select the left clavicle joint. (Hopefully, all of your joints are uniquely named).
string $jts[] = stringArrayCatenate(`listRelatives -ad -pa -type "joint"`, `ls -sl`);
for($jt in $jts)
{
string $mirror = `substitute "_l_" $jt "_r_"`;
float $rot[] = `getAttr ($jt+".r")`;
setAttr -type double3 ($mirror+".r") $rot[0] $rot[1] $rot[2];
}
How did you initially mirror your joints? Did you use mirror behavior function? If you did, then both left and right sides would have the exact same rotation values for a mirrored pose. No negating needed.
Can't find what you're looking for? Ask the community or share your knowledge.