|
### How to convert a MIDI file to WAVe? ###
MIDI files are great. They contain "real" music instructions, which makes them the most efficient way of storing music. However, in many applications, MIDI is unusable, because of lack of support. It is often usefull to be able to take a MIDI file, and convert it to a WAVe (for example to convert it even further, into MP3, Ogg, ulaw, or whatever).
On the Linux platform, there is a great MIDI player, which is hardware-independant (does not use MIDI capabilities of the soundcard), and allows the conversion of MIDI files to WAVe.
timidity filein.mid -Ow -s 48000 -o fileout.wav
By default, the quality of the MIDI synthesis with Timidity is pretty bad. That's because at default installation, Timidity uses some minimalistic instrument sets. To improve your MIDI experience, I highly recommend using additional instrument sets. "How to do that?", you will say?
Here we go:
On my system, the configuration for Timidity is stored in /usr/share/timidity/timidity.cfg (as my /etc/timidity.cfg contains only a "source /usr/share/timidity/timidity.cfg" instruction).
There, I removed default instrument (as these are providing a really crappy sound):
#source piano+guitar.cfg
#source drums.cfg
...and I added an alternative soundfont using such line:
soundfont /usr/share/timidity/merlin_vienna.sf2
(Obviously, I had to copy this new soundfont to /usr/share/timidity/ first, you will have to look on the net after alternative soundfonts).
=== Attachments ==========================================
|