CyberFSR2: My Red Dead Redemption 2 Port - Can't get D3D12_Init to call
Hey! I absolutely love the idea behind this and I had something really similar in mind. However, I am not as good at writing in C++ as I am in C#. I am trying to port this over to Red Dead Redemption 2.
I’ve managed to find the viewport and applied some simple changes in hopes it would work.
struct CameraParams
{
float FoV; //0x0
float NearPlane; //0x4
float FarPlane; //0x8
};
//offset can be found by tinkering with in-game FOV slider.
auto mod = (uint64_t)GetModuleHandleW(L"RDR2.exe");
auto ptr1 = *((uintptr_t*)(mod + 0x3E806E0));
camParams = ((CameraParams*)(ptr1));
I am unable to get it to work correctly for some reason. The game refuses to load the DLL when named “nvngx.dll” but loads when named “d3d11.dll” but then the actual functionality of the DLL doesn’t work with D3D12_Init not being called. (tested by using print with console in DLL_PROCESS_ATTACH).
Tested in Cyberpunk and works flawless.
Do you have any ideas how I could make this work? I am very desperate haha.
Thank you, again.
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 3
- Comments: 25 (9 by maintainers)
https://github.com/RealIndica/RDRFSR2
I am using the legit version of rdr2. I will update to find the address by signature today so it shouldn’t matter what version of rdr2 you have unless it’s pre-dlss update.
edit : I won’t be supporting cracked versions, sorry.
Would love to know how nvngx.dll gets loaded in the first place because maybe I could force RDR2 to load it the way it should.
That got it working! nice. Weird because the reg edit wasn’t needed for me for the legit version.
I forgot to put ‘EnableSignatureOverride.reg’ and ‘DisableSignatureOverride.reg’ to release zip-file. Can you download ‘EnableSignatureOverride.reg’ from the repository and run it? It allows to bypass DLSS signature check.
Yeah sorry, no DLSS option, looks like it never gets loaded. Could you put up a fork with your edited files? Or share the diff with me? I guess I’m doing something wrong since I have no idea what I’m doing 🥲
Got it working! For some reason, the game seems to check if you have a supported GPU before going ahead and loading nvngx.dll, whereas cyberbug loads it pretty much without question and then unloads it if its not needed. Took a lot of debugging but will fork this repo and apply my edits. Thanks for the help dudes 😃
Some performance stats (i7 8700k, 6700-xt, 32gb ram) : native : 95 balanced : 120 ultra performance : 140