On 11/24/2017 01:40 PM, Daniel Gillet wrote:
​Hello,

Thank you for trying out the new version. This is an interesting use case you're describing. My first thought on this was : why bother splitting the audio file into 2 files? You could just override the Player on_eos method to seek back to where you want.

class LoopPlayer(Player):
     offset_start = 20 # Intro is 20 seconds
     def on_eos(self):
         if self.loop:
             self.seek(LoopPlayer.offset_start)
         else:
             self.next_source()​

I can only assume the playback needs to be gap-less, so the looping needs to be scheduled in advance.

--
You received this message because you are subscribed to the Google Groups 
"pyglet-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/pyglet-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to