protonscr

[d3d9] Duke Nukem Forever → the shadows are not "soft"

dxvkclosed
doitsujin/dxvk#1641 · opened 2020-05-25 by NerosTie · updated 2020-06-02 · 27 comments · github
NNerosTie 2020-05-25 github

With DXVK:
Screenshot_20200525_210441

With WineD3D:
Screenshot_20200525_210308

It's not the same bug as https://github.com/doitsujin/dxvk/issues/1639, it would be like this instead:
Screenshot_20200525_210700

System information

  • GPU: Nvidia GeForce GT 730M
  • Driver: nvidia-vulkan 440.66.14
  • Wine version: Proton 5.0
  • DXVK version: 1297

Apitrace file(s)

https://mega.nz/file/yzYXDQha#tSJKWoMY2xDloDO-6RkSKUanxKk_CA8yz7yIx-Vrjb4

Log files

steam-57900-wined3d.log
steam-57900-dxvk.log

CCME42 2020-05-25 github

The trace is working fine and it seems like DF24 is not being used, so i guess this was created with wined3d, can you record one with dxvk?

Mmisyltoad 2020-05-26 github

The order/swizzle on my FETCH4 might be incorrect -- but thats an easy fix if I can get a trace to figure that out.

NNerosTie 2020-05-26 github
Mmisyltoad 2020-05-27 github

Should be fixed now :)

NNerosTie 2020-05-27 github

It's way better!

But when I look closer, the issue is still here:

dxvk:
Screenshot_20200527_103503

wined3d:
Screenshot_20200527_103655

Tested with dxvk v1305

Mmisyltoad 2020-05-27 github

Can you try reverting 2fc00a331b952b1ecba9813d892f1edf80688c68? Otherwise at this point I do not know :<

Mmisyltoad 2020-05-27 github

also if you can can you provide a trace close up with DXVK so I can check it against AMD native? It could just be like that...

NNerosTie 2020-05-27 github

Nope, it's the same thing as the first screenshot:

Screenshot_20200527_104419

I think you have to reopen the issue 🤷

edit: ok, I will make a new trace

Mmisyltoad 2020-05-27 github

can you provide a trace close up with DXVK so I can check it against AMD native? It could just be like that...

if it is, then i can fudge it to use the path it does in wined3d

Mmisyltoad 2020-05-27 github

Should be fixed for good now :)

NNerosTie 2020-05-27 github

Again, it's better!

BUT (I know..) there is still a difference with wined3d:

With wined3d, you have a lot of "noise":
Screenshot_20200527_134931

Which is not here with dxvk:
Screenshot_20200527_135046

Plus, you can notice there are black lines we shouldn't see.

Ddoitsujin maintainer 2020-05-27 github

iirc the game uses a different method to sample shadows on dxvk compared to wined3d, so differences are expected.

Mmisyltoad 2020-05-27 github

If you can get a dxvk trace super up close I can validate that on native and see if anything is amiss. Sorry to be a pain

NNerosTie 2020-05-27 github
NNerosTie 2020-06-01 github

Can this issue be reopened?

Mmisyltoad 2020-06-01 github

This should be fixed now 👍

NNerosTie 2020-06-01 github

The black bars are gone!

But he "noise" is still not here:

WINED3D:
Screenshot_20200601_144510

DXVK:
Screenshot_20200601_144437

Which one is supposed to be the right one?

Mmisyltoad 2020-06-01 github

Its a different shadow path.

NNerosTie 2020-06-02 github

What's does it mean? Is the "noise" not being here normal?

Mmisyltoad 2020-06-02 github

For the shadow path on AMD, yes.

NNerosTie 2020-06-02 github

But I have a Nvidia GPU.

KK0bin maintainer 2020-06-02 github

It's using D3D9 driver hacks that Nvidia usually doesn't have.

NNerosTie 2020-06-02 github

Buy I have this "noise" with my Nvidia GPU with WINED3D. Why not with DXVK? I don't understand :/

Mmisyltoad 2020-06-02 github

Because we expose DF24 which uses a different shadow path.

NNerosTie 2020-06-02 github

I guess everything's normal then.

Let's say Duke Nukem Forever is... done™

KK0bin maintainer 2020-06-02 github

Duke Nukem Forever has two different ways to filter shadows:
With DXVK the game uses the one primarily built for AMD GPUs. That is because DXVK supports D3D9 driver hacks that typically Nvidia's Windows D3D9 driver doesn't support. DXVK also supports those on Nvidia GPUs.
When those hacks (DF24 in particular here) aren't present (as would be the case on Nvidia Windows D3D9 drivers), the game does something else to filter shadows.

Proton versions

Upstream links