jp7677 / dxvk-nvapi

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

The Elder Scrolls Online isn't showing the dlss option #99

Closed ltsdw closed 1 year ago

ltsdw commented 1 year ago

os: arch linux gpu: rtx 3050 cpu: i5 11400h

envar DXVK_NVAPI_LOG_LEVEL=info log when running the game:

DXVK-NVAPI v0.5.4 (eso64.exe)
NvAPI Device: NVIDIA GeForce RTX 3050 Laptop GPU (520.56.6)
NvAPI Output: \\.\DISPLAY1
NvAPI_Initialize: OK
NvAPI_QueryInterface (0x33c7358c): Unknown function ID
NvAPI_QueryInterface (0x593e8644): Unknown function ID
NvAPI_D3D_GetCurrentSLIState: OK
NvAPI_Unload: OK

log when running the tests.

DXVK-NVAPI v0.5.4 (nvapi64-tests.exe)
info:  Game: nvapi64-tests.exe
info:  DXVK: v1.10.3
info:  Built-in extension providers:
info:    Win32 WSI
info:    OpenVR
info:    OpenXR
info:  OpenVR: could not open registry key, status 2
info:  OpenVR: Failed to locate module
info:  Enabled instance extensions:
info:    VK_KHR_get_surface_capabilities2
info:    VK_KHR_surface
info:    VK_KHR_win32_surface
info:  NVIDIA GeForce RTX 3050 Laptop GPU:
info:    Driver: 520.56.6
info:    Vulkan: 1.3.205
info:    Memory Heap[0]:
info:      Size: 4096 MiB
info:      Flags: 0x1
info:      Memory Type[1]: Property Flags = 0x1
info:      Memory Type[4]: Property Flags = 0x7
info:    Memory Heap[1]:
info:      Size: 11834 MiB
info:      Flags: 0x0
info:      Memory Type[0]: Property Flags = 0x0
info:      Memory Type[2]: Property Flags = 0x6
info:      Memory Type[3]: Property Flags = 0xe
info:  Intel(R) UHD Graphics (TGL GT1):
info:    Driver: 22.2.99
info:    Vulkan: 1.3.230
info:    Memory Heap[0]:
info:      Size: 11834 MiB
info:      Flags: 0x1
info:      Memory Type[0]: Property Flags = 0xf
NvAPI Device: NVIDIA GeForce RTX 3050 Laptop GPU (520.56.6)
NvAPI Output: \\.\DISPLAY1
NvAPI_Initialize: OK
NvAPI_GetInterfaceVersionString: OK
--------------------------------
Interface version:              DXVK_NVAPI
NvAPI_SYS_GetDriverAndBranchVersion: OK
Driver version:                 520.56
Driver branch:                  r510_v0.5.4
NvAPI_GPU_CudaEnumComputeCapableGpus: OK
NvAPI_EnumPhysicalGPUs: OK
    ----------------------------
    GPU 0
NvAPI_GPU_GetGPUType: OK
    GPU type:                   2 (Discrete)
NvAPI_GPU_GetPCIIdentifiers: OK
    Device ID:                  0x25a210de
    Subsystem ID:               N/A
NvAPI_GPU_GetFullName: OK
    Full name:                  NVIDIA GeForce RTX 3050 Laptop GPU
NvAPI_GPU_GetBusId: OK
NvAPI_GPU_GetBusSlotId: OK
    Bus:Slot ID:                PCI:01:00
NvAPI_GetGPUIDfromPhysicalGPU: OK
    Board ID:                   0x100
NvAPI_GPU_GetPhysicalFrameBufferSize: OK
    Physical framebuffer size:  4096MB
NvAPI_GPU_GetAdapterIdFromPhysicalGpu: OK
    Adapter ID/LUID:            f2030000-00000000 (0x00000000/0x000003f2)
NvAPI_GPU_GetArchInfo: OK
    Architecture ID:            0x00000170 (Ampere)
    Implementation ID:          0x00000002
    Compute capable:            Yes (Compute GPU topology flags: 0x0b)
NvAPI_GPU_GetVbiosVersionString: OK
    VBIOS version:              N/A
NvAPI_GPU_GetDynamicPstatesInfoEx: No implementation
    Current GPU utilization:    N/A
    Current memory utilization: N/A
NvAPI_GPU_GetThermalSettings: No implementation
    Current GPU temperature:    N/A
NvAPI_GPU_GetCurrentPstate: No implementation
    Current performance state:  N/A
NvAPI_GPU_GetAllClockFrequencies: No implementation
    Current graphics clock:     N/A
    Current memory clock:       N/A
    Current video clock:        N/A
NvAPI_Unload: OK
===============================================================================
All tests passed (34 assertions in 1 test case)
adamdmoss commented 1 year ago

FWIW this game is one I've successfully tested with DLSS at some not-too-distant time in the past.

ltsdw commented 1 year ago

yup, maybe I'm doing something wrong, the game only shows the fsr option :/

jp7677 commented 1 year ago

Thanks for the detailed report. Which launcher are you using (e.g. Steam or Lutris)? First thing that comes to my mind is https://github.com/jp7677/dxvk-nvapi/wiki/Tips-and-tricks-for-usage-with-DXVK-NVAPI#dlss-2x

Do you have other games where DLSS is available?

ltsdw commented 1 year ago

Thanks for the detailed report. Which launcher are you using (e.g. Steam or Lutris)? First thing that comes to my mind is https://github.com/jp7677/dxvk-nvapi/wiki/Tips-and-tricks-for-usage-with-DXVK-NVAPI#dlss-2x

oh forgot to mention that, I'm running manually with wine. This one to be specific Wine-GE-Proton7-33 Released.

Tried with wine 7.19 compiled by me and wine 7.19 from the arch repository but both versions were segfaulting when launching the game (not related to this project I think it's an upstream thing).

I've read that section of the wiki and thought "uh oh, I don't see these dlls in the package I guess I don't need them in the new version of dxvk-nvapi anymore?"

So about these dlls (nvngx.dll and _nvngx.dll) I just need to list them as native at winecfg or at WINEDLLOVERRIDES, or I need them from another project first?

Also I do have a nvcuda at winecfg listed as "(???)" tried switching that to native, but didn't see any difference.

Do you have other games where DLSS is available?

Nope, not right now, bought this nb just to play this game and was the first and only one I tried so far.

But I don't know, I can see If I have some other game around here that I can install.

I think minecraft bedrock version has dlss, I can try that if needed.

jp7677 commented 1 year ago

Both files (nvngx.dll and _nvngx.dll) are part of the nvidia driver itself, you should find them in /lib64/nvidia/wine (or similar, depending on your driver installation). Those should be copied into the system32 folder of your wine prefix.

Also no wine override should be needed. nvcuda also needs no override.

ltsdw commented 1 year ago

So, I copied cp /usr/lib64/nvidia/wine/{_nvngx.dll,nvngx.dll} .local/share/Games/TESO/drive_c/windows/system32/, but still, no dlss option. Didn't override any nvngx or nvcuda. Am I still doing something wrong ain't I?

Also, I don't know if it's worth mentioning, but I'm using the nvidia-open package instead of the just "nvidia".

jp7677 commented 1 year ago

Could you try the DXVK device filter https://github.com/doitsujin/dxvk#device-filter to hide your integrated GPU? The DXVK logs should reflect that and only log your NV GPU.

jp7677 commented 1 year ago

Ah, no idea actually if DLSS works with the open source kernel driver works. Switching (even just temporary) to exclude another factor would certainly be sensible.

ltsdw commented 1 year ago

I'll try the dxvk device filter first, and after if it doesn't works, I'll try the nvidia proprietary driver (but I'll have to figure out why it hard freezes the entire system on boot, only thing that works is a force shutdown 🤣)

ltsdw commented 1 year ago

Ok, so, no, it still nothing.

pacman -Ss nvidia | grep installed
extra/egl-wayland 2:1.1.11-2 [installed]
extra/libvdpau 1.5-1 [installed]
extra/libxnvctrl 520.56.06-1 [installed]
extra/nvidia 520.56.06-8 [installed]
extra/nvidia-prime 1.0-4 [installed]
extra/nvidia-settings 520.56.06-1 [installed]
extra/nvidia-utils 520.56.06-2 [installed]

Screenshot-04-11-2022_13-08-00

Just for reference, if anyone by any mean have this nvidia proprietary freeze some day. Had to set the kernel parameter ibt=off FS#74886/FS#74891

~Also how can I check if the dxvk device filter thing worked? I set this, I don't know if it's right DXVK_FILTER_DEVICE_NAME="NVIDIA GeForce RTX 3050"~

eso64_d3d11.log eso64_dxgi.log

I'll keep the nvidia proprietary kernel driver just for consistency with everyone else then, and if I get to make the dlss work with the game I'll switch back.

jp7677 commented 1 year ago

mmh, that’s a pity. To be honest I’m running out of ideas. You could try Lutris. There is also nvidia-modprobe -u -c=0 in case not all nvidia modules got loaded (from https://github.com/jp7677/dxvk-nvapi/wiki/Tips-and-tricks-for-usage-with-DXVK-NVAPI#general) but not sure if that is still a thing.

About the DXVK filter, just try to set the filter to your intel GPU, that should hide your discrete card and certainly have effect :)

Just to be sure, you did disable the DXVk nvapi hack?

jp7677 commented 1 year ago

You could also check this thread for other wild ideas https://github.com/jp7677/dxvk-nvapi/issues/55#issuecomment-1017304875

ltsdw commented 1 year ago

Hahaha thank you so much, so I basically deleted the dxvk device filter that was set to my intel gpu, set the nvcuda as builtin and copied all _nvngx.dll and nvngx.dll back to the system32 directory and now the option appeared.

Again, thank you for your time and nice work ❤️

jp7677 commented 1 year ago

So for my understanding, compared with your initial setup you needed to copy both nvngx dlls and you had to set nvcuda explicitly to “built-in”?

PS also cool to hear ofc that it works now! :)

ltsdw commented 1 year ago

So for my understanding, compared with your initial setup you needed to copy both nvngx dlls and you had to set nvcuda explicitly to “built-in”?

PS also cool to hear ofc that it works now! :)

Yup, that was I did, (but I don't know if I messed up something initially and re-doing the whole thing corrected) and also I installed the proprietary kernel driver, I don't know if that affected at all, ~I will switch back to the open source one and edit this messages if all still good.~

Yes, it does work normally on open source kernel driver.