jp7677 / dxvk-nvapi

Alternative NVAPI implementation on top of DXVK.
MIT License
353 stars 32 forks source link

Witcher 3: Wild Hunt LatencyFlex isn't working on AMD GPU #145

Closed In-line closed 9 months ago

In-line commented 9 months ago

As indicated by @ishitatsuyuki, https://github.com/ishitatsuyuki/LatencyFleX/issues/41#issuecomment-1747951932, there is currently no way to spoof GPU generation, which is needed to mask AMD GPU as NVIDIA GPU in Streamline-based games to enable NVIDIA Reflex.

18744.260:013c:0140:trace:loaddll:build_module Loaded L"C:\\windows\\system32\\latencyflex_layer.dll" at 0000000066280000: builtin
Successfully loaded latencyflex_layer.dll
LatencyFleX loaded and initialized successfully
NvAPI_Initialize: OK
NvAPI_QueryInterface (0x33c7358c): Unknown function ID
NvAPI_QueryInterface (0x593e8644): Unknown function ID
NvAPI_EnumPhysicalGPUs: OK
NvAPI_SYS_GetDriverAndBranchVersion: OK
NvAPI_GPU_GetArchInfo: NVIDIA or other suitable device not found or initialization failed

steam-292030.log

Saancreed commented 9 months ago

Can you try again with https://github.com/Saancreed/dxvk-nvapi/commit/234eaabc85d25db1c1ba3c9c4df48cf04fed0ce7 applied and let me know it this gets you any further? I haven't rebased this in months but at least the important part of this diff (the nvapi_gpu.cpp one) should still apply fairly easily.

FakeMichau commented 9 months ago

I've been spoofing NvAPI_GPU_GetArchInfo in effort to get LatencyFlex2 working. It does work but it would be nice to have an option of spoofing this externally, without needing to patch and compile.

jp7677 commented 9 months ago

Hi @In-line and @FakeMichau , does https://github.com/jp7677/dxvk-nvapi/pull/146 works for you? This is very similar to the commit Saancreed referred to.

FakeMichau commented 9 months ago

An environment variable would be preferred because spoofing Turing is useful at times. Mainly with CyberFSR (a mod that replaces DLSS with FSR) in games that use nvapi for checking the GPU, like Cyberpunk or Witcher 3. Otherwise a game specific bypass is needed. But I understand that this might be a niche use case outside the scope of this issue.

jp7677 commented 9 months ago

@FakeMichau Since both games you mentioned already support FSR directly, I would consider that indeed an esoteric scenario.

The PR here to spoof Pascal is ready, would be cool if you could confirm that it solves the LFX issue.