vgmsplitter

I have been getting into playing music lately. A particular interest of mine is video game music, which tends to be covered less frequently than mainstream top-40 stuff. When transcribing music, it is helpful to be able to hear each instrument individually. This is rarely possible with most music, which can have a lot happening at once, but it is possible for VGM.

With video game music, particularly for older consoles, there exist a variety of technologies for ripping the contents of a game’s soundtrack. The resulting files are generally very small (under 100kb in many cases), but are more complex than an mp3 to play back, because they are essentially rips of RAM contents for their respective consoles’ sound chips. The software that can play such a file is generally a small emulator of that sound chip. This means that the music is effectively synthesized in real time, allowing for changes to the tune’s tempo, muting of certain voices, and other modifications.

I thought it would be useful to whip up a utility that can process a track and split it into WAV files each containing a single voice of the track. The result, which I called VGMSplitter, is on my Github. It’s not pretty: a horrific mishmash of C and C++, and ultimately pretty damning evidence against the idea that I can write in either language. It’s my first project in C++ written for an x86 processor since university, and I found myself shocked at the amount of effort necessary to do something as simple as iterating over the contents of a directory. Java has spoiled me.

VGMSplitter uses a library called game-music-emu for the emulation/playback. It’s also probably not going to run on Windows, yet. When I figure out how to write C/C++ directory manipulation calls for Windows, I’ll probably fix that.