Replace procedural Nuke Write paths with real paths in write node by replacing the write node(s)


/ Published in: Python
Save to your folder(s)

This allows you to take a node that has expressions in it and create copies of them that are hard pathed. It will also disable said expression driven write nodes and disable them.


Copy this code and paste it in your HTML
  1. import nuke
  2.  
  3.  
  4. for n in nuke.allNodes('Write'):
  5. print nuke.filename(n)
  6. nodeInput = n.dependencies()
  7. newWrite = nuke.nodes.Write(file=nuke.filename(n))
  8. newWrite.setInput(0,nodeInput[0])
  9. n.knob('disable').setValue(1.0)

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.