Make Xwayland use EGLStream

I want Xwayland to use EGLStream instead of GBM. If I run Xwayland manually then I can use the -eglstream flag and everything is fine. However, I can’t figure out a way to do the same thing for the Xwayland server that is started automatically by kwin.

Is there an environment variable I can set, or an option in some configuration file, that would make kwin run Xwayland with the EGLStream backend?

Edit: the way I’ve worked around this for now is by creating a /usr/local/bin/Xwayland script that calls /usr/bin/Xwayland "$@" -eglstream

Can you comment on why you want to do this? Sounds a bit like an X/Y question.

That probably won’t work for long since Xwayland has already removed EGLStreams support.

Thank you both for your replies.

With GBM, I’m having terrible performance with some java apps I really need for work (namely, Burp Suite and Ghidra). Redraws are sluggish, and on some widgets even just typing text is slow. I’m also having weird display bugs sometimes. Using EGLStream is the only fix I’ve found and everything works perfectly smoothly with it. And yes, I’m worried of what will happen when EGLStream is removed.

I have a GTX 1060 with the 550.67 drivers. I think nvidia has started supporting GBM a while back, so I’m a bit surprised I’m having those issues.