Go to: Synopsis. Return value. Related. Flags. Python examples.
scale(
float float float [objects]
, [absolute=boolean], [centerPivot=boolean], [componentSpace=boolean], [constrainAlongNormal=boolean], [deletePriorHistory=boolean], [distanceOnly=boolean], [localSpace=boolean], [objectCenterPivot=boolean], [objectSpace=boolean], [orientAxes=[angle, angle, angle]], [pivot=[linear, linear, linear]], [preserveChildPosition=boolean], [preserveGeometryPosition=boolean], [preserveUV=boolean], [reflection=boolean], [reflectionAboutBBox=boolean], [reflectionAboutOrigin=boolean], [reflectionAboutX=boolean], [reflectionAboutY=boolean], [reflectionAboutZ=boolean], [reflectionTolerance=float], [relative=boolean], [scaleX=boolean], [scaleXY=boolean], [scaleXYZ=boolean], [scaleXZ=boolean], [scaleY=boolean], [scaleYZ=boolean], [scaleZ=boolean], [symNegative=boolean], [worldSpace=boolean], [xformConstraint=string])
Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.
scale is undoable, NOT queryable, and NOT editable.
The scale command is used to change the sizes of geometric
objects.
The default behaviour, when no objects or flags are passed,
is to do a relative scale on each currently selected object
object using each object's existing scale pivot point.
None
move, rotate, xform, xformConstraint
absolute, centerPivot, componentSpace, constrainAlongNormal, deletePriorHistory, distanceOnly, localSpace, objectCenterPivot, objectSpace, orientAxes, pivot, preserveChildPosition, preserveGeometryPosition, preserveUV, reflection, reflectionAboutBBox, reflectionAboutOrigin, reflectionAboutX, reflectionAboutY, reflectionAboutZ, reflectionTolerance, relative, scaleX, scaleXY, scaleXYZ, scaleXZ, scaleY, scaleYZ, scaleZ, symNegative, worldSpace, xformConstraint
Long name (short name) |
Argument types |
Properties |
|
absolute(a)
|
boolean
|
|
|
Perform an absolute operation.
|
|
centerPivot(cp)
|
boolean
|
|
|
Let the pivot be the center of the bounding box of all objects
|
|
componentSpace(cs)
|
boolean
|
|
|
Move in local component space
|
|
constrainAlongNormal(xn)
|
boolean
|
|
|
When true, transform constraints are applied along the vertex normal first
and only use the closest point when no intersection is found along the normal.
|
|
deletePriorHistory(dph)
|
boolean
|
|
|
If true then delete the history prior to the current operation.
|
|
distanceOnly(dso)
|
boolean
|
|
|
Scale only the distance between the objects.
|
|
localSpace(ls)
|
boolean
|
|
|
Use local space for scaling
|
|
objectCenterPivot(ocp)
|
boolean
|
|
|
Let the pivot be the center of the bounding box of each object
|
|
objectSpace(os)
|
boolean
|
|
|
Use object space for scaling
|
|
orientAxes(oa)
|
[angle, angle, angle]
|
|
|
Use the angles for the orient axes.
|
|
pivot(p)
|
[linear, linear, linear]
|
|
|
Define the pivot point for the transformation
|
|
preserveChildPosition(pcp)
|
boolean
|
|
|
When true, transforming an object will apply an opposite transform to its
child transform to keep them at the same world-space position.
Default is false.
|
|
preserveGeometryPosition(pgp)
|
boolean
|
|
|
When true, transforming an object will apply an opposite transform to its
geometry points to keep them at the same world-space position.
Default is false.
|
|
preserveUV(puv)
|
boolean
|
|
|
When true, UV values on scaled components are projected along the axis of
scaling in 3d space. For small edits, this will freeze the world space texture
mapping on the object.
When false, the UV values will not change for a selected vertices.
Default is false.
|
|
reflection(rfl)
|
boolean
|
|
|
To move the corresponding symmetric components also.
|
|
reflectionAboutBBox(rab)
|
boolean
|
|
|
Sets the position of the reflection axis at the geometry bounding box
|
|
reflectionAboutOrigin(rao)
|
boolean
|
|
|
Sets the position of the reflection axis at the origin
|
|
reflectionAboutX(rax)
|
boolean
|
|
|
Specifies the X=0 as reflection plane
|
|
reflectionAboutY(ray)
|
boolean
|
|
|
Specifies the Y=0 as reflection plane
|
|
reflectionAboutZ(raz)
|
boolean
|
|
|
Specifies the Z=0 as reflection plane
|
|
reflectionTolerance(rft)
|
float
|
|
|
Specifies the tolerance to findout the corresponding reflected components
|
|
relative(r)
|
boolean
|
|
|
Perform a operation relative to the object's current position
|
|
scaleX(x)
|
boolean
|
|
|
scaleXY(xy)
|
boolean
|
|
|
Scale in X and Y direction
|
|
scaleXYZ(xyz)
|
boolean
|
|
|
Scale in all directions (default)
|
|
scaleXZ(xz)
|
boolean
|
|
|
Scale in X and Z direction
|
|
scaleY(y)
|
boolean
|
|
|
scaleYZ(yz)
|
boolean
|
|
|
Scale in Y and Z direction
|
|
scaleZ(z)
|
boolean
|
|
|
symNegative(smn)
|
boolean
|
|
|
When set the component transformation is flipped so it is relative to the
negative side of the symmetry plane. The default (no flag) is to transform
components relative to the positive side of the symmetry plane.
|
|
worldSpace(ws)
|
boolean
|
|
|
Use world space for scaling
|
|
xformConstraint(xc)
|
string
|
|
|
Apply a transform constraint to moving components.
- none - no constraint
- surface - constrain components to the surface
- edge - constrain components to surface edges
- live - constraint components to the live surface
|
|
Flag can appear in Create mode of command
|
Flag can appear in Edit mode of command
|
Flag can appear in Query mode of command
|
Flag can have multiple arguments, passed either as a tuple or a list.
|
import maya.cmds as cmds
cmds.scale( 1, 1, 1 )
cmds.scale( 3, 3, 3, 'curve1', pivot=(1, 0, 0), absolute=True )