mmtrt / leagueoflegends

Unofficial league of legends snap repo
https://snapcraft.io/leagueoflegends
GNU Lesser General Public License v2.1
220 stars 27 forks source link

Nvidia graphics not used #177

Closed mirage2032 closed 3 years ago

mirage2032 commented 3 years ago

I've got the exact problem like here, #121 But the fix doesn't work for me :( I use prime-manager, got drivers installed fine but still can't find League in nvidia-smi

Other games work fine but League seems not to. nvidia-smi output:

+-----------------------------------------------------------------------------+
| NVIDIA-SMI 465.31       Driver Version: 465.31       CUDA Version: 11.3     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  NVIDIA GeForce ...  Off  | 00000000:01:00.0 Off |                  N/A |
| N/A   44C    P5    10W /  N/A |      5MiB /  5934MiB |      0%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+

+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|    0   N/A  N/A       800      G   /usr/lib/Xorg                       4MiB |
+-----------------------------------------------------------------------------+

In Steam i just set these launch options to the games

__NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME="nvidia" __VK_LAYER_NV_optimus="NVIDIA_only" %command%

or just

prime-run %command%

In Lutris I just enable "Nvidia Prime Render Offload".

I am running Arch Linux Down below you can see the output of "leagueoflegends.leagueoflegendsnv":

alx@Alx-Arch ~ $ leagueoflegends.leagueoflegendsnv 
WARNING: cgroup v2 is not fully supported yet, proceeding with partial confinement
fsync: warning: a previous shm file /wine-36357e-fsync was not properly removed
fsync: up and running.
000b:err:wineboot:process_run_key Error running cmd L"C:\\windows\\system32\\winemenubuilder.exe -r" (2).
000000.001|   OKAY| Running from cwd 'C:\Riot Games\League of Legends'.
000000.003| ALWAYS| Application Version:11.12.379.4946 - CL:3794946 - Build Date:Jun 03 2021 - Build Time:15:13:11
000000.005|   OKAY| Initial working directory: "C:\Riot Games\League of Legends"
000000.006|   OKAY| Current process: "C:\Riot Games\League of Legends\LeagueClient.exe"
000000.008|   OKAY| Command line arguments:
000000.010|   OKAY| Enabling Data API Dradis collection with endpoint: https://ekg.riotgames.com/messages
000000.017| ALWAYS| The following message is prepared to be sent to dradis:
Event Name: riot__rclient__event
common.os_platform: Windows
common.application_name: LeagueClient
common.application_version: 11.12.379.4946
common.cef_version: 74.1.19+gb62bacf+chromium-74.0.3729.157
common.installation_id: f8anXg==
common.locale: en_GB
common.os_version_major: 10
common.machine_id: Hj3Rn8NUykSpmFCMXxwz5A==
common.os_edition: Ultimate N, x64
common.os_version_minor: 
common.region: EUNE
common.session_id: d705a20c-e43b-8b44-88bd-924ca250e181
event_name: startup
crash_reporter: crashpad
000000.026| ALWAYS| Queued Dradis event to be sent.
000000.027| ALWAYS| Direct Launch enabled for league_of_legends.live in environment 'live' for app path 'C:\Riot Games\League of Legends\LeagueClient.exe' and install dir 'C:\Riot Games\League of Legends'
000000.031| ALWAYS| Found associated Riot Client install (c:/Riot Games/Riot Client/RiotClientServices.exe)
000000.086|   OKAY| Launched Riot Client with process 57
000000.087| ALWAYS| Riot Client started. Exiting with the expectation of being restarted (ExitForDirectLaunch).
008b:err:rpc:I_RpcGetBuffer no binding
0026:err:systray:add_sni_icon DBus: Request name failed! Not primary owner! code=3
0026:err:systray:add_sni_icon DBus error: (null)
000005.830|   OKAY| EventCollector: 0 events remaining after thread join
000005.831|   OKAY| Shut down EventCollector in 815 milliseconds
alx@Alx-Arch ~ $ LeagueClientUx pid: 35884
Waiting for port 44219
ALSA lib conf.c:3816:(config_file_open) cannot access file /etc/alsa/conf.d/10-samplerate.conf
ALSA lib conf.c:3736:(snd_config_hooks_call) function snd_config_hook_load returned error: No such file or directory
ALSA lib conf.c:4190:(snd_config_update_r) hooks failed, removing configuration
00fc:err:winediag:MIDIMAP_drvOpen No software synthesizer midi port found, Midi sound output probably won't work.
0190:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0190, blocked by 0142, retrying (60 sec)
0245:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0245, blocked by 0142, retrying (60 sec)
0190:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0190, blocked by 0142, retrying (60 sec)
0245:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0245, blocked by 0142, retrying (60 sec)
INTEL-MESA: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0
INTEL-MESA: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0
INTEL-MESA: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0
INTEL-MESA: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0
INTEL-MESA: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0
INTEL-MESA: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0
0190:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0190, blocked by 0142, retrying (60 sec)
0245:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0245, blocked by 0142, retrying (60 sec)
ALSA lib conf.c:3816:(config_file_open) cannot access file /etc/alsa/conf.d/10-samplerate.conf
ALSA lib conf.c:3736:(snd_config_hooks_call) function snd_config_hook_load returned error: No such file or directory
ALSA lib conf.c:4190:(snd_config_update_r) hooks failed, removing configuration
02cb:err:winediag:MIDIMAP_drvOpen No software synthesizer midi port found, Midi sound output probably won't work.
0190:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0190, blocked by 0142, retrying (60 sec)
0245:err:ntdll:RtlpWaitForCriticalSection section 0x7bd59920 "loader.c: loader_section" wait timed out in thread 0245, blocked by 0142, retrying (60 sec)

Is it possible to link the wine env to Lutris and play it from there? Maybe it works like that.

mmtrt commented 3 years ago

did you tried launch options with leagueoflegends command see if it does anything.

mirage2032 commented 3 years ago

Sorry for no response, it seems to be a problem with nvidia-smi not showing it. My framerate seems to be to big to be on cpu. I got constant 60fps. Tested it while my laptop was in Nvidia mode(everythin running on GPU) and Hybrid mode, not showing either way in Nvidia-smi but fps was the same.