Write1 [1.0]
Write1 [12.0]
Write1 ['C:/Users/san/Modeler/']
Write1 ['png']
Write1 ['rgb']
Write1 [True]
Write2 [1.0]
Write2 [1.0]
Write2 ['']
Write2 [' ']
Write2 ['rgb']
Write2 [False]
我想做这样的字典 {'Write1':[1.0,12.0,'c:/path','png','rgb',True],'Write2':[1.0,1.0,'',' ', 'rgb',False]} 列表中的值来自 nuke.toNode(wNode)[eachAttrib].value() 这是我试图做的
attributes=[]
wnodeData={}
for wNode in writeNodes:
for eachAttrib in ['first','last','file','file_type','channels','use_limit']:
wnodeData[wNode]=attributes
attributes.append(nuke.toNode(wNode)[eachAttrib].value())