GNOME Bugzilla – Bug 498928
[alsasink] Crackling sound after update to 0.10.15
Last modified: 2007-12-04 13:58:22 UTC
Hi, quoting http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=452282 : After upgrading to the latest version playing any file results in cracks during playback. Downgrading all gstreamer0.10 related packages to the Testing version fixes this problem for now. I’m using a soundcard with the CMI8783 chipset. Below are the GST_DEBUG=5 logs with 0.10.14 and 0.10.15: http://slomosnail.de/~slomo/temp/gst_0.10.14-2.log.bz2 http://slomosnail.de/~slomo/temp/gst_0.10.15-1.log.bz2 The main difference I see is, that before 16 bit caps were used on the alsa sink while with 0.10.15 32 bit caps are used: intersection of the caps in 0.10.14: audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)[ 1, 2 ], endianness=(int)1234, depth=(int)16, signed=(boolean)true; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)3, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_LFE >; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)4, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)6, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT, GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)8, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT, GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE, GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT > intersection of the caps in 0.10.15: audio/x-raw-int, width=(int)32, rate=(int)[ 4000, 2147483647 ], channels=(int)[ 1, 2 ], endianness=(int)1234, signed=(boolean)true, depth=(int)32; audio/x-raw-int, width=(int)32, rate=(int)[ 4000, 2147483647 ], channels=(int)3, endianness=(int)1234, signed=(boolean)true, depth=(int)32, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_LFE >; audio/x-raw-int, width=(int)32, rate=(int)[ 4000, 2147483647 ], channels=(int)4, endianness=(int)1234, signed=(boolean)true, depth=(int)32, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >; audio/x-raw-int, width=(int)32, rate=(int)[ 4000, 2147483647 ], channels=(int)6, endianness=(int)1234, signed=(boolean)true, depth=(int)32, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT, GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >; audio/x-raw-int, width=(int)32, rate=(int)[ 4000, 2147483647 ], channels=(int)8, endianness=(int)1234, signed=(boolean)true, depth=(int)32, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT, GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE, GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)[ 1, 2 ], endianness=(int)1234, depth=(int)16, signed=(boolean)true; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)3, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_LFE >; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)4, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)6, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT, GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >; audio/x-raw-int, width=(int)16, rate=(int)[ 4000, 2147483647 ], channels=(int)8, endianness=(int)1234, depth=(int)16, signed=(boolean)true, channel-positions=(GstAudioChannelPosition)< GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT, GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE, GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >
You could confirm if it is in fact caused by 32-bit caps by forcing 16-bit caps into the audio sink with a capsfilter.
He has confirmed that a capsfilter forcing it to 16 bit doesn't give crackling sound. I've told him to test with aplay with a 16 bit and 32 bit wav file, should give us the answer if it's our bug or alsa's ;)
Ok, he doesn't get any crackling with aplay so I guess this bug is our's then... anything else I could ask him to test? :)
This looks like another instance of this alsa bug: https://bugtrack.alsa-project.org/alsa-bug/view.php?id=3360 which is an integer overflow in their 32bit->16bit conversion.
I know this bug, unfortunately this doesn't seem to be the cause, see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=429326 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=436337 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=451929
Actually one of the reporters confirmed that it _is_ this bug. Ok, let's close this as NOTGNOME then... It happened more often since 0.10.15 because volume got 32 bit support it seems... way to reproduce: gst-launch-0.10 audiotestsrc volume=1.0 ! "audio/x-raw-int,width=32,depth=32" ! volume volume=1.0 ! alsasink