GNOME Bugzilla – Bug 309463
alsasink sound quality is poor
Last modified: 2009-08-15 18:40:50 UTC
Version details: gst-plugins 0.8.9 Distribution/Version: Mandrake 10.1 official If I play any mp3 file through alsasink: gst-launch filesrc location=var/test.mp3 ! mad ! alsasink it plays, but the quality is like a scratchy LP: there are many clicks and jumps. This happens on Mandrake 10.1 and some other distros, but not on gentoo; see the discussion at http://bugs.campware.org/view.php?id=1230 . Playback is fine if I use osssink or filesink instead of alsasink. The same problem occurs with version 0.8.5, but to a much lesser degree. (I would not have noticed it there if I did not know what to listen for.)
WHat kind of soundcard? What driver?
My sound card is an on-board VIA VT8233 AC'97 card, with the snd-via82xx driver. Frans van Berckel tried it with several other sound cards, with similar results; I'll ask him to post his configurations, as well.
I have a powermac g4 with a on-board sound card, the driver snd-powermac 2th a soundbaster live with the snd-emu10k1 driver, or better with lspci 0001:10:17.0 Class ff00: Apple Computer Inc. KeyLargo Mac I/O rev 03 Flags: bus master, medium devsel, latency 16 Memory at 0000000080000000 (32-bit, non-prefetchable) 0001:10:13.0 Multimedia audio controller: Creative Labs SB Live! EMU10k1 rev 07 Subsystem: Creative Labs CT4780 SBLive! Value Flags: bus master, medium devsel, latency 16, IRQ 53 I/O ports at 0400 Capabilities: [dc] Power Management version 1 Drivers are build in into the kernel, my uname -a Linux lnxsrv3 2.6.10-5-powerpc #1 Tue Apr 5 12:44:32 UTC 2005 ppc ppc ppc GNU/Linux
Are you using dmix?
I am am using aumixrc for sound-slot-0 and sound-slot-1, and for snd-card-0 and snd-card-1 the alsactl
... which means?
Created attachment 48970 [details] frans modprobe.conf my /etc/modprobe.conf from yellowdog linux ppc file
Created attachment 48971 [details] the 2th time as text
I found a reference to "stuttering" here: http://alsa.opensrc.org/index.php?page=DmixPlugin and created a $HOME/.asoundrc file containing pcm.!default { type plug slave.pcm "dmixer" } pcm.dsp0 { type plug slave.pcm "dmixer" } pcm.dmixer { type dmix ipc_key 1024 slave { pcm "hw:0,0" period_time 0 period_size 2048 # instead of 1024 buffer_size 32768 # instead of 8192 rate 44100 } bindings { 0 0 1 1 } } ctl.mixer0 { type hw card 0 } as suggested there, with the increased values for period_size and buffer_size. This solved the problem.
OK, so you *are* using dmix and it was indeed causing this. That's a known upstream bug. I suggest you submit a bug report at the alsa bug tracker at http://www.alsa-project.org/ and keep a close eye there.
Yes, I am using dmix now -- I don't know if I was earlier: I had no ~/.asoundrc and no /etc/asound.conf file. But now that I read up on it, I probably want to use it, and increasing the buffer size seems like a better a solution than trying to disable dmix. Thanks for your help!