protonscr

[d3d9] THE KING OF FIGHTERS XIII: STEAM EDITION: Missing Graphics

dxvkclosed bugd3d9
doitsujin/dxvk#3472 · opened 2023-06-03 by waspennator · updated 2023-06-14 · 9 comments · github
Wwaspennator 2023-06-03 github

Was testing out this game on my steam deck when I noticed it had some weird graphical quirks going on that were also reported on the proton github page for this game (But didn't seem to be present when using proton 4.11-13) so I figured i'd hop on my windows laptop to test it out on there with DXVK and noticed these issues (Since testing it out on deck requires a command to skip the videos or else it crashes the game and dunno how to setup the commands to skip videos and make a log file)

DXVK:
KOF DXVK 1
KOF DXVK 2

How it should look:
KOF 1
KOF 2

Software information

THE KING OF FIGHTERS XIII: STEAM EDITION

System information

  • GPU: AMD Van Gogh for Steam Deck, GTX 1650 for the Windows Laptop
  • Driver: Mesa 22.2.0 for Steam Deck, Nvidia 531.79 for Windows Laptop
  • Wine version: 8.0 on Steam Deck
  • DXVK version: https://github.com/doitsujin/dxvk/actions/runs/5126995523, also tested on latest dev build available at time (Respect all PS input elements for registers)

Apitrace file(s)

For instructions on how to use apitrace, see: https://github.com/doitsujin/dxvk/wiki/Using-Apitrace

Log files

Please attach Proton or Wine logs as a text file:

  • When using Proton, set the Steam launch options for your game to PROTON_LOG=1 %command% and attach the corresponding steam-xxxxx.log file in your home directory.
  • When using regular Wine, use wine game.exe > game.log 2>&1 and attach the resulting game.log file.

kofxiii_d3d9.log

WWinterSnowfall 2023-06-03 github

Looks good here with my self-built e9e0949.

KOFXIII

P.S.: Note that I'm launching it with: kof13_win32_Release.exe -v -r (see here)

Wwaspennator 2023-06-03 github

On Deck at least, the only launch command I used was the -v one cause the game would die trying to play the intro FMV after the logos. Was able to replicate the graphical issue on there for all versions up to 4.11-13, though I couldn't test out 5.0-10 because it would not launch on my deck.

On Windows if I run it normally it looks visually fine, albeit things are running faster cause the game doesn't have a framerate cap. But if I toss in DXVK, while it does run at a more normal framerate (I know why it was capped) the visual issues just happen, like it only renders specific assets on one side and everything else is just not showing up. (If you jump over your opponent, you'll go invisible while your opponent shows up instead.)

I've seen some reports on protondb (Most on deck, some on non-deck devices) mentioning missing graphics, and there was one other person on the proton github page for this game who had similar visual issues that i'm having.

WWinterSnowfall 2023-06-03 github

I have played a few matches and not noticed anything off. That being said PCGW does mention graphical issues on AMD cards with the game. Not sure if anyone on AMD has tested it up till now.

KK0bin maintainer 2023-06-03 github

The apitrace replays fine (mines a couple of apitrace bugs).

BBlisto91 2023-06-03 github

I can reproduce the issue. But only when i do a resolution change in the game, not out of the box without switching resolution after having started.

Edit: Actually also when started using Windowed mode or borderless

WWinterSnowfall 2023-06-03 github

We've talked about it on Discord, but for the sake of clarity I'll sum it up here as well: the bug is related to the game depending on proper device lost behavior (it calls TestCooperativeLevel() then attempts a device reset) and also the proper release of D3DPOOL_DEFAULT resources on device reset. I've captured two traces, one with WineD3D and one with DXVK to highlight the differences (these can be seen even on the first 2 frames).

KK0bin maintainer 2023-06-03 github

To go a bit more into detail, it seems like the game relies on D3D9 failing in Reset when there's any alive D3DPOOL_DEFAULT resources.

That's just a theory for now.

KK0bin maintainer 2023-06-04 github

After a bunch of experimentation, we've basically confirmed that theory now.

Wwaspennator 2023-06-14 github

Can confirm on my end the graphics look fine now using the latest dev build, thanks.

Proton versions

Launch options