Your Ad Here

Go to: Synopsis. Flags. Return value. Python examples.

Synopsis

polyAutoProjection([constructionHistory=boolean], [createNewMap=boolean], [layout=int], [name=string], [optimize=int], [percentageSpace=float], [pivot=[float, float, float]], [pivotX=float], [pivotY=float], [pivotZ=float], [planes=int], [polyGeomObject=DAGobject], [projectBothDirections=boolean], [rotate=[angle, angle, angle]], [rotateX=angle], [rotateY=angle], [rotateZ=angle], [scale=[linear, linear, linear]], [scaleMode=int], [scaleX=linear], [scaleY=linear], [scaleZ=linear], [skipIntersect=boolean], [translate=[linear, linear, linear]], [translateX=linear], [translateY=linear], [translateZ=linear], [uvSetName=string], [worldSpace=boolean])

Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.

polyAutoProjection is undoable, queryable, and editable.

Projects a map onto an object, using several orthogonal projections simultaneously.

Flags

constructionHistory, createNewMap, layout, name, optimize, percentageSpace, pivot, pivotX, pivotY, pivotZ, planes, polyGeomObject, projectBothDirections, rotate, rotateX, rotateY, rotateZ, scale, scaleMode, scaleX, scaleY, scaleZ, skipIntersect, translate, translateX, translateY, translateZ, uvSetName, worldSpace
Long name (short name) [argument types] Properties
planes(p) int createqueryedit
Number of intermediate projections used. Valid numbers are 4, 5, 6, 8, and 12.
C: Default is 6.

In query mode, this flag needs a value.

optimize(o) int createqueryedit
Use two different flavors for the cut generation.
0 Every face is assigned to the best plane. This optimizes the map distortion.
1 Small UV pieces are incorporated into larger ones, when the extra distortion introduced is reasonable. This tends to produce fewer UV pieces.

In query mode, this flag needs a value.

skipIntersect(si) boolean createqueryedit
When on, self intersection of UV pieces are not tested. This makes the projection faster and produces fewer pieces, but may lead to overlaps in UV space.

In query mode, this flag needs a value.

scaleMode(sc) int createqueryedit
How to scale the pieces, after projections:
0 No scale is applied.
1 Uniform scale to fit in unit square.
2 Non proportional scale to fit in unit square.

In query mode, this flag needs a value.

layout(l) int createqueryedit
What layout algorithm should be used:
0 UV pieces are set to no layout.
1 UV pieces are aligned along the U axis.
2 UV pieces are moved in a square shape.

In query mode, this flag needs a value.

percentageSpace(ps) float createqueryedit
When layout is set to square, this value is a percentage of the texture area which is added around each UV piece. It can be used to ensure each UV piece uses different pixels in the texture.
Maximum value is 5 percent.

In query mode, this flag needs a value.

createNewMap(cm) boolean createquery
Create a new UV set, as opposed to editing the current one, or the one given by the -uvSetName flag.

In query mode, this flag needs a value.

uvSetName(uvs) string createquery
Specifies the name of the UV set to edit uvs on. If not specified will use the current UV set if it exists.
When createNewMap is on, the name is used to generate a new unique UV set name.

In query mode, this flag needs a value.

worldSpace(ws) boolean createqueryedit
This flag specifies which reference to use. If "on" : all geometrical values are taken in world reference. If "off" : all geometrical values are taken in object reference.
C: Default is "on".
Q: When queried, this flag returns an integer.

In query mode, this flag needs a value.

projectBothDirections(pb) boolean createqueryedit
This flag specifies which reference to use. If "on" : projections are mirrored on directly opposite faces. If "off" : projections are not mirrored on opposite faces.
C: Default is "off".
Q: When queried, this flag returns an integer.

In query mode, this flag needs a value.

polyGeomObject(pg) DAGobject createquery
Specifies an optional Polygonal object.
UVs will be projected through this object.

In query mode, this flag needs a value.

translate(t) [linear, linear, linear] createqueryedit
This flag specifies the translation vector.
C: Default is 0.0 0.0 0.0.
Q: When queried, this flag returns a float[3].

In query mode, this flag needs a value.

translateX(tx) linear createqueryedit
This flag specifies the X translation vector.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

translateY(ty) linear createqueryedit
This flag specifies the Y translation vector.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

translateZ(tz) linear createqueryedit
This flag specifies the Z translation vector.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

rotate(ro) [angle, angle, angle] createqueryedit
This flag specifies the rotation angles around X, Y, Z.
C: Default is 0.0 0.0 0.0.
Q: When queried, this flag returns a float[3].

In query mode, this flag needs a value.

rotateX(rx) angle createqueryedit
This flag specifies the rotation angle around X.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

rotateY(ry) angle createqueryedit
This flag specifies the rotation angle around Y.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

rotateZ(rz) angle createqueryedit
This flag specifies the rotation angle around Z.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

scale(s) [linear, linear, linear] createqueryedit
This flag specifies the scaling vector.
C: Default is 1.0 1.0 1.0.
Q: When queried, this flag returns a float[3].

In query mode, this flag needs a value.

scaleX(sx) linear createqueryedit
This flag specifies X for scaling vector.
C: Default is 1.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

scaleY(sy) linear createqueryedit
This flag specifies Y for scaling vector.
C: Default is 1.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

scaleZ(sz) linear createqueryedit
This flag specifies Z for scaling vector.
C: Default is 1.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

pivot(pvt) [float, float, float] createqueryedit
This flag specifies the pivot for scaling and rotation.
C: Default is 0.0 0.0 0.0.
Q: When queried, this flag returns a float[3].

In query mode, this flag needs a value.

pivotX(pvx) float createqueryedit
This flag specifies the X pivot for scaling and rotation.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

pivotY(pvy) float createqueryedit
This flag specifies the Y pivot for scaling and rotation.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

pivotZ(pvz) float createqueryedit
This flag specifies the Z pivot for scaling and rotation.
C: Default is 0.0.
Q: When queried, this flag returns a float.

In query mode, this flag needs a value.

name(n) string create
Name the resulting object.
constructionHistory(ch) boolean createquery
Turn the construction history on or off (where applicable).

In query mode, this flag needs a value.


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.

Return value


string The node name.

Python examples

import maya.cmds as cmds

# Create a plane with default UVs.
cmds.polySphere( n='sph' )

# Automatic projections with 6 planes.
cmds.polyAutoProjection( 'sphShape.f[*]' )

  

Return to Autodesk Index


Your Ad Here