Skip to content

Modifying VGM's for tempo

Technical discussion about the VGM format, and all the software you need to handle VGM files.

Moderator: Staff

  • SirDarwin Offline
  • Posts: 5
  • Joined: 2022-10-08, 22:06:56

Modifying VGM's for tempo

Post by SirDarwin »

I'd like to know if there's a way to modify VGM's to be playable (or played back by default) at a different tempo or to extend the fading point. For example:

I'm trying to play back the Sonic 2 ending theme at 82.21% speed (one of foobar's intervals). Problem is this is a song that doesn't loop, but it fades out before it finishes.

The closest thing I could find was vgm_ptch for patching it and it seemed like it might have had the right tools. But whenever I press any key in the window it closes.

I apologize if this is a commonly asked question or if I'm missing something very obvious...

Post by Soundshock »

If the fadeout is hard coded I don't think there's anything you can do. Maybe you could manually loop it?

vgm_ptch usage is "vgm_ptch -command:value file.vgm". all -SetRate does is set the rate setting in the header at 0x24, which is used in conjunction with the playback rate option in the player (PlaybackRate in vgmplay). Internally the player runs at 44100 samples per second so to get the most precision write 44100 to 0x24 then set PlayBackRate to some integer division of that. To hard code it You'd have to resample the vgm, idk if such a tool exists
Post Reply