Go to: Synopsis. Return value. Keywords. Related. Flags. MEL examples.
bakeClip [-blend uint uint] [-clipIndex uint] [-keepOriginals] [-name string]
bakeClip is undoable, NOT queryable, and NOT editable.
This command is used to bake clips and blends into a single clip.
character, clip, blend, animation, bake
clip, clipSchedule
blend, clipIndex, keepOriginals, name
Long name (short name) |
Argument types |
Properties |
-blend(-b)
|
uint uint
|
|
|
Specify the indices of the clips being blended.
|
|
-clipIndex(-ci)
|
uint
|
|
|
Specify the index of the clip to bake.
|
|
-keepOriginals(-k)
|
|
|
|
Keep original clips in the trax editor and place the merged clip into the visor. The default is to schedule the merged clip, and to keep the original clips in the visor.
|
|
-name(-n)
|
string
|
|
|
Specify the name of the new clip to create.
|
|
Flag can appear in Create mode of command
|
Flag can appear in Edit mode of command
|
Flag can appear in Query mode of command
|
Flag can be used more than once in a command.
|
// First create a simple character.
//
cone -n bakeCone;
character -n coneCharacter;
// Create some animation.
//
select -r bakeCone;
currentTime 0; setKeyframe -v 0 bakeCone.tx;
currentTime 10; setKeyframe -v 10 bakeCone.tx;
// Make a clip.
//
clip -startTime 0 -endTime 10 -name "up" "coneCharacter";
// Create a second clip.
//
select -r bakeCone;
currentTime 15; setKeyframe -v 15 bakeCone.tx;
currentTime 25; setKeyframe -v 0 bakeCone.tx;
// Make a clip.
//
clip -startTime 15 -endTime 25 -name "down" "coneCharacter";
// Blend the clips, with a linear weighting function.
//
string $scheduler = `character -q -sc "coneCharacter"`;
clipSchedule -b 0 1 $scheduler;
string $blendNode[] = `clipSchedule -bn 0 1 -q $scheduler`;
setKeyframe -at weight -t 0.0 -v 0.0 $blendNode[0];
setKeyframe -at weight -t 1.0 -v 1.0 $blendNode[0];
// Bake out the two clips and the blend.
//
bakeClip -ci 0 -ci 1 -name "bakedUpAndDown" "coneCharacter";