This command will set the passID of a renderPass node and create the custom attributes specified by the corresponding render pass definition. If the render pass node already has a passID assigned to it, attributes that are no longer required become hidden, and new attributes are unhidden and/or created as needed. This allows passIDs to be changed back and forth without losing attribute data. It also allows common attributes to be transported from one render pass type to another.
Long name (short name) | Argument Types | Properties | |
---|---|---|---|
defaultDataType (d) | bool | ![]() |
|
|
|||
numChannels (n) | int | ![]() |
|
Specify the number of channels to use in the render pass. Note that this flag is only valid if there is an implementation supporting the requested number of channels. Flag can have multiple arguments, passed either as a tuple or a list. |
|||
type (t) | unicode | ![]() |
|
|
Derived from mel command maya.cmds.setRenderPassType
Example:
import pymel.core as pm
# create a render pass for diffuse reflection
#
pm.createNode( 'renderPass', name='myDiffusePass' );
pm.setRenderPassType( 'myDiffusePass', type='diffuse' );
true