[fpc-pascal] MIDI & Kylix

Peter H.M. Brooks peter at new.co.za
Thu Jan 13 20:38:19 CET 2005


Pedro Lopez-Cabanillas wrote:

>I've wrote a translation of ALSA's library headers to Pascal. It has support 
>for Linux only, and it can be used with Kylix and FPC compilers. 
>
>If you want to work with MIDI files only, but not to play or record sequences, 
>you can download this file:
>http://perso.wanadoo.es/plcl/ametro/ametro-0.4.tar.bz2
>
>Inside the tarball you will find a directory named musicobjects/ and inside it 
>there is a file "smf.pas", a Standard Midi File unit, that allows you to read 
>and write MIDI files. The metronome program itself does not uses this unit, 
>though. This directory is a set of components for Kylix and Lazarus that I 
>would like to distribute some day as a standalone project, if I could find  
>some time to test, to write the documentation and to create the packages.
>  
>
I've been enjoying looking through these. Your smf.pas unit looks 
perfect for my requirements - it's nicely put together.

I'm using fpc, not kylix, and I it chokes over the variable length array 
"fred : array of byte" is illegal in fpc, but presumably fine in Kylix.

Have you got a version that has compiled in fpc? I've tried setting the 
Delphi compatability switches but it doesn't help. I could set it up as 
a fixed length array and modify the code where necessary, but, if you do 
have a version that works with fpc then I'd rather use that!

While I'm asking, I don't suppose that you have a sample program that 
uses the unit, do you? It isn't, of course, necessary, but it would be 
nice to see, if you have one.






More information about the fpc-pascal mailing list