pymel.core.animation.setKeyframeBlendshapeTargetWts

setKeyframeBlendshapeTargetWts(*args, **kwargs)

This command can be used to keyframe per-point blendshape target weights. It operates on the currently selected objects as follows. When the base object is selected, then the target weights are keyed for all targets. When only target shapes are selected, then the weights for thoses targets are keyframed.

Derived from mel command maya.cmds.setKeyframeBlendshapeTargetWts

Example:

import pymel.core as pm

import maya.cmds as cmds

# first create a blendShape
#
pm.polySphere()
# Result: [nt.Transform(u'pSphere1'), nt.PolySphere(u'polySphere1')] #
pm.duplicate()
# Result: [nt.Transform(u'pSphere2')] #
pm.duplicate()
# Result: [nt.Transform(u'pSphere3')] #
pm.select( 'pSphere2', 'pSphere1', 'pSphere3', r=True )
pm.blendShape()
# Result: [nt.BlendShape(u'blendShape1')] #
# Select one of the targets, and key its per-point weights.
# Typically this would be done after painting per-point weights
# for the target.
#
pm.select( 'pSphere2', r=True )
pm.setKeyframeBlendshapeTargetWts()

Previous topic

pymel.core.animation.setKeyframe

Next topic

pymel.core.animation.shot

Core

Core Modules

Other Modules

This Page