MIDI is a Music Interchange file format which describes music in abstract terms such as "piano key C-4 pressed down". A synthesizer is required to reproduce audible music from MIDI files. In this tool-assisted education video, I create one such synthesizer program from scratch, using the OPL3 hardware synthesizer as the backend for generating the actual sounds.
You see me type every line. The resulting program contains the rudimentary features for playing most MIDI files just fine, including the pitch slides and pans, but it lacks other special effects like vibrato, nor does it support any more tunings than the standard equal-interval mathematical tuning. It supports the loopStart/loopEnd mechanism found in authentic Final Fantasy VII MIDI files.
This is probably my best MS-DOS MIDI player so far (at least in some aspects), and I have written two. The first one, written in 1998, however eventually evolved also to convert them into S3Ms... This was also the most difficult production-for-show so far in terms of getting it right; BASIC has its own unique challenges at debugging it, and I did accidentally introduce many bugs into this program, despite writing it from a script. I did fix them too, though. But more time was consumed doing that than I had planned.
Music played during this video: - Zoolook by Jogeir Liljedalh (a few seconds in the beginning) - Predicament / Chrono Cross (BGM during programming) - Chmmr and Arilou themes / Star Control III (MIDI) - Barret and battle themes / Final Fantasy VII (MIDI) - Airship and Big whale themes / Final Fantasy IV (MIDI, sequenced by Andrew Thompson)