how to characterize a skeleton?

how to characterize a skeleton?

Anonymous
Not applicable
1,655 Views
4 Replies
Message 1 of 5

how to characterize a skeleton?

Anonymous
Not applicable

Hi

 

I'm working on a tool and I get stuck right at the end when I have to characterize the skeleton.

I know how to create the character and it appears in the navigator, but I don't understand how to set it as the current character so I can activate it.

Also I'm  not sure how to assign it to the skeleton.

 

I read on an another topic that I should evaluate the scene but this concept is not clear to me.

 

Could you guys explain me which should be the procedure?

 

I imagine is something like create the character, make it current, assign it to the skeleton, activate it. Or am I totally wrong?

0 Likes
Accepted solutions (1)
1,656 Views
4 Replies
Replies (4)
Message 2 of 5

Anonymous
Not applicable
Accepted solution

This is part of my script(MB2014) to characterize my mocap actor. Hope it helps.

 

from pyfbsdk import *
from pyfbsdk_additions import *

def addJointToCharacter ( characterObject, slot, jointName ):
    
    myJoint = FBFindObjectByFullName('Model::' + jointName)
    property = characterObject.PropertyList.Find(slot + "Link")
    property.append (myJoint)
        
def CharacterizeHiRes(charName):
    
    # make a character
    myCharacter = FBCharacter (charName)
    # Assign the models to the slots
    addJointToCharacter (myCharacter, 'Reference', charName)
    addJointToCharacter (myCharacter, 'Hips', 'Hips')
    addJointToCharacter (myCharacter, 'LeftUpLeg', 'LeftUpLeg')
    addJointToCharacter (myCharacter, 'LeftLeg', 'LeftLeg')
    addJointToCharacter (myCharacter, 'LeftFoot', 'LeftFoot')
    addJointToCharacter (myCharacter, 'RightUpLeg', 'RightUpLeg')
    addJointToCharacter (myCharacter, 'RightLeg', 'RightLeg')
    addJointToCharacter (myCharacter, 'RightFoot', 'RightFoot')
    addJointToCharacter (myCharacter, 'Spine', 'Spine')
    addJointToCharacter (myCharacter, 'LeftArm', 'LeftArm')
    addJointToCharacter (myCharacter, 'LeftForeArm', 'LeftForeArm')
    addJointToCharacter (myCharacter, 'LeftHand', 'LeftHand')
    addJointToCharacter (myCharacter, 'RightArm', 'RightArm')
    addJointToCharacter (myCharacter, 'RightForeArm', 'RightForeArm')
    addJointToCharacter (myCharacter, 'RightHand', 'RightHand')
    addJointToCharacter (myCharacter, 'Head', 'Head')
    addJointToCharacter (myCharacter, 'LeftToeBase', 'LeftToeBase')
    addJointToCharacter (myCharacter, 'RightToeBase', 'RightToeBase')
    addJointToCharacter (myCharacter, 'LeftShoulder', 'LeftShoulder')
    addJointToCharacter (myCharacter, 'RightShoulder', 'RightShoulder')
    addJointToCharacter (myCharacter, 'Spine1', 'Spine1')
    addJointToCharacter (myCharacter, 'Spine2', 'Spine2')
    addJointToCharacter (myCharacter, 'Spine3', 'Spine3')
    addJointToCharacter (myCharacter, 'Neck', 'Neck')
    # turn character on, for some reason this often causes mB2012 to crash.
    myCharacter.SetCharacterizeOn(1) 

#characterize hiRes
CharacterizeHiRes('MyCharacter')

 

Message 3 of 5

Anonymous
Not applicable

I should say that I think Jason Parks wrote those functions initially, but you see them in the autodesk examples and other places now.

0 Likes
Message 4 of 5

Anonymous
Not applicable
Thanks brian! When I got back home I checked Jason book again and the answer was right there 🙂
Cheers!
0 Likes
Message 5 of 5

Anonymous
Not applicable
So long ago . . .
0 Likes