NVIDIA (495) on sway tutorial + questions (Arch-based distros)

Had anyone managed to fix ‘argb8888 && xrgb8888’? I cant get any logs out of sway and this is all i have, running 510-39-01.

sway-git and wlroots-git don’t have the error for me

Currently the two linux distros i use are Void and Gentoo. I dont think i cam do that but will it be the same as building from master?

I built from source on github!

after installing arch and all the necessary -git stuff, and 510 driver

Xwayland sucks. i will go back to regular X, thanks for your help.

I’m loving Sway on Nvidia so far! Multiple monitors work great, there’s no screen tearing when scrolling on Firefox, resizing apps is fast, and games run wonderfully.

However, I’m running into major issues with every Electron app I run, and some XWayland ones such as xeyes. There are countless artifacts, including z-fighting, flickering, and weird redrawing issues.
I did notice all Element apps seem to run in XWayland (despite me setting the Ozone flags in ~/.config/electron-flags.conf), but forcing Wayland through directly passing the arguments --enable-features=UseOzonePlatform --ozone-platform=wayland to the program (Element Desktop as an example) does not seem to fix the rendering issues.

Here’s an example of the redrawing issues that occur with xeyes:

Has anyone else encountered these issues? Is there a current workaround? It’s pretty much the only thing keeping me from switching to it fully.

Maybe be helpful, Arch installing of Sway together to Gnome:

I followed the above video but wlroots-eglstream-git didn’t seem to do the job for me (RTX 2080 Super): sway was stalling on startup.
Using wlroots-git i/o wlroots-eglstream-git (which by the way doesn’t seem to be maintained anymore) did the trick. I’ve had flickers in the beginning but they seem to have disappeared after a reboot.
Thanks a lot to all this thread’s participant for putting all this together :)

This is becoming my favourite environment. The only issues that prevent me using this all the time (instead of i3) are:

If anyone got to the bottom of the electron issue please share! Looks like screen sharing is in the works.

Anyone test out the newest drivers to see if there is improvement, maybe there will be more supports with the kernel module being open sourced

What I’ve observed with Sway 1.7 on the 515.43.04 drivers:

  • wlroots-eglstreams has been discontinued after the maintainer’s GPU broke, so GBM is the only way forward now
  • Hardware cursor is still broken
  • Generally, flickering still happens sometimes randomly (the flicker seems worse under XWayland)
  • foot terminal still sees a lot of flickering every time the terminal needs to refresh
  • Lots of flickering in VS Code as well (using Wayland flags, don’t have the same problem with Signal Desktop which also uses Electron)
  • Screensharing is broken as others have discussed above
  • The newest release of wf-recorder (from 2020) is broken but the git release works fine
  • This official Nvidia post has a lot of info as well: Wayland information for r515 beta release

Honestly, not much has changed since 495 and most of the same issues are still there. The open source release is still alpha on GeForce cards and I had trouble booting my system even with the NVreg_OpenRmEnableUnsupportedGpus=1 option with the nvidia-open package. Hopefully it’ll allow contributors to help with development and make Nouveau better as well.

515.43.04 driver released with VK_EXT_external_memory_dma_buf and VK_EXT_image_drm_format_modifier and I can start sway with the Vulkan renderer.
I noticed there is no more flickering but when I open “dmenu”, sway crashes with an out of memory error and OpenGL/Xwayland applications are very slow.

The flickering seems to be gone when using the wlr vulkan renderer. I still get some pretty bad flickering in xwayland if fullscreen though.

Tried wlr vulkan renderer. xeyes and all chromium apps are still borked (flickering and part of frame not updating). Especially annoying in electron apps such VSCode and Discord

I’m assuming it has to do with a compatibility issue with wlroots because wayland on gnome even with the 5.10 drivers works pretty well without flickering on fedora

Most of the issues seem to be linked to explicit sync, at least the xwayland flickers you see on some applications is definitely by that and there are currently fixes on the way - xwayland glamor renders incorrectly on nvidia (#1317) · Issues · xorg / xserver · GitLab
As for the desktop flicker, it seems like sway needs to also adopt explicit sync to it’s compositor(vulkan strictly uses explicit sync hence why you don’t see weird shenanigans), not sure if that’ll happen soon, but I do know kde has explicit sync for it’s compositor refactor to come in 5.26 which has beta in September.
So at the moment it isn’t an nvidia driver issue, it’s just that nvidia driver has support only for the newer explicit sync and doesn’t use implicit sync which causes the entire stack to do flickers, black screens, going forward/backwards. I’d say either file an issue for sway or keep an eye in case it gets explicit sync supported on OpenGL(honestly can’t wait for kde to drop theirs, then only xwayland would be left)


I asked the KDE developer and he told me that there is no explicit sync feature in KDE Plasma 5.26. Even if this feature was added, he did not seem to believe that it could solve the problems on the NVIDIA side. Honestly, whenever I’m hopeful, I’m disappointed.

You spoke to Vlad Zahorodnii ? The main wayland dev at KDE ? Refactor surface state handling in preparation for explicit sync (#91) · Issues · Plasma / KWin · GitLab also this is literally their preparation for explicit sync…

EDIT: With milestone 5.26

I spoke with Xaver Hugl. He mentioned that there was a merge request for explict sync, but he said he didn’t think the NVidia driver had support for explict sync. Even though I remind him of what the NVidia developer said, he seems hopeless. Thinks it won’t help in practice.