I was trying to play scummvm with alsa, and I coudlnt get it to play midis.. So I did a Little research, and found this. He did an excellent job at adding midi in hoary, so this is kind of a translation and a bit of fix.
- Install timidity & pmidi:
Code:sudo apt-get install timidity pmidi and add the following lines:Code:sudo gedit /etc/modulesCode:snd-seq-device snd-seq-midi snd-seq-oss snd-seq-midi-event snd-seq- Download the Unison Soundfont:
Code:wget ftp://ftp.personalcopy.net/pub/Unison.sf2.gz- Extract it to /etc/sounds:
Code:sudo mkdir /etc/sounds/ tar -xzf Unison.sf2.gz mv Unison.SF2 Unison.sf2 sudo mv Unison.sf2 /etc/sounds/ It should look like this (No more, no less):Code:sudo gedit /etc/timidity/timidity.cfgCode:soundfont /etc/sounds/Unison.sf2 variable TIM_ALSASEQPARAMS (variable 22 I think), should look like this:Code:sudo gedit /etc/init.d/timidityCode:TIM_ALSASEQPARAMS="-iA -B2,8 -Os1l -s 44100" Uncomment the two TIM variables. It should look like this:Code:sudo gedit /etc/default/timidityCode:# Defaults for TiMidity++ scripts # sourced by /etc/init.d/timidity # installed at /etc/default/timidity by the maintainer scripts # $Id: timidity.default,v 1.3 2004/08/07 14:33:26 hmh Exp $ # # This is a POSIX shell fragment # # Enable MIDI sequencer (ALSA), default is disabled TIM_ALSASEQ=true # Setting overrides (of /etc/timidity.conf) for the ALSA sequencer daemon TIM_ALSASEQPARAMS="-iA -B2,8 -Os1l -s 44100"
Add the following line (A good idea is to add it after line 9):Code:gedit ~/.bashrcCode:export ALSA_OUTPUT_PORTS="128:0"- Done! Now you can play midis with pmidi. Like this:
If it doesnt work, reboot (just to be sure... Damn windows tick!)Code:pmidi Song.mid
Bonus: SCUMMVM
Now you can play scumm vm through alsa! Just follow these steps:
Add the following line (Again, after line 9 is a good idea):Code:gedit ~/.bashrcCode:export SCUMMVM_PORT=128:0- (If you want to create a launcher)
Add the folowing lines:Code:gedit ~/.gnomercCode:export ALSA_OUTPUT_PORTS="128:0" export SCUMMVM_PORT=128:0- In scummvm, go to options, audio, music driver: ALSA
Good luck.
PD: Thanks to:
- http://www.ubuntu-es.org/node/3777
- http://www.ubuntulinux.org/wiki/Midi...SynthesisHowTo
- http://www.personalcopy.com/home.htm
- http://ubuntuforums.org/showthread.p...light=timidity
Note: I think Ubuntu should have MIDI support by default
Bookmarks