You are not logged in.

#1 2013-06-09 18:46:58

Shingetsu
Member
Registered: 2012-09-15
Posts: 27

Pulseaudio tsched workaround keeping wine audio

Pulseaudio's scheduling is broken on some audio cards, including mine (my driver is snd_emu10k1).
Unfortunately, the only working hack I found was to disable timing scheduling (tsched=0) during loading of pulse drivers.

An ugly solution since this kills wine sound.

For now I set wine to use alsa directly (resulting in a working, sometimes slightly buggy sound).
Does anyone know of a better alternative? (I've done quite a bit of forum crawling XD)

Offline

#2 2013-06-09 18:48:05

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,018

Re: Pulseaudio tsched workaround keeping wine audio

You could try wine-multimedia.

Offline

#3 2013-06-09 18:53:11

Shingetsu
Member
Registered: 2012-09-15
Posts: 27

Re: Pulseaudio tsched workaround keeping wine audio

lucke wrote:

You could try wine-multimedia.

*facepalm*
so I missed that, huh?

Though it winds up not being 1.6-rc1 unfortunately, at this time.

Thanks anyway, I'll make sure to compile it and check it out a bit later!

Offline

#4 2013-06-09 19:54:41

brebs
Member
Registered: 2007-04-03
Posts: 3,444

Re: Pulseaudio tsched workaround keeping wine audio

Shingetsu wrote:

sometimes slightly buggy sound

In which app/game?

Do you have a hardware-mixing soundcard? If so, you should get rid of pulseaudio (which will always do software mixing, AIUI), and configure ALSA to *not* use dmix, and it might help to configure wine to output directly to the hardware too - this might work:

echo -e "[HKEY_CURRENT_USER\\Software\\Wine\\ALSA Driver]\n\"UseDirectHW\"=\"Y\"" | wine regedit -

Offline

#5 2013-06-09 20:33:32

Shingetsu
Member
Registered: 2012-09-15
Posts: 27

Re: Pulseaudio tsched workaround keeping wine audio

brebs wrote:

In which app/game?

Pretty much all of them. Crackling sound. Including (but not limited to):

  • DotA2

  • CS:GO

  • touhou

brebs wrote:

Do you have a hardware-mixing soundcard?

Nope. My sound card is very high quality (24/192khz) but it has no hardware mixing (thus why it's cheap despite the amazing quality).
And I use pulse for streaming (easier to combine sound streams/sources).
And of course monitors. Monitors are so useful.

Offline

#6 2013-06-09 20:34:35

Shingetsu
Member
Registered: 2012-09-15
Posts: 27

Re: Pulseaudio tsched workaround keeping wine audio

brebs wrote:
echo -e "[HKEY_CURRENT_USER\\Software\\Wine\\ALSA Driver]\n\"UseDirectHW\"=\"Y\"" | wine regedit -

That's pretty much what I did.
Now it's slightly buggy (sound'll break off for a few seconds every now and then). But seems like rather inelegant.

Offline

#7 2013-06-09 20:49:18

brebs
Member
Registered: 2007-04-03
Posts: 3,444

Re: Pulseaudio tsched workaround keeping wine audio

Could try wine-rt-101107.patch from wine-rt, which I've recently started using.

Then in a game's startup script, before running wine:

export WINE_RT=15
export WINE_SRV_RT=10

Edit: Removed wrong comments about running wine as suid - it's not needed.

Last edited by brebs (2013-08-11 14:52:42)

Offline

#8 2013-06-10 02:09:42

Shingetsu
Member
Registered: 2012-09-15
Posts: 27

Re: Pulseaudio tsched workaround keeping wine audio

Shingetsu wrote:
lucke wrote:

You could try wine-multimedia.

*facepalm*
so I missed that, huh?

Though it winds up not being 1.6-rc1 unfortunately, at this time.

Thanks anyway, I'll make sure to compile it and check it out a bit later!

Follow up on this.
Using wine-multimedia-git I got the latest version (which I wanted, 1.6 seemed a lot smoother than lastest 1.5.x).

It runs perfectly.

As a note, on my sound card, I got amazing quality @
44100 KHz
speex-float-3
realtime = yes

segments = 2
segment size = 25

(I'll bump up the actual frequency later)

Offline

Board footer

Powered by FluxBB