Nuke Script : Breakdown Helper

Hey Guys!

So here’s something I know you’ll like.
So you’ve got this awesome script in Nuke all done up and pretty and now all you gotta do is make up breakdowns to show off to the Big Guys. So you begin going through each node, double-clicking, going into the ‘node’ tab, set key on disable, more ahead a frame, then check the box, move to the next node and repeat.


Well guess what? This little guy does that for you.


How it works is it calls for what frame you’re on, called currentTime. Then it declared that newTime is just the current frame +1… Not too bad… Then it says for every ‘disable’ knob in the nodes you have selected, set a key on the current frame for the box being unchecked, and the next frame to be checked, then move ahead one frame. Just run this script on a selected node, go to another node and run, another node and run, etc… So that’s about it!


Stay tuned for more little guys like this, and who knows? I might write one that will set keys in order of selectedNodes… In time.

currentTime = nuke.frame() ### set current frame
newTime = currentTime + 1 ### set variable for next frame
for i in nuke.selectedNodes(): ### for every knob in selectedNode
  i['disable'].setAnimated() ### make disable animated
  i['disable'].setValueAt(0, currentTime) ### 'disable' value of 0 = box unchecked
  i['disable'].setValueAt(1, newTime) ### 'disable' value of 1 = box checked
  nuke.frame(newTime) ### go to next frame


### If you messed up, go to frame you started breakdowns at and run this
### script to clear all animations on 'disable'

for i in nuke.selectedNodes(): ### for every knob in selectedNode
  i['disable'].clearAnimated() ### clear animations on 'disable'