VirtualGL / virtualgl

Main VirtualGL repository
https://VirtualGL.org
Other
699 stars 106 forks source link

Blank screen on KDE with VirtualGL on EGL with NVIDIA #224

Open ehfd opened 1 year ago

ehfd commented 1 year ago

Environment: Ubuntu 22.04 with KDE, using vglrun +wm startplasma-x11 with Xvfb with export VGL_DISPLAY="egl".

What I am supposed to see (In the exact same condition except when using Xorg with NVIDIA 515 drivers): image

What I see: image

Is there any other considerations for using QT desktop environments with VirtualGL? I believe these issues may be affected by QT XCB.

ehfd commented 1 year ago

It works if the compositor is off, but when it's on, it doesn't work with or without +wm.

dcommander commented 1 year ago

Hard to say. Regular Qt applications work with VirtualGL, so I would need a better understanding of what Plasma is doing differently. Unfortunately, the odds that I will be able to look into this anytime soon are close to zero. TurboVNC doesn't officially support Plasma, so it falls into the category of "community support." That means that I am happy to integrate patches that fix issues with it, but diagnosing those issues isn't something I can do outside of the context of a paid support contract.

ehfd commented 1 year ago

I needed the compositor off anyways, so it will be kept that way for now...

ehfd commented 1 year ago

About how much would be the range of that paid contract, by the way? We have a potential sponsor.

dcommander commented 1 year ago

Contact me through e-mail: https://virtualgl.org/About/Contact

ehfd commented 1 year ago

There is one way to use VirtualGL + KWin Compositing: Set Rendering Backend: XRender, both OpenGL 3.0 and 2.1 fails now. Should be possible in command-line with something in the lines of kwriteconfig5 --file kwinrc --group Compositing --key ??? --type ???.

ehfd commented 1 year ago

XRender is not in Ubuntu 22.04.

Possible fix:

export QT_XCB_GL_INTEGRATION=xcb_egl export KWIN_OPENGL_INTERFACE=egl

From https://linuxreviews.org/HOWTO_enable_10-bit_color_on_Linux#KDE_Plasma_5.x.x_And_The_Deepin_Desktop_Envionment_Won.27t_Start

I will tell you if it is successful, and if you should add that to the docs or not.

ehfd commented 1 year ago

It's still broken. The last time I made it work was through llvmpipe. I guess it's something with the pixmaps that must be supported.

dcommander commented 1 year ago

Is there a way to tell Qt to use GLX (QT_OPENGL=desktop)? I'm just wondering if this is another facet of #226, which also seems to be related to Qt trying and failing to use our new EGL/X11 front end.

ehfd commented 1 year ago

I'm just wondering if this is another facet of https://github.com/VirtualGL/virtualgl/issues/226, which also seems to be related to Qt trying and failing to use our new EGL/X11 front end.

Possible, however the VLC issue arise additionally in 3.0.91. This issue is in 3.0.2 as well as 3.0.9x.

I am trying to make some time for reproducing this.

ehfd commented 1 year ago

Solved together with #226.

Nope, not solved.

image

Plus, an immense black border around Firefox.

ehfd commented 1 year ago

QT_OPENGL=desktop changes nothing.

dcommander commented 1 year ago

Yeah, I personally observed the issue after the VLC issue was fixed, and that issue affected the EGL/X11 front end, whereas this issue affects the GLX front end with the EGL back end. I suspect that it's because the EGL back end doesn't yet implement GLX_EXT_texture_from_pixmap.

ehfd commented 1 year ago

What would be the steps needed for support?

dcommander commented 1 year ago

Contact me through e-mail: https://virtualgl.org/About/Contact We would first need to determine whether the addition of GLX_EXT_texture_from_pixmap would really solve the problem, then I can give you a formal estimate for the cost of developing it.

dcommander commented 1 year ago

Any news on this front? It might be worth trying the latest pre-release build, which includes a fix for the EGL back end that affected other applications.

ehfd commented 1 year ago

Hi, Darrell. Always a pleasure to converse with you. I'll try it right away this weekend. So, this commit is in the latest dev build (in AWS S3), I assume?

dcommander commented 1 year ago

Lastest 3.1.x Stable build:

https://virtualgl.org/DeveloperInfo/PreReleases

ehfd commented 1 year ago

image

Unfortunately, basically the same issue. export QT_XCB_GL_INTEGRATION=xcb_egl and export KWIN_OPENGL_INTERFACE=egl shows the above.

image

With QT_OPENGL=desktop above.

Used the VirtualGL 3.1.1 PreRelease.

ehfd commented 11 months ago

image

I reproduce this situation with Chrome on KDE as well with compositing disabled.

ehfd commented 5 months ago

Related to: https://gitlab.gnome.org/GNOME/gtk/-/issues/4815

export KWIN_COMPOSE=N before invoking startplasma-x11 disables the compositor completely and doesn't result in the borders. Do not touch the KWin Compositor Settings post-invocation as that will activate the compositor and result in the black borders.