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

Synopsis

swatchRefresh()

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

swatchRefresh is NOT undoable, NOT queryable, and NOT editable.

The swatchRefresh command causes image source node swatches to be refreshed on screen. The purpose of this command is to provide a mechanism to trigger a swatch refresh in cases that are not subject to dirty propagation in the dependency graph. This command only works with imageSource-derived node types. Invoking this command with no arguments will cause all imageSource swatches to be refreshed.

Return value

booleantrue if all arguments are valid image source nodes and the operation succeded.

Keywords

swatch, renderPass, renderLayer, renderTarget

Python examples

import maya.cmds as cmds

# Refresh the swatch for the layer1 node
cmds.swatchRefresh('layer1')