pymel.core.modeling.polyDuplicateAndConnect

polyDuplicateAndConnect(*args, **kwargs)

This command duplicates the input polygonal object, connects up the outMesh attribute of the original polygonal shape to the inMesh attribute of the newly created duplicate shape and copies over the shader assignments from the original shape to the new duplicated shape. The command will fail if no objects are selected or sent as argument or if the object sent as argument is not a polygonal object.

Flags:
Long name (short name) Argument Types Properties
removeOriginalFromShaders (ros) bool ../../../_images/create.gif
 

Used to specify if the original object should be removed from the shaders (shadingGroups) that it is a member of. The shader associations will get transferred to the duplicated object, before they are removed from the original. If this flag is specified then the original polygonal object will be drawn in wireframe mode even if all objects are being drawn in shaded mode.

renameChildren (rc) bool ../../../_images/create.gif
 

rename the children nodes of the hierarchy, to make them unique.Flag can appear in Create mode of commandFlag can have multiple arguments, passed either as a tuple or a list.

Derived from mel command maya.cmds.polyDuplicateAndConnect

Example:

import pymel.core as pm

pm.polyDuplicateAndConnect( 'pPlane1' )

Previous topic

pymel.core.modeling.polyDelVertex

Next topic

pymel.core.modeling.polyDuplicateEdge

Core

Core Modules

Other Modules

This Page