pymel.core.general.align

static general.align(*args, **kwargs)

Align or spread objects along X Y and Z axis.

Flags:
Long name (short name) Argument Types Properties
alignToLead (atl) bool ../../../_images/create.gif
 
When set, the min, center or max values are computed from the lead object. Otherwise, the values are averaged for all objects. Default is false
coordinateSystem (cs) PyNode ../../../_images/create.gif
 

Defines the X, Y, and Z coordinates. Default is the world coordinates Flag can have multiple arguments, passed either as a tuple or a list.

xAxis (x) unicode ../../../_images/create.gif
 
Any of none, min, mid, max, dist, stack. This defines the kind of alignment to perfom, default is none.
yAxis (y) unicode ../../../_images/create.gif
 
Any of none, min, mid, max, dist, stack. This defines the kind of alignment to perfom, default is none.
zAxis (z) unicode ../../../_images/create.gif
 
Any of none, min, mid, max, dist, stack. This defines the kind of alignment to perfom, default is none.

Derived from mel command maya.cmds.align

Example:

import pymel.core as pm

# align the selected objects to their average mid-point in x
pm.align(x='mid')
# align the selected objects to the mid-point in x of the first select object
pm.align(x='mid', alignToLead=True)

Previous topic

pymel.core.general.aliasAttr

Next topic

pymel.core.general.artAttrTool

Core

Core Modules

Other Modules

This Page