looking for win32 (or cross-platform) midi module

Alex Martelli aleax at aleax.it
Sun Aug 3 17:32:10 EDT 2003


dan wrote:

> Max M <maxm at mxm.dk> wrote in message news:<3F2B84C9.5050507 at mxm.dk>...
>> dan wrote:
>> > is there anything like the nice midipy.pyd, but up to date (ie works >
>> > 2.0)???
>> 
>> 
>> No
>> 
>> regards Max M
> the website (http://www.josos.org/midipy/) says:
> 
> "MidiPY - real-time MIDI input module for python (win32) - If someone
> can compile for newer python versions, please!"
> 
> So modules need to be recompiled every time a major release comes out?

On Windows, yes.  Each .PYD refers to the specific python DLL it was
compiled for, e.g. PYTHON20.DLL, so if you're using PYTHON22.DLL or
whatever other than PYTHON20.DLL you'll indeed need a recompile.  On
other architectures, not necessarily.

>  There's a .cpp file in midipy.zip but no instructions, makefile,
> includes, project files etc.

I think you mean midipy20.zip (the apparently slightly older midipy.zip
which can also be found on the net has a .pyd and a readme, while the
midipy20.zip adds a .cpp as well).

Unfortunately, to rebuild that cpp you apparently also need the "OSC
library" presumably from:

http://www.pvv.org/cgi/thammer/soundlink_download2.pl/http://www.pvv.org/~thammer/localfiles/software/osc11.zip

[looks like a strange URL but it's the one I found on that "hammer"
site] or perhaps an earlier version (I wouldn't know).  Once you do
have that, rebuilding the .pyd from the .cpp shouldn't be any harder
(assuming you do have VC++ 6 installed) than writing and using the
usual setup.py file for extension building, as documented on the
Python online manuals and elsewhere.


Alex





More information about the Python-list mailing list