PIPELINE

Python

Saver tool Precomp, elements write node Render Write node
  • With this tiny path in your Autosave will be enough to be happy and safe

    idl Comp autosave after 30

    Force Comp autosave after 180

    [value root.name]-[expr int ([expr [scan [date %M] %d]%30]/3)].autosave


  • Add this in write node before Render and he will write your folder for you.

    #always nuke writes folders. put inside write node in before render import os if not os.path.isdir(os.path.dirname(nuke.thisNode() ['file'].evaluate())): os.makedirs(os.path.dirname(nuke.thisNode()['file'].evaluate()))


  • FrameHold set up as frame you are.

    nuke.menu('Nodes').addCommand('Time/FrameHold', "nuke.createNode('FrameHold')['first_frame'].setValue(nuke.frame())", icon= 'FrameHold.png')

    n.addCommand("Position_matte")
    n.addCommand("Position_Matte3D")
    n.addCommand("Position_Noise3D")
    n.addCommand("Position_Ramp3D")

    if aitoolsToolbar:
    import os
    import glob

    np= "S:/HOUSE/2D/NUKE/"
    # build a list of folders (so you can have multiple subfolders)
    includedFolders = ['templates', 'test']

    # walk thorugh the folder list and build the menu items
    for folderName in includedFolders:
    pPresets = os.path.join ( np , folderName )
    if os.path.exists(pPresets):
    for root, dirs, files in os.walk(pPresets):
    for f in files:
    fullpath = os.path.join(root, f)
    fileBits = os.path.splitext(f)
    if fileBits[1] == '.nk':
    menuItem = folderName + '/' + fileBits[0]
    pyCom = "nuke.nodePaste(r'" + fullpath +"')"
    aitoolsToolbar.addCommand(menuItem, pyCom)
     
    p = nukescripts.render_panel((nuke.thisNode(),), False)
    print p
    if p:
    node = nuke.thisNode()
    nuke.render( node, )
    print node

  • #reload fonts into Nuke
    nuke.rescanFontFolders()

    #reload python script into nuke console
    reload(python)

Nuke Tools

This a small list of the python tools that I've been working on.

Tools to have better behavior when saving or comping...


Auto write nodes for final render, precomp, elements, etc...