Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[d3d9] Tomb Raider: Legend has some form of flickering with DXVK, does not occur with wined3d #4319

Closed
Leopard1907 opened this issue Oct 3, 2024 · 15 comments · Fixed by #4442
Assignees
Labels

Comments

@Leopard1907
Copy link
Contributor

Leopard1907 commented Oct 3, 2024

Software information

Tomb Raider: Legend, GOG copy, all settings maxed, everything enabled

Ekran Görüntüsü_20241004_000622

System information

  • GPU: 7900 XTX
  • Driver: Mesa 24.2.3
  • Wine version: Proton Experimental
  • DXVK version: Whatever Experimental has and also tested with latest release, occurs with master too

Apitrace file(s)

  • wined3d trace:

https://drive.google.com/file/d/1l1bGAeI62rfjLC91BePooemQTipn6i0H/view?usp=sharing

  • dxvk trace:

https://drive.google.com/file/d/1_k7pPDNML1ki_AWsHQKdd7iXhv0TfFJh/view?usp=sharing

Log files

steam-heroic-Tomb Raider Legend.log

Has this in it but not sure if that is related:

warn:  Failed to create global buffer:
warn:    size:  157810696
warn:    usage: 1ff
warn:    type:  0
warn:  D3D9DeviceEx::SetRenderState: Unhandled render state 181

Video that shows the issue

https://youtu.be/PGoJLkdbvvA?si=c6WlcYPici43iT79

@K0bin K0bin added the d3d9 label Oct 3, 2024
@K0bin K0bin self-assigned this Oct 3, 2024
@K0bin
Copy link
Collaborator

K0bin commented Oct 3, 2024

Looks like an issue with a depth prepass. That buffer error is definitely interesting too. I'll take a look tomorrow.

@doitsujin
Copy link
Owner

The buffer error is already fixed on master and not related.

@mrdeathjr28
Copy link

in my case dont appear this flickering in same scene using dxvk 2.4.1

trlc

@K0bin
Copy link
Collaborator

K0bin commented Oct 4, 2024

I'm not seeing any issues when replaying the apitraces on Nvidia.

EDIT: Enabling strict float emulation makes it show up on Nvidia too.

@Blisto91
Copy link
Contributor

Blisto91 commented Oct 4, 2024

@Leopard1907 Out of curiosity could you try running it with d3d9.invariantPosition = False

@Leopard1907
Copy link
Contributor Author

in my case dont appear this flickering in same scene using dxvk 2.4.1

In your case... you didnt have enabled everything there 🤣 But you have to enable everything to start reproducing it. So first create in a registry ExtendedDialog and enable it. After that enable everything with -setup switch, so make sure it is same settings just like on picture that he posted. There are more setting hidden there, that he didnt showed, but i assume he didnt touched that. 👯 If you do exactly that, then we can figure out if bug is RDNA specific (if it happens also for you with everything enabled) or maybe just happens on RDNA specific ASIC. like his card (if it dont happen for you with everything enabled)..

Yes, i didnt touch those "Dev" options.

Ekran Görüntüsü_20241004_135214

@Leopard1907
Copy link
Contributor Author

@Leopard1907 Out of curiosity could you try running it with d3d9.invariantPosition = False

Yep, that fixes the issue.

@qinlili23333
Copy link
Contributor

qinlili23333 commented Oct 4, 2024

image

Hardware related issue I think.
Cannot reproduce on Nvidia & Windows.

Edit: according to PCGW, this game has broken physics when running over 60 fps. Can you test again under 60hz?

PS: The game seems lock the usage of Windows key on keyboard in setup dialog.

@Blisto91
Copy link
Contributor

We've found that the issue shows itself when d3d9.floatEmulation is set to Strict which is only default on radv, nvk and amdvlk open as of writing.

@Leopard1907
Copy link
Contributor Author

@qinlili23333 Can you try with dxvk master?

@qinlili23333
Copy link
Contributor

qinlili23333 commented Nov 8, 2024

@qinlili23333 Can you try with dxvk master?

Interesting. I can reproduce on master 8584fc7.

Video: https://youtu.be/LV9gVc3juSs
Device: RTX 4080 Laptop 565.90 (Windows 11 23H2)

@Leopard1907
Copy link
Contributor Author

Yes, as expected. MR linked above enables same behaviour for NV driver too now so you have same behaviour as RADV now. So not a driver or hw specific issue.

Strict: Use a slower but more correct approach. Necessary for some games

@mrdeathjr28
https://github.com/doitsujin/dxvk/blob/master/dxvk.conf#L489

Probably should be able to repro too with his Intel if he sets this to Strict.

@qinlili23333
Copy link
Contributor

Yes, as expected. MR linked above enables same behaviour for NV driver too now so you have same behaviour as RADV now. So not a driver or hw specific issue.

Strict: Use a slower but more correct approach. Necessary for some games

@mrdeathjr28 https://github.com/doitsujin/dxvk/blob/master/dxvk.conf#L489

Probably should be able to repro too with his Intel if he sets this to Strict.

d3d9.floatEmulation=False fix for me.
Maybe we need to add a config for this game, or maybe strict emulation need to be reverted

@qinlili23333
Copy link
Contributor

Yes, as expected. MR linked above enables same behaviour for NV driver too now so you have same behaviour as RADV now. So not a driver or hw specific issue.

Strict: Use a slower but more correct approach. Necessary for some games

@mrdeathjr28 https://github.com/doitsujin/dxvk/blob/master/dxvk.conf#L489

Probably should be able to repro too with his Intel if he sets this to Strict.

Verified on Intel Xe 80eu (1135G7) 101.5768 (24H2), if set to Strict, same issue.

@qinlili23333
Copy link
Contributor

I've found something already in config

    /* Tomb Raider: Legend, Anniversary, Underworld  *
     * Read from a buffer created with:              *
     * D3DPOOL_DEFAULT,                              *
     * D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY buffer. *
     * Legend flickers with next gen content option. */
    { R"(\\(trl|tra|tru)\.exe$)", {{
      { "d3d9.cachedDynamicBuffers",        "True" },
      { "d3d9.maxFrameRate",                "60" },
    }} },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
6 participants