You are not logged in.

#1 2013-06-23 09:01:54

PhotonX
Member
From: Munich
Registered: 2008-08-10
Posts: 607

[Solved] Crackling sound in Wine

Hi community,

I'm having some trouble with Wine's sound output. In all Wine applications (including winecfg) I get crackling sound and many of these lines:

ALSA lib pcm.c:7832:(snd_pcm_recover) underrun occurred

All non-Wine applications work fine. I know that the problem appeared some time ago, but since I didn't use Wine for a pretty long time, I cannot tell exactly when it appeared. Currently the latest version from multilib/ is installed (1.6rc3-1). Here is the list of opt deps (installed ones are marked as such):

Optional Deps  : giflib [installed]
                 lib32-giflib
                 libpng [installed]
                 lib32-libpng [installed]
                 libldap [installed]
                 lib32-libldap [installed]
                 gnutls [installed]
                 lib32-gnutls
                 lcms [installed]
                 lib32-lcms
                 libxml2 [installed]
                 lib32-libxml2
                 mpg123 [installed]
                 lib32-mpg123 [installed]
                 openal [installed]
                 lib32-openal [installed]
                 v4l-utils [installed]
                 lib32-v4l-utils [installed]
                 libpulse [installed]
                 lib32-libpulse [installed]
                 alsa-plugins [installed]
                 lib32-alsa-plugins [installed]
                 alsa-lib [installed]
                 lib32-alsa-lib [installed]
                 libjpeg-turbo [installed]
                 lib32-libjpeg-turbo [installed]
                 libxcomposite [installed]
                 lib32-libxcomposite [installed]
                 libxinerama [installed]
                 lib32-libxinerama [installed]
                 ncurses [installed]
                 lib32-ncurses [installed]
                 libcl
                 lib32-libcl
                 oss
                 cups [installed]
                 samba

I need to say that I'm using the fix for crackling noise in Skype: https://wiki.archlinux.org/index.php/Sk … -bit_OS.29 (adding "tsched=0" to some line in /etc/pulse/default.pa). Trying to revert the fix left me without sound at all for some reason.

The .asoundrc (nothing changed as far as I remember):

$ cat ~/.asoundrc
pcm.dmixout {
  # Just pass this on to the system dmix
  type plug
  slave {
     pcm "dmix"
  }
}

defaults.pcm.rate_converter "samplerate_best"

Thanks for any hint,
PhotonX

Last edited by PhotonX (2013-06-23 19:36:55)


Desktop: http://www.sysprofile.de/id15562, Arch Linux    |    Notebook: Thinkpad L13 Yoga Gen2, Manjaro

The very worst thing you can do with free software is to download it, see that it doesn't work for some reason, leave it, and tell your friends that it doesn't work.  -  Tuomas Lukka

Offline

#2 2013-06-23 15:04:23

ZekeSulastin
Member
Registered: 2010-09-20
Posts: 266

Re: [Solved] Crackling sound in Wine

... are you using PulseAudio or are you using dmix?  The package `pulseaudio-alsa` provides an /etc/asound.conf that should direct all sound to pulse, thereby obviating the need for ~/.asoundrc for most configs.  Also, having to set tsched=0 is indicative of a bad ALSA driver and really screws with latency/power management - did you look for or file a bug report over it on the tracker the page mentioned.

If you are using pulse, just bite the compile-time bullet and install `wine-multimedia` from the AUR; the patchset includes actual PulseAudio support and your underruns will be a thinkg of the past.

Offline

#3 2013-06-23 17:04:24

PhotonX
Member
From: Munich
Registered: 2008-08-10
Posts: 607

Re: [Solved] Crackling sound in Wine

Thanks for your reply! I don't think, I use dmix, the .asoundrc is some default one (might actually be a pretty old one since I tend to carry my /home partition over to new system installs). I tried to remove it with no luck. pulseaudio-alsa has been already installed with following /etc/asound.conf:

# Use PulseAudio by default
pcm.!default {
  type pulse
  fallback "sysdefault"
  hint {
    show on
    description "Default ALSA Output (currently PulseAudio Sound Server)"
  }
}

ctl.!default {
  type pulse
  fallback "sysdefault"
}

# vim:set ft=alsaconf:

Since nothing changed after removing .asoundrc, maybe this asound.conf has been used all the time rather than the .asoundrc?

Concerning the tsched=0 thing, the driver is snd_hda_intel (with snd_hda_codec_realtek), the card is an ALC887-VD. The Alsa page you mentioned states that indeed some cards with snd_intel_hda (seems to be the same as snd_hda_intel) driver have problems with timer-based scheduling, but doesn't specify which ones exactly.

So now I'm following your last hint and building wine-multimedia. It had lib32-libcl as make dependency which made conflicts with lib32-catalyst-utils, so I now try building wine-multimedia with lib32-libcl removed from the makedepends list, let's see whether it builds, it takes a while.  Will report back as soon as I have any news.

Last edited by PhotonX (2013-06-23 17:04:51)


Desktop: http://www.sysprofile.de/id15562, Arch Linux    |    Notebook: Thinkpad L13 Yoga Gen2, Manjaro

The very worst thing you can do with free software is to download it, see that it doesn't work for some reason, leave it, and tell your friends that it doesn't work.  -  Tuomas Lukka

Offline

#4 2013-06-23 19:36:32

PhotonX
Member
From: Munich
Registered: 2008-08-10
Posts: 607

Re: [Solved] Crackling sound in Wine

wine-multimedia installed fine without lib32-libcl as makedep and the sound problems disappeared. Thanks for you help!


Desktop: http://www.sysprofile.de/id15562, Arch Linux    |    Notebook: Thinkpad L13 Yoga Gen2, Manjaro

The very worst thing you can do with free software is to download it, see that it doesn't work for some reason, leave it, and tell your friends that it doesn't work.  -  Tuomas Lukka

Offline

#5 2013-06-25 17:04:09

fettouhi
Member
Registered: 2007-05-07
Posts: 775

Re: [Solved] Crackling sound in Wine

Same issue here and installing wine-multimedia fixes the crackling sound but now i have infinite echoes instead in game in borderlands 2 and dishonored.

Offline

#6 2013-06-25 22:05:27

boast
Member
Registered: 2010-09-28
Posts: 219

Re: [Solved] Crackling sound in Wine

fettouhi wrote:

Same issue here and installing wine-multimedia fixes the crackling sound but now i have infinite echoes instead in game in borderlands 2 and dishonored.

For wine gaming, I found it best to use ALSA only, no PA.


Asus M4A785TD-V ;; Phenom II X4 @ 3.9GHz ;; Ripjaws 12GB DDR3-1600 ;; 128GB Samsung 830 ;; MSI GTX460 v2 w/ blob ;; Arch Linux + KDE 4.x

Offline

Board footer

Powered by FluxBB