When working with CG renders that come with a lot of AOVs it can be quite a task going through them all and finding the ones you need to work with. I find the easiest way to do this is to use the page up/down keys with my cursor in the viewer. This cycles the viewer through all the layers that are currently connected to it.
But once you’ve found the layer you need you have to move over to the node graph, create a shuffle node, and then find the layer again in the dropdown menu in the shuffle. I found this way too many clicks, and really frustrating as I already had the layer in the viewer, so I decided it would be a good python exercise to create a script that did it for me.
The shuffleFromViewer script does three things:
1. If there are no shuffle nodes currently selected in the node graph the “Shuffle From Viewer” script (CTRL+ALT+SHIT+S) will create a new shuffle node with the first ‘in’ set to the layer currently being shown in the viewer. It will also set a label on the node that will display the layer that is set.
2. If there are shuffle nodes selected in the node graph the script won’t create any new nodes, but will change the ‘in’ on each selected shuffle to match the viewer. It won’t change the label for any shuffle nodes that already exist.
3. If you have a shuffle node selected in the node graph and run “Set Viewer From Shuffle” (CTRL+ALT+SHIFT+V) will change the layer currently being displayed in the viewer to match the ‘in’ of the shuffle node.
Here is a quick demo of it working:
You can download this tool from Nukepedia:
http://www.nukepedia.com/python/nodegraph/shufflefromviewer
or Github:
https://github.com/conradolson/nuke-tools/blob/main/shuffleFromViewer.py
To install the script, download the shuffleFromViewer.py file and move it to wherever you keep your python scripts (this is usually a folder in your .nuke folder), then make sure you add “import shuffleFromViewer” to your menu.py file.
Latest Comments