diff options
Diffstat (limited to 'src/egl.c')
-rw-r--r-- | src/egl.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -455,6 +455,16 @@ bool gsr_egl_load(gsr_egl *self, gsr_window *window, bool is_monitor_capture, bo } gsr_egl_disable_vsync(self); + + if(self->gpu_info.vendor == GSR_GPU_VENDOR_NVIDIA) { + /* This fixes nvenc codecs unable to load on openSUSE tumbleweed because of a cuda error. Don't ask me why */ + const bool inside_flatpak = getenv("FLATPAK_ID") != NULL; + if(inside_flatpak) + system("flatpak-spawn --host -- nvidia-smi -f /dev/null"); + else + system("nvidia-smi -f /dev/null"); + } + return true; fail: |