ジャンプ先: 概要. 戻り値. 関連. フラグ. Python 例.
deformer(
selectionList
, [after=boolean], [afterReference=boolean], [before=boolean], [components=boolean], [deformerTools=boolean], [dumpInfo=boolean], [exclusive=string], [fixedSetupData=string], [frontOfChain=boolean], [geometry=string], [geometryIndices=boolean], [ignoreSelected=boolean], [includeHiddenSelections=boolean], [name=string], [parallel=boolean], [prune=boolean], [remove=boolean], [selectedComponents=boolean], [split=boolean], [type=string], [useComponentTags=boolean])
注: オブジェクトの名前と引数を表す文字列は、カンマで区切る必要があります。これはシノプシスに示されていません。
deformer は、取り消し可能、照会可能、および編集可能です。
このコマンドは、指定したタイプのデフォーマを作成します。デフォーマでは、選択したオブジェクトが変形されます。
このコマンドはデフォーマ ノードを作成して、デフォメーション チェーンに接続します。デフォーマがまだ存在しない場合は、作成されます。デフォーマが既に存在する場合は、このコマンドを使用して、指定したデフォーマのパラメータを変更できます。特殊なデフォーマのコマンドとは異なり、このコマンドでデフォーマ固有のセットアップを作成または管理することはありません。このコマンドを使用すると、デフォメーション チェーンをより一般的な方法で管理することができます。
| string[] | 作成/編集されたアルゴリズム ノードの名前。 |
照会モードでは、戻り値のタイプは照会されたフラグに基づきます。
cluster, flexor, lattice, percent, sculpt, wire, wrinkle
after, afterReference, before, components, deformerTools, dumpInfo, exclusive, fixedSetupData, frontOfChain, geometry, geometryIndices, ignoreSelected, includeHiddenSelections, name, parallel, prune, remove, selectedComponents, split, type, useComponentTags
フラグはコマンドの作成モードで表示できます
|
フラグはコマンドの編集モードで表示できます
|
フラグはコマンドの照会モードで表示できます
|
フラグに複数の引数を指定し、タプルまたはリストとして渡すことができます。
|
import maya.cmds as cmds
# Select the geometries that you'd like to deform,
# and use the deformer command as follows. For example, to deform a
# cylinder with a deltaMush:
#
cmds.cylinder( ax=(0, 1, 0), r=1, hr=10, d=3, s=8, nsp=20, ch=1 )
cmds.select( 'nurbsCylinder1', r=True )
cmds.deformer( type="deltaMush" )
# To query the membership of the deformer
#
cmds.deformer( 'deltaMush1',q=True, g=True )
# To add additional geometries from your deformer, type:
#
cmds.select( 'nurbsCylinder1', r=True )
cmds.duplicate()
# Result: nurbsCylinder2 #
cmds.move( -2.749017, 0, 0, r=True )
cmds.deformer( 'deltaMush1', e=True, g='nurbsCylinder2' )
# To remove a geometry from your deformer, type:
#
cmds.deformer( 'deltaMush1', e=True, rm=True, g='nurbsCylinder2' )
# To query the components and the selected components used by the deformer
cmds.polyCylinder(r=1, h=6, sx=6, sy=1, sz=1)
cmds.select(['pCylinder1.vtx[6:11]', 'pCylinder1.vtx[13] '], r=True)
cmds.cluster()
cmds.select(['pCylinder1.vtx[4:5]', 'pCylinder1.vtx[10:11] '], r=True)
cmds.deformer('cluster1', q=True, cmp=True)
# Result: ['pCylinder1.vtx[6:11]', 'pCylinder1.vtx[13]'] #
cmds.deformer('cluster1', q=True, cms=True)
# Result: ['pCylinder1.vtx[10:11]'] #