Nuke tmp

From Antoine Vienne | Wiki
Revision as of 01:33, 6 December 2019 by Walter (talk | contribs) (Created page with "=Maya tmp Scripts= === Nuke - Extract some images from Read === <pre> nodes = nuke.selectedNodes() for node in nodes: if node.Class() == 'Read': oPath = node['fil...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Maya tmp Scripts

Nuke - Extract some images from Read

nodes = nuke.selectedNodes()
for node in nodes:
    if node.Class() == 'Read':

        oPath = node['file'].value()
        first = node['first'].value()
        last = node['last'].value()
        oFrameHold = nuke.allNodes('FrameHold')

        channels = node.channels()
        layers = list( set('1234') )
        layers.sort()
        readPath = node['file'].evaluate()
        readPath = os.path.splitext(readPath)[0]
        print(readPath)
        if 'rgba' in layers:
            layers.remove('rgba')
        for n in layers:
            shuffleNode = nuke.nodes.FrameHold(inputs=[node])
            shuffleNode['first_frame'].setValue(last/2)