SyntaxHighlighter

2013年7月9日火曜日

メモ_配列の場合の表記

for b in  nuke.allNodes('Transform'):
    b.knob('center').setValue((640,512))

for b in  nuke.allNodes('Crop'):
    b.knob('box').setValue((((0,-10,1280,1034))))

sn = nuke.selectedNodes()
for n in sn:

    n.knob('box').setValue((((0,0,1280,1024))))

- pass the value argument as a tuple: 

nuke.toNode("Transform1").knob("center").setValue((0, 1080)) 

- or set the value for each index separately 

nuke.toNode("Transform1").knob("center").setValue(0,0) 
nuke.toNode("Transform1").knob("center").setValue(1080,1) 


0 件のコメント:

コメントを投稿