http://bugs.winehq.org/show_bug.cgi?id=28679
Bug #: 28679 Summary: Scrabble Online corrupt sound Product: Wine Version: 1.3.30 Platform: x86-64 OS/Version: Linux Status: NEW Keywords: regression Severity: normal Priority: P2 Component: winealsa.drv AssignedTo: wine-bugs@winehq.org ReportedBy: kennybobs@o2.co.uk CC: aeikum@codeweavers.com Classification: Unclassified Regression SHA1: b0652dd8bdb144645be4a6bf77cbb68a8ade49d9
Created attachment 36853 --> http://bugs.winehq.org/attachment.cgi?id=36853 wine-1.3.30-45-ga843ace console output
Scrabble Online has a recent regression that causes the sound and music to "sound corrupted". On some occasions there is no sound at all.
b0652dd8bdb144645be4a6bf77cbb68a8ade49d9 is the first bad commit commit b0652dd8bdb144645be4a6bf77cbb68a8ade49d9 Author: Andrew Eikum aeikum@codeweavers.com Date: Mon Oct 10 15:56:55 2011 -0500
winealsa.drv: Don't try to control ALSA's behavior.
Now, winealsa maintains its own buffer, which is written to ALSA on the period cycle requested by the application. We also let ALSA start when it has enough data and stop when it runs out, recovering from the expected underruns. This seems to be more like how ALSA expects to be used.
:040000 040000 874ae9456f596d46ee3911eabcbc6f291afe48cb 62ca893abef4dd0459b201d4c45d0c7b0c87a989 M dlls
Reverting this commit in wine-1.3.30-45-ga843ace fixes the problem.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #1 from Ken Sharp kennybobs@o2.co.uk 2011-10-12 11:42:36 CDT --- Created attachment 36854 --> http://bugs.winehq.org/attachment.cgi?id=36854 wine-1.3.30-45-ga843ace +alsa
Don't know if this is of any use.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #2 from Austin English austinenglish@gmail.com 2011-10-12 12:05:45 CDT --- (In reply to comment #1)
Created attachment 36854 [details] wine-1.3.30-45-ga843ace +alsa
Don't know if this is of any use.
See http://wiki.winehq.org/Sound for proper debugging tips.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #3 from Andrew Eikum aeikum@codeweavers.com 2011-10-12 13:09:03 CDT --- Thanks, Ken. Does this problem affect only this application, that you know of? Or is sound broken for many applications for you?
Is there a download available for this application? If not, can you attach a log as requested at http://wiki.winehq.org/Sound?
http://bugs.winehq.org/show_bug.cgi?id=28679
Alexey Loukianov mooroon2@mail.ru changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |mooroon2@mail.ru
--- Comment #4 from Alexey Loukianov mooroon2@mail.ru 2011-10-12 14:53:03 CDT --- Just had done regression testing with "sound effects totally messed" in RAGE. Comes down to a same commit, reverting it "fixes" the problem. So RAGE is also affected, hadn't had a chance yet to test other apps I maintain in appdb. Would test tomorrow and post any info about other affected app if any.
http://bugs.winehq.org/show_bug.cgi?id=28679
Ken Sharp kennybobs@o2.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #36854|0 |1 is obsolete| |
--- Comment #5 from Ken Sharp kennybobs@o2.co.uk 2011-10-12 18:39:30 CDT --- Created attachment 36870 --> http://bugs.winehq.org/attachment.cgi?id=36870 wine-1.3.30-45-ga843ace +tid,+mmdevapi,+winmm,+midi,+dsound,+dmusic,+oss,+alsa,+coreaudio
Other than in Alexey's comment I'm not currently aware of any other app that is affected.
Diner Dash 5 might be affected but it won't install due to some regression. I'll have a look for a downloadable app that is affected and update.
http://bugs.winehq.org/show_bug.cgi?id=28679
Ken Sharp kennybobs@o2.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download URL| |http://downloads.popcap.com | |/www/popcap_downloads/Bejew | |eledSetup.exe
--- Comment #6 from Ken Sharp kennybobs@o2.co.uk 2011-10-12 18:44:42 CDT --- Bejeweled is affected. Probably affects a lot. Will add links to the bug as I find affected apps. http://downloads.popcap.com/www/popcap_downloads/BejeweledSetup.exe
http://bugs.winehq.org/show_bug.cgi?id=28679
Ken Sharp kennybobs@o2.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Scrabble Online corrupt |Corrupt sound in many apps |sound |
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #7 from Ken Sharp kennybobs@o2.co.uk 2011-10-12 20:08:38 CDT --- Family Feud appears to be the worst affected app so far. http://downloads.popcap.com/www/popcap_downloads/FamilyFeudSetup.exe
The game does not start and hangs when trying to exit.
http://bugs.winehq.org/show_bug.cgi?id=28679
Luke Bratch l_bratch@yahoo.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |l_bratch@yahoo.co.uk
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #8 from Alexey Loukianov mooroon2@mail.ru 2011-10-13 06:02:17 CDT --- Affected: * All Source-based games I had tested so far: HL2, HL2:EP1, HL2:EP2, HL:Source, HL:Lost Coast, Portal, Counter Strike: Source; * All GldSrc-based games I had tested so far: HL, HL: Blue Shift, HL: Opposing Force, Counter Strike; * King's Bounty: The Legend, King's Bounty: Armored Princess, King's Bounty: Crossworlds; * Braid
Unaffected: * Osmos * S.T.A.L.K.E.R. series; * Machinarium (i.e. Adobe Flash 10.x) * Torchlight
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #9 from Andrew Eikum aeikum@codeweavers.com 2011-10-13 08:25:53 CDT --- Thanks for the thorough testing!
(In reply to comment #6)
Bejeweled is affected. Probably affects a lot. Will add links to the bug as I find affected apps. http://downloads.popcap.com/www/popcap_downloads/BejeweledSetup.exe
This was fixed for me when I applied this patch which is currently in the wine-patches queue: http://source.winehq.org/patches/data/79841
(In reply to comment #7)
Family Feud appears to be the worst affected app so far. http://downloads.popcap.com/www/popcap_downloads/FamilyFeudSetup.exe
The game does not start and hangs when trying to exit.
This doesn't seem to work with or without the commit this bug is about (b0652dd8b). Haven't looked further into it.
(In reply to comment #8)
Affected:
- All Source-based games I had tested so far: HL2, HL2:EP1, HL2:EP2, HL:Source,
HL:Lost Coast, Portal, Counter Strike: Source;
Steam is currently broken for me so I wasn't able to test these. But...
- All GldSrc-based games I had tested so far: HL, HL: Blue Shift, HL: Opposing
Force, Counter Strike;
I do have a copy of Half-Life, and it was fixed by the patch linked above as well.
- King's Bounty: The Legend, King's Bounty: Armored Princess, King's Bounty:
Crossworlds;
- Braid
I tried demos for The Legend, Armored Princess, and Braid, but all of them refused to run. AppDB didn't help, either.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #10 from Alexey Loukianov mooroon2@mail.ru 2011-10-13 08:58:04 CDT --- (In reply to comment #9)
This was fixed for me when I applied this patch which is currently in the wine-patches queue: http://source.winehq.org/patches/data/79841
What's ETA for this patch to be pulled into wine-git? Should I create a temporary branch and apply this patch over it to do the test or would it be easier to wait till it would land to git?
- King's Bounty: The Legend, King's Bounty: Armored Princess, King's Bounty:
Crossworlds;
- Braid
I tried demos for The Legend, Armored Princess, and Braid, but all of them refused to run. AppDB didn't help, either.
It's another regression I'm trying to debug now. Looks like recent changes to msvcrt broke it heavily for a lot of apps, namely all KB series, S.T.A.L.K.E.R., Braid and many other. I've been testing for apps affected by this bug against wine-1.3.30-10-gb0652dd - it is free from msvcrt related regression as it was introduced later on.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #11 from Alexey Loukianov mooroon2@mail.ru 2011-10-13 09:01:22 CDT --- P.S. BTW, I've got a lot of this in logs after recent changes to Wine's sound subsystem when playing SC2:
ALSA lib pcm.c:7316:(snd_pcm_recover) underrun occurred ALSA lib pcm.c:7316:(snd_pcm_recover) underrun occurred ALSA lib pcm.c:7316:(snd_pcm_recover) overrun occurred ALSA lib pcm.c:7316:(snd_pcm_recover) underrun occurred ALSA lib pcm.c:7316:(snd_pcm_recover) underrun occurred ALSA lib pcm.c:7316:(snd_pcm_recover) underrun occurred 0069:err:winediag:FILE_CreateFile Too many open files, ulimit -n probably needs to be increased ALSA lib pcm.c:7316:(snd_pcm_recover) overrun occurred
Not sure if this is related to this bug as the in-game sound seems to be good enough: I can't spot any stutter or other type of corruption during general gameplay.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #12 from Andrew Eikum aeikum@codeweavers.com 2011-10-13 09:19:48 CDT --- (In reply to comment #9)
- All Source-based games I had tested so far: HL2, HL2:EP1, HL2:EP2, HL:Source,
HL:Lost Coast, Portal, Counter Strike: Source;
Steam is currently broken for me so I wasn't able to test these.
Spoke too soon. I got Steam working, and the patch fixes the Braid demo (when installed through Steam; the stand-alone demo remains broken for some probably unrelated reason. The King's Bounty demo worked neither stand-alone nor through Steam). It also fixed Lost Coast. So I think it's pretty safe to say that I expect this to be fixed after today's commit round.
(In reply to comment #11)
P.S. BTW, I've got a lot of this in logs after recent changes to Wine's sound subsystem when playing SC2:
Not sure if this is related to this bug as the in-game sound seems to be good enough: I can't spot any stutter or other type of corruption during general gameplay.
By SC2 you mean StarCraft 2? StarCraft 2's sound works in two ways, either through DirectSound or directly with MMDevAPI, depending on some internal heuristics (Windows version, or presence of a working mmdevapi.dll, or something similar). Unfortunately there isn't an easy way to tell which sound API it's using, as far as I know.
If it's using DirectSound, then I'd expect those messages to be gone, or mostly gone, after the above patch is applied.
If it's using MMDevAPI directly, then that's a little unexpected. Do you get a _whole_lot_ of those messages (several per second) or just one every few minutes or something? The former is worrying, the latter is not. Underruns just happen sometimes, and if it's not corrupting your sound noticeably then it's no problem.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #13 from Alexey Loukianov mooroon2@mail.ru 2011-10-13 10:27:30 CDT --- (In reply to comment #12)
Steam). It also fixed Lost Coast. So I think it's pretty safe to say that I expect this to be fixed after today's commit round.
So I had branched from wine-1.3.30-10-gb0652dd and applied the patch you mentioned. It fixed HL2, HL, RAGE and - most probably - all other apps that are affected by this bug.
By SC2 you mean StarCraft 2? StarCraft 2's sound works in two ways, either through DirectSound or directly with MMDevAPI, depending on some internal heuristics (Windows version, or presence of a working mmdevapi.dll, or something similar). Unfortunately there isn't an easy way to tell which sound API it's using, as far as I know.
If it's using DirectSound, then I'd expect those messages to be gone, or mostly gone, after the above patch is applied.
If it's using MMDevAPI directly, then that's a little unexpected. Do you get a _whole_lot_ of those messages (several per second) or just one every few minutes or something? The former is worrying, the latter is not. Underruns just happen sometimes, and if it's not corrupting your sound noticeably then it's no problem.
Yeah, I meant Starcraft II. In case I set emulated Windows version to be WinXP I've got this messages. Their amount vary from run to run. Applying patch that fixes _this_ bug reduces a number of this messages. Overall amount is not too big at all - it is about 2-5-10-15 messages total after I had started up SC2 and played back short game replay (~5 minutes in length). Having windows version set to Win7 made this messages disappear but I've got SC2.exe crash at the moment I exit from it which is a subject of another already reported bug.
What I had tracked down is that right after I log in into my account and SC2 opens up its main interface GUI there are several brief (~0.5-1s) pauses (stutters) both in sound and in visual appearance. Every second time I start up the game I've got an in-game messagebox telling something like "There was a problem downloading content, please try again later". I suspect this problems to be related either to the new SC2 patch I had installed today while were looking for apps affected by this bug or to the some regression introduced somewhere between Wine 1.3.8 and 1.3.30 (last time I were playing SC2 for long-enough period under Wine was when Wine were at 1.3.8). Let's not hijack this bug report, I would test it a bit later and file a new report in case there would be enough reasons for that.
P.S. Thx a lot for your hard work over Wine's sound subsystem!
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #14 from Andrew Eikum aeikum@codeweavers.com 2011-10-13 14:13:19 CDT --- The patch is in Wine as 9d29d9f7665c0e75ed143052408c5fb02fd2afad. Ken, can you retest and confirm this fixes the problem?
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #15 from Alexey Loukianov mooroon2@mail.ru 2011-10-13 16:39:35 CDT --- Well, sad to report but I was too quick to state this patch fixes the sound to the level it was before commit b0652dd8.
With emulated win version set to Windows 7 I've got extremely noticeable sound stutter in RAGE even after the patch from commit 9d29d9f7. In WinXP mode sound seems to be _almost_ normal. Listening to it carefully makes me come to a conclusion that there's slight distortion introduced which sounds like "very slight clipping". This distortion might be a result of a lot of tiny (1-2 samples) underruns occurring non-stop.
http://bugs.winehq.org/show_bug.cgi?id=28679
Ken Sharp kennybobs@o2.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |9d29d9f7665c0e75ed143052408 | |c5fb02fd2afad Status|NEW |RESOLVED Component|winealsa.drv |directx-dsound Resolution| |FIXED
--- Comment #16 from Ken Sharp kennybobs@o2.co.uk 2011-10-13 18:53:41 CDT --- All fixed, including Family Feud (you need to update SDL.dll to get FF working).
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #17 from Alexey Loukianov mooroon2@mail.ru 2011-10-14 06:16:26 CDT --- Andrew, as Ken had marked this one as fixed - should I file a new report instead about corrupted sound after b0652dd8 in RAGE? As I already posted, in case WINEPREFIX is configured to be Win7 - corruption is huge (I suspect that RAGE and/or XAudio2 uses mmdevapi directly in this case instead of relying on dsound). For WinXP-configured prefix corruption is also in place but is barely noticable, you need to listen very carefully to spot it.
http://bugs.winehq.org/show_bug.cgi?id=28679
--- Comment #18 from Andrew Eikum aeikum@codeweavers.com 2011-10-14 07:26:37 CDT --- Yes, please go ahead and file a new bug. If it's not fixed by that patch, then it's probably caused by a separate issue. Thanks.
http://bugs.winehq.org/show_bug.cgi?id=28679
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #19 from Alexandre Julliard julliard@winehq.org 2011-10-21 13:50:48 CDT --- Closing bugs fixed in 1.3.31.