Phoenix.pm: Playing MIDI with Perl on Windows

Chris Krum cakrum at cox.net
Wed Aug 13 21:06:10 CDT 2003


> Hey all!
>
> I'm looking for a solution to play MIDI files from Perl on Windows.  I'm
> already aware of Win32API::MIDI on CPAN, but it requires Visual C++ to
> compile, and I don't have that available.  There are other MIDI modules
> on CPAN, but they appear to be concerned with generating/reading/munging
> MIDI.  I was wondering if there is a way to do it using Win32::OLE.  I'm
> woefully (or blissfully) ignorant of the Windows API, so any ideas are
> appreciated.  Thanks!
>
I'm also interested in playing midi from perl. Here are a few questions to
help me understand your situation better.

Does this have to be a pure perl solution? Could you use a rendering engine
like Timidity++ to render the midi to a wave file and output that to the
soundcard? Are you restricted to midi or could you use something like SAOL?
Is your app generating the midi files or does it pull them from a file
system somewhere? Do you need to play the midi notes in realtime (like
creating your own midi instrument) or are they stored in files and played
back later?

Regards,
Chris.




More information about the Phoenix-pm mailing list