Skip to content

Tips and tricks for usage with DXVK NVAPI

Jens Peters edited this page Mar 17, 2024 · 21 revisions

This page contains known tips and tricks or workarounds for usage with DXVK-NVAPI.

General

DXVK-NVAPI honors DXVK device filter. Forcing to advertise only a specific GPU might solve issues in a multi-GPU setup. Additionally, running nvidia-modprobe -u -c=0 for loading NVIDIA's UVM kernel module might be needed on some systems before using CUDA related features like DLSS or PhysX.

DLSS 1.x

The current DLSS implementation in Proton/DXVK/VKD3D-Proton i.c.w the Linux NVIDIA driver only supports DLSS 2.x. DLSS is not available / cannot be enabled for games that wants to use DLSS 1.x. An example is "Battlefield V".

DLSS 2.x

DXVK-NVAPI uses entry points in VKD3D-Proton and DXVK for implementing DLSS relevant methods.

NVIDIA DLSS also requires nvngx.dll and _nvngx.dll to be present in the system32 directory of the Wine prefix. Proton and other popular game launchers copy the relevant files automatically when enabling NVAPI. Both files are part of the NVIDIA driver installation and are usually findable in /lib64/nvidia/wine/. Additionally the absence of the registry key FullPath (set to C:\Windows\system32) in HKEY_LOCAL_MACHINE\SOFTWARE\NVIDIA Corporation\Global\NGXCore might prevent NVNGX from initializing correctly.

DLSS 2.1.38 through 2.1.40

DLSS in this version range has a link-time dependency on nvcuda.dll and thus needs a CUDA implementation to be present in Wine. This should be given in a.o. Proton and Wine-Staging unless disabled with WINEDLLOVERRIDES. An example is "Watch Dogs: Legion".

Reflex

Reflex support in DXVK-NVAPI has two flavors.

  • Using entry points in VKD3D-Proton 2.12 and newer for D3D12, DXVK (still work-progress, https://github.com/doitsujin/dxvk/pull/3690) for D3D11, which in turn relies on a Vulkan device having support for the VK_NV_low_latency2 extension. The NVIDIA proprietary driver supports this extension since driver version R550.
  • Using LatencyFlex. See Installation for instructions for setting up the Vulkan layer and the Wine extensions. See why-latencyflex for a general context. The LatencyFlex implementation has preference when being detected.

PhysX

PhysX utilizes CUDA, thus nvcuda.dll must also be present in the Wine prefix. A suitable implementation for Wine can be found here. Wine-Staging unfortunately no longer ships nvcuda.dll. Note that nvcuda.dll found in regular/experimental Proton does not work since it only contains a stub implementation (see https://github.com/ValveSoftware/wine/pull/119). Additionally, the latest PhysX runtime should be used. Winetricks (or Protontricks) allows installing the PhysX runtime. Having both requirements fulfilled allows enabling "Interactive Paper Debris" and "Interactive Smoke & Fog" in "Batman: Arkham Knight".

See also this discussion and following posts on the GitHub Proton issues list for additional information for older PhysX implementations.

Game / application specifics

Marvel's Guardians of the Galaxy (gotg.exe)

This game can be started and DLSS itself works when NVAPI is present, but it is otherwise unplayable due to issues when an NVIDIA GPU is exposed. See https://github.com/HansKristian-Work/vkd3d-proton/issues/1216 and newer comments for more information.