Dxvk: [Overwatch] Sometimes missing sound and effects/objects

Created on 7 May 2018  Â·  40Comments  Â·  Source: doitsujin/dxvk

Software information

Overwatch, Game Settings (change txt to ini)

System information

  • GPU: NVIDIA GeForce GTX 770
  • Driver: 390.48-12
  • Wine version: 3.7 staging
  • DXVK version: r1081.757be61 from here

Apitrace file(s)

  • Link (change .txt to .trace)
    I don't think it worked ☹ Only one frame shows up in QApiTrace, and I've tried tracing multiple times.

Log files

DXVK_LOG_LEVEL was set to debug

Like in title, sometimes sounds do not play (like Somba, Junkrat, McCree gun and possibly more) and sometimes objects do not render (like Pharah rockets, Zarya right click and possibly more). From my observations I've noticed (when playing as Sombra), weapon sound stops playing after first reload of the gun. After waiting some time (without firing a wepon) sound plays again, but again, stops after reloading. Something similar happens with Pharah rockets - firstly fired rocket renders fully (with smoke), but other ones don't show up (smoke also doesn't render). And similarly like with Sombra, after waiting some time without firing a weapon, first rocket renders properly, and the rest don't show up.

Also sometimes, when alt-tabbing and returning to the game, everything is black except a cursor (which I can move) and I can't do anything, but I'm not sure if this is related to DXVK. I couldn't get it to froze when these logs were created, but when it happens I will try to upload a new ones.

I haven't tested the game with latest NVIDIA drivers yet, because I'm still waiting for an update to show up in Arch repositories, so if someone can test the game with in the latest drivers, I would appreciate it.

d3d11 feature set

Most helpful comment

@davemint
The crashes are related to OW expecting function alignment in DXVK since the Hanzo rework update.
If you are able to build DXVK yourself, you can fix this by modifying build-win64.txt.
Either enable -O2 or add -falign-functions to the build flags and the crashes will be gone.

All 40 comments

I tried it on 396, issue still present

The game is known to require Stream Output (see #135), it's quite likely that the missing effects are related.

As for the sound, DXVK shouldn't interfere at all with anything sound-related, not sure what's going on there but there's not much i can do about that.

Sorry, I missed something: While I could replicate the Graphics issues, I couldn't do so for the audio ones, as in: I have no audio problems.

Additionally, if this Issue is part of #135, shouldn't it be closed? #298, #58 etc. were too

After running multiple tests (with and without DXVK) it looks like that these missing sounds are somehow tied to effects that are not always rendering (which happens only with DXVK). For example, when playing as Lucio and shooting from the gun, weapon sound plays when "sound wave" effect from the gun riffle is rendering. When this effect stops rendering (in Lucio example, when first "bullet" is fired), sound is also gone. Same thing with Sombra. So I think it is related to DXVK (and possibly Stream Output), but it's because how (weirdly) the game handles some weapons sounds.
@N00byKing Weird, very weird. Maybe my problem is somehow related to the NVIDIA driver? I will try to test the game with newer driver version and if the audio problem is gone, I will close the issue.

The Sounds are probably supposed to play after the effect was shown, if it aint shown, no sounds.

Regarding sound: It didn't happen to me at first, but, now that I played a bit longer, it did. Strangely, It didn't happen while playing as Tracer (which is how I tested it).

Also, another thing: After playing a little while, wine crashed with a Segmentation Fault, and I couldn't reproduce it on stock wine, only with DXVK installed.
Some Files:
Overwatch_d3d11.log
Overwatch_dxgi.log
I've also attached the console log, just in case it helps (There loads of "unimplemented function" talk going on in there...)
ConsoleLog.txt

OS: Elementary OS 0.4.1 Loki
GPU: Nvidia GTX860M
GPU Driver: 396.24.0
Wine Version: 3.7-staging
DXVK Version: 0.50

@N00byKing Have you compiled your own dll's? If you're getting a Segmentation Fault or an Address Boundary Error crash, I have a strong feeling that's due to Arch's mingw32 cross-compiler as I also been having them on Overwatch but only when I compiled my own dll's. If I run the pre-compiled 0.40 version everything works just fine, however, 0.50 also crashes after some time.

I reached this conclusion by cross-compiling the dll's on Ubuntu 18.04 and ran the game for 40 minutes without crashing, while if I compile them on my Arch rig the game usually crashes after 5 minutes of gameplay.

Didn't compile them myself, used the binaries from the releases page.

Any way to cross compile on arch? I really don't want to install Ubuntu just to build DXVK for overwatch

@sambow23 Unfortunately mingw is no longer available in Arch repositories. Try to compile mingw-w64-gcc + needed dependencies from AUR.

already did a while back
I use the ./package-release to build DXVK

Someone with RADV has no issues with the new Overwatch update

@N00byKing Yes, the weapon sounds works for most characters, but for some just stops after shooting for the first time - like Lucio or Sombra. Tracer worked fine for me (but I haven't played her for long).
And about segfault, I didn't have any (yet).

@doitsujin Can these sounds not playing be related to effects not being rendered, because of missing Stream Output? I would guess that effect would only be invisible, but sound would always play.

And after some more testing it looks like these effects (and sounds that plays when the effect is shown) which disappear are again rendered/played after waiting ~5 sec from the time that the effect disappeared from the game.
So shoot, wait <5 sec, shoot and effect/sound does not play.
Shoot, wait >5 sec, shoot and the effect/sound plays again.
I'm not sure if this is helpful, it's just something that I've noticed.

I wonder if the crashing is related to the new shader compiler, because @pshe94 is using the old driver, which contains the old compiler.

I have tried on both driver versions 390 & 396 and the crashing still happens with 0.50. @pshe94 what version of DXVK are you using?

I've updated DXVK to v0.50 from GitHub releases. No segmentation fault for me, but I've had the game freeze completely multiple times and had to kill the process.
wine.log
Overwatch_d3d11.log
Overwatch_dxgi.log

@pshe94 please disable nvapi in winecfg when using wine-staging, it won't work with DXVK.

Also, please update to a newer Nvidia driver to either 396.24 or 396.18.08.

Did you try the sound latency fix option in winecfg?

@doitsujin nvapi disabled and drivers updated to 396.24 (with the new compiler enabled), with DXVK v0.50. Game still freezes randomly, tested multiple times. These issues with sound and effects not playing but playing again after 5 sec are also still there. I've tested this on a new Arch installation, just to be sure.
Overwatch_d3d11.log
Overwatch_dxgi.log
wine.log
When I've returned to my old Arch installation (with 390.48-12 drivers and and installed DXVK 0.42 from GitHub releases) that freezing didn't happen (have played right now for over an hour, maybe I was just very lucky).

So in summary:

  • old driver, DXVK 0.42 - game does not freezes
  • old driver, DXVK 0.50 - game freezes
  • new driver, DXVK 0.50 - game freezes
  • In every case some effects and some sounds stop playing, but are rendered again after 5 sec since disappearance of that effect from the screen.

@jarrard I do not have option like that in winecfg.

@pshe94 i cannot debug the issue, sorry.

What I am aware of is that there is a critical bug that affects some people playing Overwatch with DXVK binaries compiled with certain versions of GCC, including the official 0.50 binaries, but that issue usually leads to crashes. But nobody has been able to debug that so far either.

I guess the solution for now if anyone wants to use the latest version is to compile DXVK with Ubuntu's mingw32 GCC which I have verified myself that works.

The sound issue, have you tried a option in that adjusts the pulseaudio latency? This option exists as a tick box in Lutris but I believe its just latency 60msec setting (PULSE_LATENCY_MSEC=60). Also tried disabling timer based scheduling?

Also try _winetricks sound=alsa_ or _padsp wine insert-application-name-here_ (OSS)

@jarrard I would be very surprised if this was related to the PulseAudio. Sound of shooting from the weapon is gone only when the effect of firing from the weapon does not render (at least that is what I've noticed after playing the game for a few hours). When the shooting effect renders, the shooting sound plays.
And this sound problem happens only for some characters. Rest of the sounds play properly (or I just haven't noticed them being gone). Also, without DXVK, all effects are rendered and all sounds play properly.

Anyway I've tried the Reduce PulseAudio latency option in Lutris, but problem was still there. I'm going to try the ALSA and OSS later, just to report if this is really problem with DXVK and PulseAudio not playing together nicely (but like @doitsujin wrote earlier, DXVK shouldn't interfere with sound).

Well you can try just running native wine d3d11 support without dxvk, if your lucky it may run. There are mixed results on the WineDB. (for purpose of testing sound/freezes)

You can also run apitrace under windows I found out recently, so that will probably help a bit.

@jarrard I did, everything works fine without DXVK (like I wrote earlier). All sounds and effects are playing properly.This happens only on DXVK.
I've tried running apitrace, both on Windows and on Linux under Wine, but it does not work (there are always only a few entries, look at file in the first post).

@pshe94 I have the same issues as you. I'm running DXVK 0.50 on 396.24 / Wine 3.7 Staging and get the sound bug and mine crashes after a few mins of playing. DXVK 0.42 doesn't crash. If anyone wants me to provide anything to help diagnose it let me know.

@davemint
The crashes are related to OW expecting function alignment in DXVK since the Hanzo rework update.
If you are able to build DXVK yourself, you can fix this by modifying build-win64.txt.
Either enable -O2 or add -falign-functions to the build flags and the crashes will be gone.

@varris1 Thanks! I added -O2 to build-win64.txt and it no longer crashes.

@varris1 Excellent that also fixed the issues that I had. Glad I don't have to boot a VM whenever I need to compile a new build.

:confused:

@varris1 : Either enable -O2 or add -falign-functions to the build flags and the crashes will be gone.

@davemint : Thanks! I added -O2 to build-win64.txt and it no longer crashes.
@Momohime : Excellent that also fixed the issues that I had.

README: meson configure -Dbuildtype=release
meson: release | full optimization, no debug info _( mean -O3 (?) see build.ninja and compile_commands.json)_

gcc:
-Os disables the following optimization flags: -falign-functions
-falign-functions=n | Enabled at levels -O2, -O3.

It looks like you all ignoring meson configure -Dbuildtype=release from README.
Or we need to call Ghostbusters.

@pchome
If it was that easy, the crashes wouldn't have showed up in the first place. Perhaps the value in the cross file overrides the flags set by build type.

EDIT: https://github.com/doitsujin/dxvk/pull/362

b78130defd4b3b19543ed4ce1244e607131814dc implements a rather dirty hack to make the game believe that Stream Output is supported (it is not). This reportedly fixes some of the sound and visual issues.

Confirming sound and visual issues are apparently fixed with https://github.com/doitsujin/dxvk/commit/b78130defd4b3b19543ed4ce1244e607131814dc.

Ironically FO4 did have sound issues similar to this also. But I might have found a fix for that, could be unrelated. I switched win10+eax on in winecfg and maybe that stopped certain sounds from cutting out. But maybe b78130d will also work for FO4?

I still get the same sound issues. I usually test by playing Sombra and firing her gun in different places over the map. Anyone else but @saboya tried the potential fix?

Works for me @davemint.
Are you sure you used the correct build?

@doitsujin Unfortunately, problem still persists. I've tested this in a new wine staging
3.8 prefix, with DXVK version r1154.b78130d and later r1159.667616b from here (both should include commit https://github.com/doitsujin/dxvk/commit/b78130defd4b3b19543ed4ce1244e607131814dc).

Overwatch_d3d11.log
Overwatch_dxgi.log
wine.log

@pshe94 I cannot debug the issue, but the game does require a proper implementation of Stream Output, which DXVK does not have yet. In theory it shouldn't affect sound at all, but the visual issues are probably caused by that.

Out of interest, is the name of your game executable actually Overwatch.exe (with a capital O)? If not, the workaround won't be applied.

@doitsujin Yes, it starts with capital O.
Like I wrote, sounds are related to effects. If effect is gone, so is sound. So if Stream Output is implemented, it theoretically should fix both effects and sounds.

Closing this since solving #135 should resolve the issue in the future.

@pshe94 are you starting Overwatch.exe directly or via launcher?

@baka0815 I've tried both methods, same result.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

AuroransSolis picture AuroransSolis  Â·  3Comments

knuxyl picture knuxyl  Â·  5Comments

Ahmed-E-86 picture Ahmed-E-86  Â·  4Comments

HunterCZ122 picture HunterCZ122  Â·  4Comments

t14462 picture t14462  Â·  4Comments