C
carlos2004
this code is part of a program, where a button send a command to capture
some images form a web cam.When the button is clicked the program will
capture 100 frames in 30 seconds and freeze the actual image, after 30
seconds we can see the image live again,
I´d like to repeat this 10 times pressing the button only one time and at
the end send a message; END.
code down....
aNY HELP....
def OnClick_500(self, evt):
start_time = time.clock()
filename = time.asctime(time.gmtime()).replace('
','_').replace(':','-')
dat = []
while time.clock() < start_time + 30:
dat.append(cam.snap())
print len(dat) , 'frames taken in 30 seconds'
dat = array(dat)
fn =
'c:/PEPE_IMAGES/'+filename+'.GIF'#time.asctime(time.gmtime())+'.GIF'
gIF.Write(dat, fn)
some images form a web cam.When the button is clicked the program will
capture 100 frames in 30 seconds and freeze the actual image, after 30
seconds we can see the image live again,
I´d like to repeat this 10 times pressing the button only one time and at
the end send a message; END.
code down....
aNY HELP....
def OnClick_500(self, evt):
start_time = time.clock()
filename = time.asctime(time.gmtime()).replace('
','_').replace(':','-')
dat = []
while time.clock() < start_time + 30:
dat.append(cam.snap())
print len(dat) , 'frames taken in 30 seconds'
dat = array(dat)
fn =
'c:/PEPE_IMAGES/'+filename+'.GIF'#time.asctime(time.gmtime())+'.GIF'
gIF.Write(dat, fn)