Quick Tip: Easily create legacy nodes via the Script Editor

Categories Python, Quick Tip

Updated nodes in Nuke should be better than their predecessors, although that’s not always the case. For example, I love that the latest VectorBlur node is GPU-accelerated, although I find it’s output quite arbitrary; it never does what I expect out of the box, and I personally prefer the old version.

A problem arises here, because the old VectorBlur is no longer in our menus. The good news is we can still access legacy nodes via the script editor!

nuke.createNode(“VectorBlur”) creates the old one.
nuke.createNode(“VectorBlur2”) creates the new one.

If this is something you do all the time, you’re able to add the old nodes back into the Nodes menu, by placing the following code into your menu.py:

nuke.menu(‘Nodes’).addCommand(“Filter/VectorBlur Old”‘nuke.createNode(“VectorBlur”), icon=“VectorBlur.png”)

In English, this is looking for the Nodes menu, then is adding an item we’re calling VectorBlur Old, to the menu named Filter (if you want to create a new menu, type a name that doesn’t exist). The second part of the code is our same nuke.createNode() function. Finally, the last part is setting an icon for the menu — we’re just using the existing icon for VectorBlur.