移動先: 概要 戻り値 関連項目. フラグ. Python 例.
autoKeyframe([characterOption=string], [state=boolean])
注意: オブジェクト名や引数を表す文字列はカンマで区切ります。これは概要には示されていません。
autoKeyframe は 「元に戻す」が可能、「照会」が可能、「編集」が可能 です。
フラグがない場合、このコマンドは、「autoKeyframe -state on」コマンドの発行後に変更された、すべてのアトリビュートにキーフレームを設定します。修正されたアトリビュートの追跡を中止する場合、「autoKeyframe -state off」を使用してください。 autoKeyframe では、新しいアニメーション カーブは作成しません。アトリビュートは(setKeyframe コマンドで)キーフレーム設定され、修正されたアトリビュートに autoKeyframe で新しいキーフレームを追加する必要があります。 「autoKeyframe -query -state」で、autoKeyframing のカレントの状態を照会することもできます。| int | キーフレーム セットの数。 |
戻り値の型は照会モードでは照会フラグが基になります。
| ロング ネーム(ショート ネーム) | 引数型 | プロパティ | ||
|---|---|---|---|---|
state(st)
|
boolean
|
|
||
|
||||
characterOption(co)
|
string
|
|
||
|
||||
import maya.cmds as cmds # Start remembering attributes that have changed # cmds.autoKeyframe( state=True ) # Set a keyframe for all attributes that have changed # since the last "autoKeyframe( state=True ) # cmds.autoKeyframe() # Stop remembering attributes that have changed. # Note that Subsequent "autoKeyframe" commands # (with no flags) will have no effect until an # autoKeyframe( state=True ) command is executed. # cmds.autoKeyframe( state=False ) # When auto-keying, key all character attributes, not just # those that have changed. # cmds.autoKeyframe( characterOption="all" )