Allegro can't play sound with ALSA

Bug #445945 reported by Damian Yerrick on 2009-10-08
34
This bug affects 7 people
Affects Status Importance Assigned to Milestone
allegro4.2 (Debian)
Fix Released
Unknown
allegro4.2 (Ubuntu)
Undecided
Unassigned

Bug Description

Ubuntu 9.04, liballegro-4.2 version 2:4.2.2-2ubuntu1

I install and run allegro-examples and choose digitest. But instead of sound, I got this:

Error initialising sound
ALSA: snd_pcm_hw_params_set_format(pcm_handle, hwparams, format) : Invalid argument

This page suggests that pulseaudio doesn't like the unsigned (U16) samples that Allegro's mixer produces.
http://<email address hidden>/msg00421.html

Upstream recently released Allegro 4.2.3, which works around this.
http://alleg.sourceforge.net/

ProblemType: Bug
Architecture: i386
DistroRelease: Ubuntu 9.04
Package: liballegro4.2 2:4.2.2-2ubuntu1
ProcEnviron:
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: allegro4.2
Uname: Linux 2.6.28-15-generic i686

Damian Yerrick (tepples) wrote :
Damian Yerrick (tepples) wrote :

I just realized it might be hardware-dependent; in that case, it might be relevant to point out that I'm trying it on an ASUS Eee PC 900.

Marius Gedminas (mgedmin) wrote :

This seems to be http://pulseaudio.org/ticket/133 and AFAICS is not hardware-dependent. It breaks sound on every Allegro-using application on Ubuntu, with the default settings (i.e. PulseAudio enabled). Would be great to have this fixed before Lucid is out.

Changed in allegro4.2 (Ubuntu):
status: New → Confirmed

I got this error to.

Really bad that i dident see this bug before i started to digg after an answer xD. Looking for about 2h now, and here it is the answer. Anyone knows if it is working on karmic yet?

did now try to download and install allegro manualy, now the sounds works perfectly:D

Hi stampe,
how do you do the installation? I'm trying to install liballegro, but the game overgod doesn't accept my installation as your dependencie.
Thanx.
Reynaldo

Daniel Hollocher (chogydan) wrote :

Hey folks, can you test the allegro4.2 package that you can find here: https://launchpad.net/~chogydan/+archive/gnome-session/

I trivially updated the package to 4.2.3

If that works, then this can be converted into a "please update" bug maybe. Or maybe someone needs to open up a please update bug. Thanks!

Changed in allegro4.2 (Ubuntu):
status: Confirmed → Incomplete
Changed in allegro4.2 (Ubuntu):
status: Incomplete → Confirmed

I have installed the packages from https://launchpad.net/~chogydan/+archive/gnome-session/ but allegro-examples neither overgod has successful initialized sound.
Have I forgot something?
thanx
Reynaldo

Daniel Hollocher (chogydan) wrote :

yeah, I got that too, but it is a different bug. Can you open a new bug report? The error initializing sound is about the sound card not being supported at all. I think the other error is about not getting MIDI support. I tried to google it, but couldn't find anything.

Daniel Hollocher (chogydan) wrote :

for reference, here is a bug about overgod: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=474314

Changed in allegro4.2 (Debian):
status: Unknown → New
Damian Yerrick (tepples) wrote :

Reynaldo: Marius already mentioned that ticket. But just for kicks, I tried this today:

1. Upgrade my Larmic machine to Lucid
2. Add ppa:chogydan/gnome-session to my software sources
3. sudo apt-get upgrade
4. sudo apt-get install allegro-demo
5. all-demo

The error changed to "No supported synth type found". So I guess it still isn't fixed.

Changed in allegro4.2 (Debian):
status: New → Fix Committed
Daniel Hollocher (chogydan) wrote :

Hey Damian, the bug of failed initialization is actually fixed, but things like all-demo and overgod try to use MIDI, which is also not working either. That's a different bug.

I suggest you work on this bug report [1] for that, as this bug report should be marked fix released as soon as the debian package propagates.

[1] https://bugs.launchpad.net/ubuntu/+source/overgod/+bug/311833

Changed in allegro4.2 (Debian):
status: Fix Committed → Fix Released

Hi,
overgod its working on Debian Squeeze (debbugs #462810), but isn't working on Ubuntu Lucid Lynx.
When that fix wll be released?

Daniel Hollocher (chogydan) wrote :

@Reynaldo, have you tried Maverick? My understanding is that fixes like this will always just go into the next release.

I have tried to apply the patch but it returns:
reynaldo@cerbero:~/Documentos/Builds/allegro4.2-4.2.2$ patch -p0 < patch.diff
patching file allegro4.2-4.2.2/debian/changelog
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED -- saving rejects to file allegro4.2-4.2.2/debian/changelog.rej
patching file allegro4.2-4.2.2/debian/patches/series
patching file allegro4.2-4.2.2/debian/patches/070_alsa_signed.diff

Anybody knows how to apply that? Please.

Daniel Hollocher, why?

Daniel Hollocher (chogydan) wrote :

@Reynaldo: I believe I still have a lucid package in my ppa which includes the fix. I don't know why it isn't working for you, but I thnk you can ignore failures against the changelog. It is just the changelog

PasNox (pasnox) wrote :

Bug still present in ubuntu/kubuntu 10.10.

Changed in allegro4.2 (Ubuntu):
status: Confirmed → Fix Released

@Daniel that fix worked for me on overgod (problem: lacks a module and a simbolic link): http://<email address hidden>/msg2616709.html

sudo modprobe snd_virmidi
cd /dev/snd && sudo ln -s midiC2D0 midiC0D0

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.