pymel.core.rendering.assignViewportFactories

assignViewportFactories(*args, **kwargs)

Sets viewport factories for displays as materials or textures. In query mode, return type is based on queried flag.

Flags:
Long name (short name) Argument Types Properties
materialFactory (mf) unicode ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
 
Set or query the materialFactory for the node type.
nodeType (nt) unicode ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
 
The node type. Flag can have multiple arguments, passed either as a tuple or a list.
textureFactory (tf) unicode ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
 
Set or query the textureFactory for the node type.

Derived from mel command maya.cmds.assignViewportFactories

Example:

import pymel.core as pm

# To set the viewport factories for all dgs_material nodes.
#
pm.assignViewportFactories( materialFactory='MentalRayMaterial', textureFactory='MentalRayTexture', nodeType='dgs_material' )

Previous topic

pymel.core.rendering.ambientLight

Next topic

pymel.core.rendering.batchRender

Core

Core Modules

Other Modules

This Page