place the UVs of the selected polygonal objects so that they do not overlap.
Long name (short name) | Argument Types | Properties | |
---|---|---|---|
flipReversed (fr) | bool | ||
|
|||
layout (l) | int | ||
|
|||
layoutMethod (lm) | int | ||
|
|||
offsetU (ou) | float | ||
|
|||
offsetV (ov) | float | ||
|
|||
percentageSpace (ps) | float | ||
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. |
|||
prescale (psc) | int | ||
|
|||
rotateForBestFit (rbf) | int | ||
|
|||
scale (sc) | int | ||
|
|||
sizeU (su) | float | ||
|
|||
sizeV (sv) | float | ||
|
|||
uvSetName (uvs) | unicode | ||
Specifies the name of the uv set to edit uvs on. If not specified will use the current uv set if it exists. Flag can have multiple arguments, passed either as a tuple or a list. |
Derived from mel command maya.cmds.polyMultiLayoutUV
Example:
import pymel.core as pm
# Create 3 objects with overlapping UVs
sphere = pm.polySphere()
cylinder = pm.polyCylinder()
torus = pm.polyTorus()
pm.polyAutoProjection( sphere[0], ibd=1, cm=0, l=2, sc=1, o=1, p=4, ps=0.2 )
pm.polyAutoProjection( cylinder[0], ibd=1, cm=0, l=2, sc=1, o=1, p=4, ps=0.2 )
pm.polyAutoProjection( torus[0], ibd=1, cm=0, l=2, sc=1, o=1, p=4, ps=0.2 )
pm.select( sphere[0], cylinder[0], torus[0] )
# Layout the UVs in a square, allow free rotations, scale uniformly
pm.polyMultiLayoutUV( scale=1, rotateForBestFit=2, layout=2 )