from nukescripts.panels import PythonPanel
class test(PythonPanel) :
def __init__(self,title,id):
PythonPanel.__init__(self,title,id)
self.but=nuke.PyScript_Knob('button','button')
self.addKnob(self.but)
def knobChanged(self,knob):
self.flip()
def flip(self):
nukescripts.flipbook(nukescripts.framecycler_this, nuke.selectedNode(), ("1,5", ["main"]) )
then instantiate the panel using :
m=test('testpanel','123')
m.show()
select any node to render (in my example i select a Colorbar Node) ,then press the button, i got bunch of error messg, the last line said :
ValueError: ColorBars1.first_frame cannot be turned into a number
the script is working fine, as i tested on script editor without problem, the code below is working perfectly :
m.flip()
So the problem i cannot call the ‘nukescripts.flipbook()’ function by using the panel. Anyone got the solution?
thanx
Post a Comment