Allegro.cc - Online Community

Allegro.cc Forums » Programming Questions » PulseAudio and Allegro

This thread is locked; no one can reply to it. rss feed Print
PulseAudio and Allegro
jamyskis
Member #6,557
November 2005
avatar

Hi all,

I'm back from the dead (I'm not sure even if anyone remembers me here...)

Anyway, I've just got around to installing Ubuntu 9.04 and was looking to continue development of Open Invaders, now that I've finally brought myself to get used to Anjuta 2 (I used to use version 1 and couldn't get my head around v2 in the form it was back then!)

However, I've noticed that 9.04 has made the full transition from ALSA/ESD to PulseAudio, with ALSA and OSS backwards compatibility being only provided by an ALSA sink within the confines of the PulseAudio server. I have attempted to run Open Invaders by initing the Allegro server using DIGI_AUTODETECT but am met with complete silence. Not only that, but the game is unusually slow (running at about 25fps). I've also tried it with DIGI_ALSA manually.

Oddly enough, DIGI_OSS works like a charm (with sound and back to 50fps), but DIGI_AUTODETECT seems to detect DIGI_ALSA which, technically speaking, is not incorrect, as the PulseAudio server is detecting the game as a client.

I really don't want to have to resort to using DIGI_OSS in the long term, especially as I'm striving for cross-platform source compatibility and DIGI_OSS will just conk out under Windows. Does anyone have any suggestions on how to get around the atrocious ALSA support under Ubuntu 9.04?

__________________________________________________________________
In a world without fences and walls, who needs Windows and Gates?
http://www.jamyskis.net

kazzmir
Member #1,786
December 2001
avatar

$ sudo apt-get remove pulseaudio

Problem solved.

amber
Member #6,783
January 2006
avatar

You could always just #ifdef it, too. ;D

dudaskank
Member #561
July 2000
avatar

You can make a config utility to your program, or make inside the game a options menu where you can select this.

Toque a balada do amor inabalável, eterna love song de nós dois
Eduardo "Dudaskank"
[ Home Page (ptbr) | Blog (ptbr) | Tetris 1.1 (ptbr) | Resta Um (ptbr) | MJpgAlleg 2.3 ]

Thomas Fjellstrom
Member #476
June 2000
avatar

jamyskis said:

but DIGI_AUTODETECT seems to detect DIGI_ALSA which, technically speaking, is not incorrect, as the PulseAudio server is detecting the game as a client.

Because pulseaudio developers thought it was a good idea to take over the default ALSA devices. It completely breaks many valid ALSA programs.

--
Thomas Fjellstrom - [website] - [email] - [Allegro Wiki] - [Allegro SVN Snapshots] - [Allegro TODO] - [Royalty Free Music]
"God Bless Joe Pesci" -- George Carlin
"Goto is the buldozer of coding. Sometimes, the buldozer is just the right tool for the job. Not often, but sometimes." -- LordBob

Go to: