[vorbis-dev] Python Module

Andrew Chatham andrew.chatham at duke.edu
Wed Jan 17 09:17:24 PST 2001



I wrote a Python module. It's available at http://www.duke.edu/~ahc4/pyogg

It can currently decode and encode. I haven't wrapped the entire API, though,
since I don't necessarily understand all of it. But I was successfully able to
translate oggenc and ogg123 into Python at one point (they've since been
updated a lot).

Encoding may not be worthwhile, though. For example, if you just try to extract
the individual values from a WAV file in Python, that takes MORE CPU time than
actualaly encoding the file :) So I wrote a (simple) WAV module too.

It could certainly use some additions/suggestions, though, so if you have any,
please let me know. I've also not tried to build it on anything but my
computer. And I should write some more documentation once I understand the API
better.

I also wrote a wrapper for ao, but there are some serious problems there. In
particular, I'm new to dynamically loaded shared libraries and have some issues
there. Python loads modules with dlopen. ao opens it's plugins with dlopen. So
Python loads a shared object (aomodule.so) which is linked to a shared library
(libao.so) which loads another shared object (libesd.so, for example). But the
final shared objects can never find the symbols in libao.so. If I use the
example same code from aomodule.so but compile it into an executable, things
work fine. Either the linker or I is stupid. My money's on the latter.

Andrew

Thus spake Bernard Jauregui (Bernard.Jauregui at energis-squared.com) : 

> All (Newbie Alert)
> 
> A python interface for the Vorbis library would cheer up a lot of Python
> developers working on jukebox and streaming audio projects. I have some
> capability here, but before I start hacking around with the library:
> 
>   Has anyone else attempted a Python module?
>   Should I wait for a new cut of the code before even starting?
> 
> Cheers
> 
> BJ
> 
> -- 
> Bernard Jauregui               
> [Personal Email]
> 
> --- >8 ----
> List archives:  http://www.xiph.org/archives/
> Ogg project homepage: http://www.xiph.org/ogg/
> To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
> containing only the word 'unsubscribe' in the body.  No subject is needed.
> Unsubscribe messages sent to the list will be ignored/filtered.


-- 
Andrew Chatham
Duke University '02
andrew.chatham at duke.edu

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.




More information about the Vorbis-dev mailing list