移動先: 概要 戻り値 フラグ. Python 例.
alignCtx(
[contextName]
, [align=boolean], [anchorFirstObject=boolean], [distribute=boolean], [exists=boolean], [history=boolean], [image1=string], [image2=string], [image3=string], [name=string], [showAlignTouch=boolean])
注意: オブジェクト名や引数を表す文字列はカンマで区切ります。これは概要には示されていません。
alignCtx は 「元に戻す」が可能、「照会」が可能、「編集」が可能 です。
alignCtx コマンドでは、オブジェクトのアラインと配分を行うツールが作成されます。
distributing objects.
戻り値の型は照会モードでは照会フラグが基になります。
align, anchorFirstObject, distribute, exists, history, image1, image2, image3, name, showAlignTouch
: コマンドの作成モードで使用可能なフラグ
|
: コマンドの編集モードで使用可能なフラグ
|
: コマンドの照会モードで使用可能なフラグ
|
: タプルまたはリストとして渡された複数の引数を持てるフラグ
|
import maya.cmds as cmds
# Create a poly sphere and a poly cube, then move them apart
cmds.polySphere(r=3, n='pSphere1')
cmds.move(5, 0, 0)
cmds.polyCube(w=3, h=3, d=3, n='pCube1')
cmds.move(-5, 3, 0)
cmds.select('pSphere1', 'pCube1', r=True)
# Create a new align context which is used to align objects, then switch to it
# Now you can use this tool to align objects
cmds.alignCtx('alignCtx1',a=True)
cmds.setToolTo('alignCtx1')