protonscr

Using an identical named proxy dll at the same time as dxvk

dxvkclosed
doitsujin/dxvk#2772 · opened 2022-08-01 by brad86m · updated 2022-08-01 · 9 comments · github
3 matching comments, n / p to jump
Bbrad86m 2022-08-01 github

I use DXVK on older titles, a lot of which require fixes and other tweaks for playing on modern systems. Unfortunately, a few of these games make use of dll files named the same as those DXVK uses. For example, d3d9.dll.
Would it be possible to add a proxy entry in the config file, so I can rename these and use together. Similar to how you can in Reshade.

Ddoitsujin maintainer 2022-08-01 github

DXVK needs to be the last DLL in the chain so I don't really see how this would work.

Also on Wine the problem doesn't really exist in the first place, since we're replacing the Windows/System32 DLLs there.

Bbrad86m 2022-08-01 github

I'm on Windows.
I was just wondering if it was possible since I use programs like ThirteenAG Widescreens scrips, Reshade/SweetFX all have an option within their config files that allows you to rename and use a proxy dll in conjunction with theirs.

Ddoitsujin maintainer 2022-08-01 github

Yes, but Reshade etc sit between the game and the underlying D3D9 implementation. DXVK is the D3D9 implementation, we can't simply go ahead and call someone else's Direct3DCreate9 instead of ours and expect that to somehow still work.

Aadolfintel 2022-08-01 github

A simple solution that I've used in the past when using WineD3D on Windows (hopefully works with DXVK too):

  • Rename d3d9.dll from DXVK to something with the same length like d9vk.dll
  • Use an hex editor on your special d3d9.dll and replace all occurrances of d3d9.dll with d9vk.dll
  • Put your special d3d9.dll in the game's folder and d9vk.dll in C:\Windows\SysWOW64 (assuming this is a 32 bit game)

I did not try this with DXVK so let me know if it works :)

Bbrad86m 2022-08-01 github

Thanks for the tip. I tried that, but only by putting both dll's in the games folder, as I was unsure that making it system wide is a good idea.

With both in the games folder, I get prompted with 'Failed to load real DirectX dll'

Bbrad86m 2022-08-01 github

I placed in the sysWOW64 as you mention, and it works great :) thank you.

If I have issues with it being in this system folder, I can always remove it.

KK0bin maintainer 2022-08-01 github

For ReShade in particular, you can also just create a folder somewhere, then put the DXVK dlls in there and set the environment variable "RESHADE_MODULE_PATH_OVERRIDE" to the path of your folder. That'll make ReShade load DXVK instead of regular Windows Direct3D.

Aadolfintel 2022-08-01 github

Good to know that my little trick works :)

To be clear, this feature is not something that DXVK can implement, it's your special d3d9.dll that needs a feature to load a specific d3d9 replacement instead of the system one, something like that environment variable that reshade has.

Bbrad86m 2022-08-01 github

Noted. Appreciate the help, gents.

DLLs