flathub / com.github.Eloston.UngoogledChromium

https://flathub.org/apps/details/com.github.Eloston.UngoogledChromium
52 stars 8 forks source link

With Flatpak's nvidia-525-105-17 no GPU acceleration #111

Closed Flashwalker closed 1 year ago

Flashwalker commented 1 year ago
Host driver: nvidia-525-105-17
Flatpak driver: nvidia-525-105-17
Result: No GPU acceleration ❌

image

Host driver: nvidia-525-105-17
Flatpak driver: nvidia-525-85-05 or nvidia-525-89-02
Result: GPU acceleration is OK ✅

image

Command:

export __NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME=nvidia PW_PRIME_RENDER_OFFLOAD=1
flatpak run --env=__NV_PRIME_RENDER_OFFLOAD=1 --env=__GLX_VENDOR_LIBRARY_NAME=nvidia --env=PW_PRIME_RENDER_OFFLOAD=1 \
    --branch=stable \
    --arch=x86_64 \
    --command=/app/bin/chromium \
    --file-forwarding \
    com.github.Eloston.UngoogledChromium \
    @@u \
        --enable-gpu-rasterization \
        --enable-accelerated-2d-canvas \
        --enable-accelerated-video-decode \
        --ignore-gpu-blocklist \
        --enable-unsafe-webgpu \
        --enable-zero-copy \
        --enable-features=CanvasOopRasterization,EnableDrDc,RawDraw,UseSkiaRenderer,Vulkan \
        --user-data-dir=/tmp/unchrfltmp \
        --custom-ntp=chrome://gpu \
        "$@" \
    @@

Graphics:

export __NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME=nvidia PW_PRIME_RENDER_OFFLOAD=1 
inxi -G
Graphics:
  Device-1: Intel HD Graphics 630 driver: i915 v: kernel
  Device-2: NVIDIA GP107M [GeForce GTX 1050 Mobile] driver: nvidia
    v: 525.105.17
  Device-3: Sunplus Innovation Integrated_Webcam_HD type: USB
    driver: uvcvideo
  Display: x11 server: X.Org v: 1.21.1.3 driver: X:
    loaded: modesetting,nvidia unloaded: fbdev,nouveau,vesa gpu: i915
    resolution: 1920x1080~60Hz
  OpenGL: renderer: NVIDIA GeForce GTX 1050/PCIe/SSE2
    v: 4.6.0 NVIDIA 525.105.17
rany2 commented 1 year ago

Host driver: nvidia-525-105-17 Flatpak driver: nvidia-525-105-17 Result: No GPU acceleration x

image

Host driver: nvidia-525-105-17 Flatpak driver: nvidia-525-85-05 or nvidia-525-89-02 Result: GPU acceleration is OK white_check_mark

image

Command:

export __NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME=nvidia PW_PRIME_RENDER_OFFLOAD=1
flatpak run --env=__NV_PRIME_RENDER_OFFLOAD=1 --env=__GLX_VENDOR_LIBRARY_NAME=nvidia --env=PW_PRIME_RENDER_OFFLOAD=1 \
    --branch=stable \
    --arch=x86_64 \
    --command=/app/bin/chromium \
    --file-forwarding \
    com.github.Eloston.UngoogledChromium \
    @@u \
        --enable-gpu-rasterization \
        --enable-accelerated-2d-canvas \
        --enable-accelerated-video-decode \
        --ignore-gpu-blocklist \
        --enable-unsafe-webgpu \
        --enable-zero-copy \
        --enable-features=CanvasOopRasterization,EnableDrDc,RawDraw,UseSkiaRenderer,Vulkan \
        --user-data-dir=/tmp/unchrfltmp \
        --custom-ntp=chrome://gpu \
        "$@" \
    @@

Graphics:

export __NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME=nvidia PW_PRIME_RENDER_OFFLOAD=1 
inxi -G
Graphics:
  Device-1: Intel HD Graphics 630 driver: i915 v: kernel
  Device-2: NVIDIA GP107M [GeForce GTX 1050 Mobile] driver: nvidia
    v: 525.105.17
  Device-3: Sunplus Innovation Integrated_Webcam_HD type: USB
    driver: uvcvideo
  Display: x11 server: X.Org v: 1.21.1.3 driver: X:
    loaded: modesetting,nvidia unloaded: fbdev,nouveau,vesa gpu: i915
    resolution: 1920x1080~60Hz
  OpenGL: renderer: NVIDIA GeForce GTX 1050/PCIe/SSE2
    v: 4.6.0 NVIDIA 525.105.17

It probably works with that driver because of Chromium's GPU whitelist. By default, Chromium will only function with specific driver versions the developers are sure will cause no issues.