Cura
Cura copied to clipboard
Wayland - Viewport doesn't render
Cura Version
5.7.0
Operating System
Arch Linux, Hyprland (wayland), nvidia gtx 1060
Printer
Creality Ender 5
Reproduction steps
- Launch the cura flatpak in a wayland compositor (in my case hyprland)
Actual results
All UI elements render fine apart from the view port in the center. When running the application under xwayland it works fine.
Expected results
All UI items render fine (like they do on xorg).
Add your .zip and screenshots here ⬇️
Does this also happen for the appimage? We don't officially support the flatpack, so there might be subtle differences between the two that cause this issue.
Also, can you provide the log files? It's a bit hard to debug without them
Same here. With official AppImage on fedora 39
Same here. With official AppImage 5.7.1, with rpm version 5.5.0 and flatpak 5.7.1, both on Fedora 39 and Fedora 40 Only chance to "somewhat" run it is to set QT_QPA_PLATFORM=xcb before running it.
Arch Linux with Nvidia/KDE Plasma 6/Wayland
Same issue. Works with these arguments -platform xcb -platformtheme gtk3 but it's a flickery mess. I guess, I have to wait for the much hyped "Explicit Sync" patch. Atleast can slice and print!
Had the same issue on Fedora 39 and 40 with Flatpak.
Setting QT_QPA_PLATFORM=xcb in Environment in FlatSeal fixed it for me. For me it runs smooth on Fedora 40 with Gnome 46.1.
It's nowhere near to "smooth". It does run, however, it flickers a lot, and sometimes I have a white window that only refreshes when I rotate or zoom. In addition, it takes ages until the model gets a first rendering. I did not experience this when I was running my desktop in an X session. Only after I moved to Wayland.
Good news everyone! Not a fix but a non flickery workaround.
According to this hint I tried to tweak EGL which raised an error before: https://wiki.archlinux.org/title/OpenGL#OpenGL_over_Vulkan_(Zink)
At least 5.7.1 seem to run fine in pure Wayland on my Nvidia RTX 4060 and nvidia-dkms
.
Running cura with these two environment variables seem to be enough for me:
__EGL_VENDOR_LIBRARY_FILENAMES=/usr/share/glvnd/egl_vendor.d/50_mesa.json MESA_LOADER_DRIVER_OVERRIDE=zink cura
You'll probably also need QT_QPA_PLATFORM="wayland;xcb"
which is set by my global env file which I share for free too:
# /etc/profile.d/wayland.sh
# Tweaks mostly from: https://wiki.archlinux.org/title/Wayland
export QT_QPA_PLATFORM="wayland;xcb"
export SDL_VIDEODRIVER="wayland,x11"
export CLUTTER_BACKEND=wayland
export GBM_BACKEND=nvidia-drm
export __GLX_VENDOR_LIBRARY_NAME=nvidia
export ELECTRON_OZONE_PLATFORM_HINT=wayland
# GTK to X11
#GDK_BACKEND=x11
# Thunderbird and Firefox
export MOZ_ENABLE_WAYLAND=1
# LibreOffice
# /etc/profile.d/libreoffice-still.sh
export SAL_USE_VCLPLUGIN=qt6
# Java blank screen?
#export _JAVA_AWT_WM_NONREPARENTING=1
Rule of thumb for NVidia and Wayland: No xwayland.
This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further.
The above seem to fix the flickering at least thank you. I can not use it per say, still no build plate, but it at least is not flickering. What ever build Qidiprint is on it just works in Wayland, Hperland etc.. Its an older version of Cura though thats been reskined.
@basilverthorn I never had flickering in pure Wayland. The print bed and some UI was missing. Old workaround was using xwayland at the cost of flickering within Cura.
Do you run Cura in a pure Wayland session?
QT_QPA_PLATFORM=wayland cura
and add the Vulkan fix variables to get the bed and UI visualized.
Then cura or the Qt backend will truely use Wayland.
Yes I run in true Wayland or Hyprland. Migrating to Hyprland, but see the same thing in both. I will try this tomorrow if I can, working late today unfortnately. Fixed the flickering, but the build plate is still missing. I have resorted to just running Cura in a Windows VM atm as a work around.
So I tried the vulkan fix and QT_QPA and I know recieve: "Could not probe OpenGL. This program requires OpenGL 2.0 or higher. Please check your video card drivers." Trying to start Cura, the appimage runs, but does not have a build plate.
glxinfo shows:
glxinfo | grep "OpenGL version" OpenGL version string: 4.6.0 NVIDIA 550.76
env __GLX_VENDOR_LIBRARY_NAME=mesa __EGL_VENDOR_LIBRARY_FILENAMES=/usr/share/glvnd/egl_vendor.d/50_mesa.jsonMESA_LOADER_DRIVER_OVERRIDE=zink GALLIUM_DRIVER=zink cura MESA: error: ZINK: vkCreateInstance failed (VK_ERROR_INCOMPATIBLE_DRIVER) libEGL warning: egl: failed to create dri2 screen MESA: error: ZINK: vkCreateInstance failed (VK_ERROR_INCOMPATIBLE_DRIVER) libEGL warning: egl: failed to create dri2 screen qt.qpa.wayland: Failed to initialize EGL display 3001
cura ran by itself starts, just no build plate.
Still an issue anyone come up with solution? No build plate still.
Mesa seems to be broken on EGL/OpenGL at Qt level already: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11316
How did you get mesa 24.1.1 early on May 2th? Even Arch users got that version on June 6th. Can you downgrade mesa on your distribution to 24.1.0? We didn't find a better fix or workaround yet.
I am also on Hyprland but installed cura via the aur cura-bin
package, but I am using intel integrated graphics not NVIDIA. I am not experiencing this issue but (unrelated) I get a segfault when trying to open a file. #16815
Same here. With official AppImage 5.7.1, with rpm version 5.5.0 and flatpak 5.7.1, both on Fedora 39 and Fedora 40 Only chance to "somewhat" run it is to set QT_QPA_PLATFORM=xcb before running it.
How do you check that?
I have the same issue with AppImage 5.8.1. It's a Gentoo system with Nvidia graphics.