Saturday, January 08, 2005

ABC Music Notation File Format

Just the other day, I became aware of a terrific music file format called ABC. Apparently, it's been around for a many years, but I didn't even realize it existed. I haven't spent a lot of time using it, but so far it seems pretty cool.

It reminds me of GWBASIC/QBASIC's PLAY command, but ABC is much more powerful. Apparently, it was originally created to describe traditional music (melody-only). Fortunately for piano and ensemble enthusiasts, extentions have been added to allow polyphonic harmony.

There are various freeware and Open Source programs out there that support ABC. Many of them haven't been updated recently, but I've found that they still work pretty well (some patience and trial-and-error is required, though). The open-source program iabc tries to bring together many functions under one roof, but I had trouble getting it to work right. There are some shareware and commercial programs that allude to fancy GUI editors and integrated approaches, but I haven't checked them out yet.

Home Pages
Command-line program websites:
  • abcMIDI: converts ABC Music (.abc) into MIDI Music (.mid) files
  • abcm2ps: converts ABC Music (.abc) into a PostScript (.ps) document
  • Ghostscript: converts PostScript (.ps) into Portable Document Format (.pdf)
John Chambers' tutorial: Steve Mansfield's tutorial: BarFly's comparison of multivoice extentions

Sample Windows batch file to produce a MIDI and a .ps file:
set abcfile=i:\media\midi\mysong
erase %abcfile%.mid
cd \prgfiles\abc\abcm2ps
abcm2ps.exe %abcfile%.abc
copy out.ps %abcfile%.ps
cd \prgfiles\abc\abcmidi
abc2midi.exe %abcfile%.abc -o %abcfile%.mid
pause

No comments: