Gorka Olaizola wrote: > Hello, > > I'm trying to play various videos with kaa.popcorn one after each other. > I want also to start the next video when the user hits the spacebar. > With the mplayer backend it works but the window flickers between > videos. I've seen that the same behaviour is present in Freevo2 so I > think it's mplayer's fault. > > I've tried then with the xine backend but I get the following traceback > randomly. Attached is the program I coded so far. > > To run just do > > video2.py ~/videos/*.avi > > and press spacebar to start watching the next video or get the traceback
Should be fixed. BTW, maybe open fails and in that case you do not want to call play (it makes no sense). So better use the coroutine decorator. | @kaa.coroutine() | def next(self, id): | fname = self.fnames.pop(0) | print 'play %s with %s' % (fname, id) | yield self.player.open(fname, player=id) This now blocks until the stream is open or you get an exception. After that call play: | self.player.play() No return allowed, return your result with yield | yield True Dischi -- As far as we know, our computer has never had an undetected error. ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Freevo-devel mailing list Freevo-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freevo-devel