​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()​

But then I can see that it might be useful to have a loop attribute on each
Source in the PlayList. Without external intervention this Source would
loop, unless Player.next_source() is called.

If we go down this route, I presume that the Player.queue signature would
become something like Player.queue(source, loop=False). Would this meet
your expectations? Do you have a better idea?

-- 
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