Hi, sorry if I missed something in the docs, but I can't get MIDI music working at all in Linux. I've tried using all 3 sound drivers (-sndoss/-sndalsa/-sndsdl ...not all at once obviously), a variety of sample rates, the binary downloads, compiling my own with the uhexen2-sdlmixer-test3.diff patch, etc. etc. but nothing seems to be working.
Sound effects work fine, and the soundinfo console command always prints the expected results. I get console messages saying that midi music is starting (i.e. "Extracting casa3.mid from pakfile; Started music casa3.mid") and I get a file tmpmusic.mid left in my .hexen2 directory when I exit, that I can play with timidity from the command-line. But nothing in game.
Anything to help would be appreciated.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Did you compile SDL_mixer by yourself or do you use
a package provided by your distro? The problem may
be that SDL_mixer cannot locate timidity.cfg . On my
distro, it is under /etc, like /etc/timidity.cfg
IF you are compiling SDL_mixer by yourself and it
cannot find timidity.cfg, then edit timidity/config.h in
the SDL_mixer source before compiling and make sure
that CONFIG_FILE definition matches the location on
your disk.
(BTW, music volume is not 0 in hexen2, is it?)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
OK, you pointed me in the right direction. SDL_mixer is a distro package but timidity was a user-compiled package, and the instruments aren't in /usr/lib/timidity where SDL_mixer thinks they should be. A whole lot of symlinking more or less fixes things temporarily, and in the meantime I'm going to look for a better timidity package, or just compile it myself maybe :p
Thanks!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Just a follow up now that I understand what's going on a bit better. Hopefully this will help anyone else having a problem with music:
SDL_Mixer uses it's own internal version of Timidity, but still reads from /etc/timidity/timidity.cfg . If the instruments aren't where SDL_Mixer's Timidity expects (/usr/local/lib/timidity by default) then you need a line in timidity.cfg that points to them, i.e:
Unfortunately the version of Timidity used by SDL_Mixer is kind of old and doesn't support things like reverb or soundfonts :/
Thus my next question, any possibility for HoT to use an external Timidity in the future? (I realize this isn't exactly high priority :P)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
As for using a newer version of timidity, no it isn't a high priority ;)
But, I may want to use an internal version of timidity if only to
properly support midi music when using sdl audio and/or drop the
SDL_mixer dependency.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi, sorry if I missed something in the docs, but I can't get MIDI music working at all in Linux. I've tried using all 3 sound drivers (-sndoss/-sndalsa/-sndsdl ...not all at once obviously), a variety of sample rates, the binary downloads, compiling my own with the uhexen2-sdlmixer-test3.diff patch, etc. etc. but nothing seems to be working.
Sound effects work fine, and the soundinfo console command always prints the expected results. I get console messages saying that midi music is starting (i.e. "Extracting casa3.mid from pakfile; Started music casa3.mid") and I get a file tmpmusic.mid left in my .hexen2 directory when I exit, that I can play with timidity from the command-line. But nothing in game.
Anything to help would be appreciated.
Did you compile SDL_mixer by yourself or do you use
a package provided by your distro? The problem may
be that SDL_mixer cannot locate timidity.cfg . On my
distro, it is under /etc, like /etc/timidity.cfg
IF you are compiling SDL_mixer by yourself and it
cannot find timidity.cfg, then edit timidity/config.h in
the SDL_mixer source before compiling and make sure
that CONFIG_FILE definition matches the location on
your disk.
(BTW, music volume is not 0 in hexen2, is it?)
OK, you pointed me in the right direction. SDL_mixer is a distro package but timidity was a user-compiled package, and the instruments aren't in /usr/lib/timidity where SDL_mixer thinks they should be. A whole lot of symlinking more or less fixes things temporarily, and in the meantime I'm going to look for a better timidity package, or just compile it myself maybe :p
Thanks!
Just a follow up now that I understand what's going on a bit better. Hopefully this will help anyone else having a problem with music:
SDL_Mixer uses it's own internal version of Timidity, but still reads from /etc/timidity/timidity.cfg . If the instruments aren't where SDL_Mixer's Timidity expects (/usr/local/lib/timidity by default) then you need a line in timidity.cfg that points to them, i.e:
dir /usr/share/timidity
Much of this information comes by way of http://james.hamsterrepublic.com/linux/
Unfortunately the version of Timidity used by SDL_Mixer is kind of old and doesn't support things like reverb or soundfonts :/
Thus my next question, any possibility for HoT to use an external Timidity in the future? (I realize this isn't exactly high priority :P)
I'm glad your issue is solved.
As for using a newer version of timidity, no it isn't a high priority ;)
But, I may want to use an internal version of timidity if only to
properly support midi music when using sdl audio and/or drop the
SDL_mixer dependency.