I’ve been going around in circles for hours trying to figure out why my snap (an electron app) on a Raspberry Pi (latest OS) does not have any GPU acceleration enabled. Iv googlged and search these forums and im still stuck, would love some help here.
As you can see from the attached image, all acceleration has been disabled. The app runs terribly.
It looks like theres some sort of driver issue as im seeing in the logs:
- libGL Error: Failed to load driver: vc4
- MESA-LOADER: failed to open vc4
- vkCreateInstance: Found no drivers!
Im using the standard plugs as mentioned in the builder docs here: https://www.electron.build/configuration/snap.html
Also tried adding the libglu1-mesa package to stage packages, which I picked up from this article: snapcraft.io/docs/gpu-support
Im using electron-builder however and I cannot see a way to specify the “desktop-glib-only” part of that config in the electron-builder config (config in above link)
I feel like this should be a pretty common issue, what am I missing here? can any assist before i pull all my hair out? Thanks in advance
More info
- Raspberry Pi 4B / Latest Raspberry Pi OS
- The snap in question: vuepilot
Context (The full trace on app start up):
libGL error: MESA-LOADER: failed to open vc4 (search paths /snap/vuepilot/101/gnome-platform/usr/lib/aarch64-linux-gnu/dri)
libGL error: failed to load driver: vc4
libGL error: MESA-LOADER: failed to open vc4 (search paths /snap/vuepilot/101/gnome-platform/usr/lib/aarch64-linux-gnu/dri)
libGL error: failed to load driver: vc4
libGL error: MESA-LOADER: failed to open swrast (search paths /snap/vuepilot/101/gnome-platform/usr/lib/aarch64-linux-gnu/dri)
libGL error: failed to load driver: swrast
11:13:27.923 ⺠SNAP env is defined, updater is disabled
11:13:27.935 ⺠checkForUpdatesAndNotify called, downloadPromise is null
[2967773:0212/111327.935597:ERROR:angle_platform_impl.cc(44)] Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2967773:0212/111327.936900:ERROR:gl_display.cc(520)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2967773:0212/111327.937188:ERROR:gl_display.cc(795)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type
[2967773:0212/111327.944836:ERROR:angle_platform_impl.cc(44)] Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2967773:0212/111327.945113:ERROR:gl_display.cc(520)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2967773:0212/111327.945604:ERROR:gl_display.cc(795)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED
[2967773:0212/111327.945902:ERROR:gl_display.cc(829)] Initialization of all EGL display types failed.
[2967773:0212/111327.946236:ERROR:gl_ozone_egl.cc(26)] GLDisplayEGL::Initialize failed.
[2967773:0212/111328.003820:ERROR:angle_platform_impl.cc(44)] Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2967773:0212/111328.004147:ERROR:gl_display.cc(520)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2967773:0212/111328.004316:ERROR:gl_display.cc(795)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type
[2967773:0212/111328.008252:ERROR:angle_platform_impl.cc(44)] Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2967773:0212/111328.008547:ERROR:gl_display.cc(520)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2967773:0212/111328.008692:ERROR:gl_display.cc(795)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED
[2967773:0212/111328.008826:ERROR:gl_display.cc(829)] Initialization of all EGL display types failed.
[2967773:0212/111328.008966:ERROR:gl_ozone_egl.cc(26)] GLDisplayEGL::Initialize failed.
[2967773:0212/111328.014692:ERROR:viz_main_impl.cc(196)] Exiting GPU process due to errors during initialization
libGL error: MESA-LOADER: failed to open vc4 (search paths /snap/vuepilot/101/gnome-platform/usr/lib/aarch64-linux-gnu/dri)
libGL error: failed to load driver: vc4
libGL error: MESA-LOADER: failed to open vc4 (search paths /snap/vuepilot/101/gnome-platform/usr/lib/aarch64-linux-gnu/dri)
libGL error: failed to load driver: vc4
libGL error: MESA-LOADER: failed to open swrast (search paths /snap/vuepilot/101/gnome-platform/usr/lib/aarch64-linux-gnu/dri)
libGL error: failed to load driver: swrast
[2967818:0212/111328.386543:ERROR:angle_platform_impl.cc(44)] Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1056 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2967818:0212/111328.387101:ERROR:gl_display.cc(520)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.