[Tutor] Python audio help needed
Michael Lange
klappnase at freenet.de
Sat Oct 18 09:08:47 EDT 2003
On Sat, 18 Oct 2003 00:19:24 +0200
Tim <tim.ronning at start.no> wrote:
> Hello list, and greetings from Norway
>
> I'm new to this list and to Python (obviously since I'm asking questions
> here..)
>
> In paralell with learning from books, online training, etc, I have also
> started my own little project. I want to build a dead simple mp3 player
> using pymad (libmad) library and PyQt when I get the basics to work.
>
...
>
> Can anyone help me out here. Is there an ALSA audio module out there
> somewhere? Or should I set some other value to setfmt() All help is greatly
> appriciated.
>
> Best regards
> Tim
Hi Tim,
maybe you should try tkSnack : www.speech.kth.se/snack
Snack supports both OSS and ALSA (however, when I tried to compile the sources with "--enable-alsa" option it did NOT work,
but compiling without I have no problems using ALSA).
Snack's usage is quite simple and file formats are recognized automatically by the filename extension, so it is fairly easy to
play mp3 files:
import tkSnack
s = tkSnack.Sound(file='somefile.mp3')
s.play()
This way you can even play large files(bigger than system memory.
I hope this helps.
Cheers
Michael
More information about the Tutor
mailing list