VGM Tools
Command-line tools for working with VGMs, created/maintained by Valley Bell. For further information on each tool, see the individual pages linked below, or the Readme in the GitHub source repository.
Visit the official release thread to check for binary build updates and post feedback. The current binary builds of the tools are from 2022, and missing the most up-to-date fixes and features.
See the instructions under #Compiling below to make sure you have the most complete builds of the tools. This will also give you the tools marked (New), which have been added after the most-recent official binary-build release.
| Program | Description |
|---|---|
| vgm_cnt | VGM Command Counter |
| vgm_dscmp (New) | VGM Directory Size Compare |
| vgm_stat | VGM Statistics |
| vgm_vol | VGM Peak Volume Detector |
| vgm2txt | VGM Text Writer |
| Program | Description |
|---|---|
| vgm_sptd | VGM Splitter (Delay Edition) |
| vgm_spts | VGM Splitter (Sample Edition) |
| vgm_trim | VGM Trimmer |
| vgmlpfnd | VGM Loop Finder |
| Program | Description |
|---|---|
| vgm_ren | VGM Renamer |
| vgm_tag | VGM Tagger |
| vgm_tt | VGM Tag Transfer |
| Program | Description |
|---|---|
| opt_oki | VGM OKIM6258 Optimizer |
| optvgm | Optimize Sega Mega Drive/Sega Genesis VGM/VGZ |
| optvgmrf | VGM RF-PCM Optimizer |
| vgm_cmp | VGM Compressor |
| vgm_dbc | VGM Data Block Compressor |
| vgm_dso (New) | VGM DAC Stream Optimizer |
| vgm_smp1 | Remove 1 Sample Delays |
| vgm_sro | VGM Sample-ROM Optimizer |
| Program | Description |
|---|---|
| vgm_ndlz | VGM Undualizer |
| vgm_ptch | VGM Patcher |
| vgm_mono (New) | VGM Mono-izer |
| vgmmerge | VGM Merger |
| Program | Description |
|---|---|
| dro2vgm | DRO to VGM Converter |
| imf2vgm (New) | IMF to VGM Converter |
| opl_23 (New) | OPL 2<->3 Converter |
| raw2vgm (New) | RAW to VGM Converter |
| Program | Description |
|---|---|
| dacopt | VGM DAC Optimizer (created for Worms and only used for Worms) |
| optdac | VGM DAC Optimizer (must be used with caution) |
| optvgm32 | VGM PWM Optimizer (currently doesn't work) |
| vgm_facc | Make VGM Frame Accurate (specific to SMS/GG VGMs logged using Kega Fusion. These packs are out-of-scope for VGMRips.) |
If you do not see a listed tool in either the official binary releases or in the "build" folder after compiling, the tool requires special knowledge to use or is not yet usable. It's unlikely you'll need it in 99% of cases.
vgm2mid, and info on its Sphere Edition by NeoLogiX, were formerly included on this page for historical reasons. All this information has been moved to its own page, since this program is not really one of the Tools.
Compiling the tools
- Install CMake
- Download https://github.com/vgmrips/vgmtools/archive/refs/heads/master.zip
- Unzip it somewhere convenient/where you can freely edit files, so you end up with a new folder "vgmtools-master"
- Inside the vgmtools-master folder, do one of the following:
- Create and run a file with the four commands after this list placed inside it. Depending on your Operating System, the file should be named:
- build_vgmtools.bat (on Windows)
- build_vgmtools.sh (on Linux)
- Open a command line/terminal and, inside that, enter the four commands below in order
- Create and run a file with the four commands after this list placed inside it. Depending on your Operating System, the file should be named:
mkdir build cd build cmake .. make
Detailed info for power users
Building the tools should work with most compilers that support C90 and C++98. This has been tested with various versions of GCC and MS Visual Studio. Building with Visual Studio will require manually building zlib first.
The source is best viewed with 4-space-sized tabs.
The released binaries are built with MS VC++ 6.0.
Basic Usage
For most of the tools, you can specify an output file:
tool.exe "input.vgm" "output.vgm"
If any tools are not working, make sure either of these is true:
- There's no spaces in the path (folders + filename). E.g.,
C:/folders/containing/vgms/example.vgm. - If there are spaces, that the path is surrounded by quotes. E.g.,
"C:/vgms/another example.vgm".
Or, you can drag and drop your files directly onto the tools.
Some tools, like vgm_ptch and vgm_tag, accept and can modify multiple files. Others, like vgm_cnt, only process one file per launch, even if you drop more than one. See the wiki pages linked above for each tool for specific information, including per-tool options.
Other Tools by NeoLogiX
- vgm2pre
vgm2preis a program to save instrument presets from VGMs to formats usable in various trackers and sequencers. It currently dumps FM presets from VGMs with YM2612 data.- YM2612 FM presets can be dumped to VGI, TFI, TYI, EIF, DMP, Y12, and GYB formats.
- VGMTool v3
- source
- As early as 2012 NeoLogiX announced plans to completely revamp VGMTool for modern systems with the goal of making the codebase easier to update and maintain than the original Win32-only VGMTool source. Though he released screenshots of work-in-progress to garner attention and has uploaded source code to it, development is not complete. Release date is currently unknown.
History
Over the years various programs have been written to work with different aspects of VGM files, beginning with the original all-in-one VGMTool by Maxim. An update to the original VGMTool (tagged as version 2R6) was released by NeoLogiX to resolve YM2612 and YM2151 processing issues, but was found to have numerous other bugs (including buggy support for the particular UTF-16/UCS2 used for GD3 tagging) that rendered it unsuitable for widespread use. Today, Maxim's VGMTool is only suitable for tagging VGMs.
Blargg's optvgm, as updated by Valley Bell, is still used today for YM2612 VGMs.
Valley Bell currently releases the most up-to-date tools for working with VGMs, though they are all command-line.