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

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

Closed
brad86m opened this issue Aug 1, 2022 · 9 comments
Closed

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

brad86m opened this issue Aug 1, 2022 · 9 comments

Comments

@brad86m
Copy link

brad86m commented Aug 1, 2022

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.

@doitsujin
Copy link
Owner

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.

@brad86m
Copy link
Author

brad86m commented Aug 1, 2022

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.

@doitsujin
Copy link
Owner

doitsujin commented Aug 1, 2022

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.

@adolfintel
Copy link
Contributor

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 :)

@brad86m
Copy link
Author

brad86m commented Aug 1, 2022

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'

@brad86m
Copy link
Author

brad86m commented Aug 1, 2022

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.

@brad86m brad86m closed this as completed Aug 1, 2022
@K0bin
Copy link
Collaborator

K0bin commented Aug 1, 2022

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.

@adolfintel
Copy link
Contributor

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.

@brad86m
Copy link
Author

brad86m commented Aug 1, 2022

Noted. Appreciate the help, gents.

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

No branches or pull requests

4 participants