Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 104939 - Doom3 does not have sound in amd64
Summary: Doom3 does not have sound in amd64
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: AMD64 Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 104635
  Show dependency tree
 
Reported: 2005-09-05 12:23 UTC by Gustavo Felisberto (RETIRED)
Modified: 2005-10-05 15:27 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gustavo Felisberto (RETIRED) gentoo-dev 2005-09-05 12:23:00 UTC
In a amd64 system with alsa sound doom3 will give an error and will not have sound:
dlopen(libasound.so.2)
asoundlib version: 1.0.8
Alsa is available
------ Alsa Sound Initialization -----
ALSA lib pcm.c:6449:(snd_pcm_slave_conf) unknown format S16
snd_pcm_open SND_PCM_STREAM_PLAYBACK 'default' failed: Invalid argument
dlclose
WARNING: sound subsystem disabled

I guess that we need to add a 32bits alsa-lib to emul-linux-x86-soundlibs
Comment 1 Simon Stelling (RETIRED) gentoo-dev 2005-09-05 12:23:56 UTC
do you have 32bit emulation for alsa in the kernel?
Comment 2 Tom Martin (RETIRED) gentoo-dev 2005-09-05 14:02:01 UTC
When I played doom3-demo a while ago, I had sound fine.

HTH.
Comment 3 Gustavo Felisberto (RETIRED) gentoo-dev 2005-09-05 16:06:15 UTC
Ok, update... With OSS emulation some people have sound, others (like me) hear
something but it is not "sound".

In pre alsa 1.0.9 there were some alsa32 kernel modules, they are gone, so it
really is needed alsalibs in emul-sound.
Comment 4 Ben Skeggs 2005-09-05 23:49:46 UTC
emul-linux-x86-soundlibs contains libasound.so.2...

darktama@disoft-dc ~ $ grep libasound.so.2
/var/db/pkg/app-emulation/emul-linux-x86-soundlibs-2.1/CONTENTS
sym /emul/linux/x86/usr/lib/libasound.so -> libasound.so.2.0.0 1121812501
sym /emul/linux/x86/usr/lib/libasound.so.2 -> libasound.so.2.0.0 1121812502
obj /emul/linux/x86/usr/lib/libasound.so.2.0.0 0e1844079fba8b19e9a1c2ea38d27d9d
1121812501
darktama@disoft-dc ~ $
Comment 5 Chris Gianelloni (RETIRED) gentoo-dev 2005-09-06 05:44:24 UTC
So is it an issue with doom3 or with the emul libs?
Comment 6 Gustavo Felisberto (RETIRED) gentoo-dev 2005-09-06 11:58:23 UTC
I'm getting really pissed with doom3 and sound :)

I managed to find in the doom3 config file an entry pointing to the lib used, so
i changed it to point to the emul lib:

seta s_alsa_lib "/emul/linux/x86/usr/lib/libasound.so.2.0.0"
seta s_alsa_pcm "default"

But still i get:

dlopen(/emul/linux/x86/usr/lib/libasound.so.2.0.0)
asoundlib version: 1.0.8
Alsa is available
------ Alsa Sound Initialization -----
ALSA lib pcm.c:6449:(snd_pcm_slave_conf) unknown format S16
snd_pcm_open SND_PCM_STREAM_PLAYBACK 'default' failed: Invalid argument
dlclose

I even tryed to use the 64bits lib :) But got a nasty error :) So it means that
doom3 was already using the lib in the emul package. Maybe updating the alsalib
version.....
Comment 7 Herbie Hopkins (RETIRED) gentoo-dev 2005-09-06 15:18:41 UTC
Please try emul-linux-x86-soundlibs-2.2 and let me know if that helps (currently
p.masked).
Comment 8 Gustavo Felisberto (RETIRED) gentoo-dev 2005-09-06 15:34:41 UTC
Async thread started
snd_pcm_writei short write: 4092 out of 4096
snd_pcm_writei short write: 2046 out of 2048
snd_pcm_writei short write: 2046 out of 2048
idAudioHardwareALSA::Write: 4096 frames overflowed and dropped
snd_pcm_writei short write: 286 out of 2048
snd_pcm_writei short write: 1012 out of 1024
snd_pcm_writei short write: 1012 out of 1024
snd_pcm_writei short write: 1012 out of 1024
snd_pcm_writei short write: 1012 out of 1024
idAudioHardwareALSA::Write: 4096 frames overflowed and dropped


But at least it initializes and i have (very bad) sound. Maybe the problem is
elsewhere now. There are some ideas on the doom3 faq that i'll try
http://zerowing.idsoftware.com/linux/doom/
Comment 9 Chris Gianelloni (RETIRED) gentoo-dev 2005-09-07 05:50:55 UTC
Doom 3, along with UT2004, don't like a few sound chipsets, especially cheap
on-board chipsets.  I would say about 90% of the problems we see on the forums
with binary games are related to on-board chipsets and their drivers.  Are you
using the kernel ALSA or alsa-driver?
Comment 10 Gustavo Felisberto (RETIRED) gentoo-dev 2005-09-07 08:28:25 UTC
The kernel one, that is the same as the alsa-driver 1.0.9 package has, but the
driver is really buggy (i'm working with the alsa dev to get it working better).

For the record it is a ati-ixp card (can't add another card as this is a laptop :) )
Comment 11 Sulla Felix 2005-09-07 11:33:49 UTC
Same problem here

Linux mars 2.6.12-gentoo-r9 #6 SMP Tue Sep 6 00:39:16 WIT 2005 x86_64 AMD 
Athlon(tm) 64 Processor 3000+ AuthenticAMD GNU/Linux

nforce ac97 alsa driver built from gentoo-sources.

ALSA lib pcm.c:6449:(snd_pcm_slave_conf) unknown format S16

I get the same error, in the alsa sound test in Point2Play (linux32 Point2Play).
So obviously something is broken in the soundlibs.

USing OSS emulation, doom3 complains about wanting 44.1khz and getting 48khz.

Comment 12 Sulla Felix 2005-09-07 11:47:28 UTC
(In reply to comment #8)
> Async thread started
> snd_pcm_writei short write: 4092 out of 4096
> snd_pcm_writei short write: 2046 out of 2048
> snd_pcm_writei short write: 2046 out of 2048
> idAudioHardwareALSA::Write: 4096 frames overflowed and dropped
> snd_pcm_writei short write: 286 out of 2048
> snd_pcm_writei short write: 1012 out of 1024
> snd_pcm_writei short write: 1012 out of 1024
> snd_pcm_writei short write: 1012 out of 1024
> snd_pcm_writei short write: 1012 out of 1024
> idAudioHardwareALSA::Write: 4096 frames overflowed and dropped
> 
> 
> But at least it initializes and i have (very bad) sound. Maybe the problem is
> elsewhere now. There are some ideas on the doom3 faq that i'll try
> http://zerowing.idsoftware.com/linux/doom/

Just emerge emul-linux-x86-soundlibs 2.2 and I get the same flood of short write
and overflowed messages.

LIBGL_DRIVERS_DIR=/usr/X11R6/lib32/modules/dri linux32 doom3 +set s_alsa_pcm
plughw:0 +Set s_numberOfSpeakers 2 +set s_driver alsa

I get sound too, and Point2Play Alsa test doesn't fail anymore...

Why is a "working" version of the emul soundlibs masked while the broken one isn't?
Comment 13 Simon Stelling (RETIRED) gentoo-dev 2005-09-07 11:52:31 UTC
because 2.2 is very new (not even a day, if you look at the date), and we want
to be sure that it works before breaking something. we'll unmask it as soon as
we see that it doesn't break anything

just a bit more patience please
Comment 14 Simon Stelling (RETIRED) gentoo-dev 2005-10-05 15:27:31 UTC
2.2 is out of p.mask