[Tutor] Re: Python audio help needed

Lee Harr missive at hotmail.com
Sat Oct 18 09:24:45 EDT 2003


>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.
>
>I started out with this little script, supplied by the author to show how
>to use pymad.
>
>#!/usr/bin/env python
>import mad, ao, sys
>mf = mad.MadFile(sys.argv[1])
>dev = ao.AudioDevice('oss', rate=mf.samplerate())
>while 1:
>    buf = mf.read()
>    if buf is None:
>        break
>    dev.play(buf, len(buf))
>
>My first problem, I don't have module ao! Couldn't find on the net so I'm
>trying to acomplish the same with module ossaudiodev. After some study in
>the Python docs I now have this script.
>


http://www.google.com/search?q=python+audio+ao
http://www.freshports.org/audio/py-ao/
http://www.andrewchatham.com/pyogg/

_________________________________________________________________
The new MSN 8: smart spam protection and 2 months FREE*  
http://join.msn.com/?page=features/junkmail




More information about the Tutor mailing list