コマ落としとバレ消しの注意書き
import nuke
readNodes = nuke.allNodes("Read")
for node in nuke.allNodes():
node["selected"].setValue(0)
#print node
for read in readNodes:
read["selected"].setValue(1)
first = read["first"].getValue()
last = read["last"].getValue()
timeWarp = nuke.createNode("TimeWarp")
timeWarp["lookup"].setAnimated(0)
timeWarp["lookup"].animations()[0].setKey(first, first)
timeWarp["lookup"].animations()[0].setKey(last, last)
if first%2 == 0:
timeWarp["lookup"].setExpression('(int(curve/2))*2')
else:
timeWarp["lookup"].setExpression('((int((curve+1)/2))*2)-1')
NoteOfCaution = nuke.nuke.createNode("Text2")
NoteOfCaution["message"].setValue('バレ消しの必要はありません')
NoteOfCaution["font"].setValue("Adobe Gothic Std", "B")
NoteOfCaution["font_size"].setValue(72)
if first%2 == 0:
NoteOfCaution["opacity"].setExpression('(frame%2)')
else:
NoteOfCaution["opacity"].setExpression('((frame+1)%2)')
read["selected"].setValue(0)
timeWarp["selected"].setValue(0)
NoteOfCaution["selected"].setValue(0)
0 件のコメント:
コメントを投稿