[python-win32] Python sound playback threading control?

Tim Roberts timr at probo.com
Wed Feb 13 20:51:45 CET 2013


Jacob Kruger wrote:
>  
> However, what it comes down to is to wanting to make it possible to
> sort of
> bypass something like current sound playback, or interrupt it, and
> re-initiate the playback for the same object/sound file, etc

It depends on what APIs you're using to play the sound.  Often, you're
feeding the sound in buffer by buffer, so stopping the playback is just
a matter of telling your own sound thread to stop sending buffers.

If you're using some other higher-level API where you just deliver a WAV
file, then you'll need to check out the facilities in that API.

-- 
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.



More information about the python-win32 mailing list