2006-03-02

MIDI to WAV conversion

Situation:
I was having a couple of MIDI files that I wanted (needed) to put on music CD's. My way was to convert them first to wav or mp3 files, prior to putting them on CD using a program like Ahead Nero (you can find it if your writer was not providing it).

Tools:
TiMidity++ is a converter that converts some MIDI files into audio-files (like RIFF WAVE).

These Distributions came with an "enough" configured timidity-package out of the box:

  • SuSE 9.0 (YaST - Software - timidity)
  • Debian 3.1a (apt-get install freepats timidity timidity-interfaces-extra)

If you have a TiMidity installation that's well-configured (capable of playing a midi-file on your (linux-) system), you'll be able to use it to save wav files.

Short way:

timidity --output-mode=w --output-file=result.wav source.mid

Long way:
You can first check your player, if at least it produces correct audio (through the speakers of the system) by executing

timidity source.mid

If this doesn't produce correct (evt. musical) sound, you should check the configuration of your timidity, prior to continuing here.

Using this command-line instruction, you create the wav file of the a midi file.

timidity --output-mode=w --output-file=result.wav source.mid

I use to reduce size of the files:

timitidy --sampling-freq=16000 --output-mode=w --output-file=result.wav source.mid
If I want only one single voice (or mute some channels), I use:
timidity --mute=0,-4 --output-mode=w --output-file=result.wav source.mid
This previous example mutes all voices (0) and then de-mutes voice 4 (in my case almost always the bass-line).

Labels: , , ,

0 Comments:

Post a Comment

<< Home