Biped Layers

 

   

Character Studio - Quick Navigation

Layer Related Methods

biped.collapseAtLayer <biped_ctrl> <index> 		

Collapses layer index+1 into layer index. All layers underneath (<= index+1) should be active for this function to work. Returns true if successful, otherwise false.

   

biped.createLayer <biped_ctrl> <index> <name> 	 

Creates a layer at the specified position, maximum index value can be NumLayers

   

biped.deleteLayer <biped_ctrl> <index>   

Deletes the specified layer

   

biped.getCurrentLayer <biped_ctrl> 

Returns the position of the currently active layer in the UI

   

biped.getLayerActive <biped_ctrl> <index> 

Returns true if the specified layer is active.

   

biped.getLayerName <biped_ctrl> <index> 

Returns the specified layer name

   

biped.numLayers <biped_ctrl> 

Returns the number of layers

   

biped.setCurrentLayer <biped_ctrl> <index> 

Sets the active layer in the UI to the specified layer

   

biped.setLayerActive <biped_ctrl> <index> <bool_val> 

Sets the specified layer to active/inactive based upon the bool_val passed

   

biped.setLayerName <biped_ctrl> <index> <name> 

Sets the specified layer name to the value passed

   

biped.setSnapKey <biped_node> 

Sets the snap key for a layer

The following example will create a new Biped, access it’s Vertical_Horizontal_Turn(Body) controller and load a specific *.Bip file:

EXAMPLE

-- create a new Biped
bipObj = biped.createNew 100 100 [0,0,0] 
-- select bipObj 
bip = bipObj.controller   
max motion mode   
-- File I/O 
biped.LoadBipFile bip (CSPATH + "scripts\\Limploop.bip") 

Layer Retargeting Methods

The following functions are used for retargeting biped layer animation, either to the base layer or to a reference biped.

biped.getLimbRetargetState <limb_node> 

Returns the retarget state of a limb.

Expects any node from a biped limb as argument.

Available in 3ds Max 2010 and higher.

   

biped.setLimbRetargetState <limb_node> <state> 

Sets the retarget state of the given limb.

Expects any node from a biped limb as first argument, a Boolean value as second argument.

Available in 3ds Max 2010 and higher.

   

biped.getRetargetRefBip <bipcontrol> 

Returns the retarget reference biped for the given biped, or undefined if no reference biped is assigned.

Available in 3ds Max 2010 and higher.

   

biped.setRetargetRefBip <bipcontrol> <refBipNode> 

Sets the retarget reference biped.

The first argument is the biped for which the refbip is being set.

The second argument is the refbip - any node from a different biped.

Returnstrue if the reference biped was set correctly, falseotherwise.

Available in 3ds Max 2010 and higher.

   

biped.retargetToReferenceBiped <bipcontrol> <IK_Only> 

Retarget to reference biped passed as first argument.

The secondargumentis the IK Only flag.

For every limb whose retarget state is active, calculates the hand/foot position at every key, maintaining IK constraints to the retarget biped.

When IK_Only is true, the biped's constrained hands and feet are retargeted only during the frames on which they are IK controlled.

Available in 3ds Max 2010 and higher.

   

biped.retargetToBaseLayer <bipcontrol> <IK_Only> 

Retargets the biped passed as first argument to base layer.

The secondargumentis the IK Only flag.

A layer must be active.

For every limb whose retarget state is active, calculates the hand/foot position at every key, maintaining IK constraints to the base layer.

When IK_Only is true, the biped's constrained hands and feet are retargeted only during the frames on which they are IK controlled.

Available in 3ds Max 2010 and higher.

See Also