Read-only archive of the Armageddon Games Forums Archive (2000–2026) · About this archive

Sound on Ubuntu (Allegro/Pulseaudio issues) -- need help with allegro.cfg

5 replies · 2,917 views · Started 25 June 2010

Fresh install, latest linux build, Ubuntu 9.10 (karmic). Start zelda-l from ZC Launcher with default options. There is no sound of any kind--music or sfx.

Examining allegro.log reveals the following:
[font=courier]Initializing sound driver... Sound driver not available. Sound disabled.[/font]

Apparently, allegro and pulseaudio don't get along very well.

Fortunately, a workaround is given. Unfortunately, however, ZC users will run into trouble at step 2a, which instructs them to edit the file [font=courier]/usr/lib/allegro/4.2.2/modules.lst[/font], which a) probably doesn't exist on their system, and b) won't affect the custom version of allegro used by ZC in any case.

Now, what step 2a actually does isn't that complicated--it forces allegro to use the OSS sound driver--so even if that particular file won't work, there should be another way to accomplish the same thing. And indeed, according to the official allegro docs,
[quote="http://alleg.sourceforge.net/latestdocs/en/readme.html"] Allegro reads information about your hardware from a file called allegro.cfg
...
Normally the setup program and allegro.cfg will go in the same directory as the Allegro program they are controlling. [/quote]
So, hopefully, all I need to do is figure out the right line(s) to put in allegro.cfg, and I'll be back on track. Which brings me to my question:

What do I put in allegro.cfg to force allegro (and thus ZC) to use the OSS sound driver?

It's... google246!

"What do I put in allegro.cfg to force allegro (and thus ZC) to use the OSS sound driver?"
And... I can be of no help to you whatsoever!

Before you do all that, try running ZC and ZQuest a couple of times each, if you haven't already. It should work, but it takes a few tries to figure it out.

Tried, no effect. Still no sound of any sort from ZC or ZQ, still the same message in allegro.log. I'm not really sure why you expected this to help, to be honest--all it seems to do is regenerate ag.cfg.

In any case, I finally found the documentation for allegro.cfg here, and setting [font=courier]oss_driver = /dev/dsp[/font] under [font=courier][sound][/font] in ag.cfg seems to have done the trick. Running [font=courier]aoss ./zelda-l[/font] gives me full sound now.

MIDI playback quality is still horrendous, but at least it's working.

Snarwin wrote:Tried, no effect. Still no sound of any sort from ZC or ZQ, still the same message in allegro.log. I'm not really sure why you expected this to help, to be honest--all it seems to do is regenerate ag.cfg.

Eh, that's what always works for me. Every new build, no sound until they've been run a few times, then they're fine.

I'm not sure if it'll use the included MIDI patches when run through aoss, but if it does, you can replace them with an sf2 soundfont pretty easily. Install liballegro4.2-dev and run pat2dat patches.dat <soundfont> and replace the one in the samplesoundset directory.

Oh, it uses the default patches fine--they just happen to sound awful (same as they did last time I managed to get working sound).

Fortunately, I managed to find an alternative soundfont that sounds halfway decent after pat2dat conversion.