I am having some tearing issues with embedded Qt 5 with the XCB backend. I have just realized that perhaps this causes it to default to GLX and I have heard that one has a far greater chance of eliminating tearing using EGL. I also know that Qt has an EGL backend for XCB but I have no idea how to switch between the two. What configuration or runtime flags can I use to force it to use the one instead of the other?
Asked
Active
Viewed 4,252 times
1 Answers
4
Set the QT_XCB_GL_INTEGRATION
env variable to xcb_egl
.
I don't see why this would eliminate tearing, which is instead typically created by lack of vsync, but there's that...

peppe
- 21,934
- 4
- 55
- 70
-
Ok this has no effect. I assumed that because eglfs apparently solves vsync issues for many egl on X11 might help. Do you think that eglfs with an X11 backend would make a difference? Also, how can I confirm that egl support was even compiled into XCB and that it is in fact using it? – Gerharddc Dec 15 '15 at 11:22
-
EGLFS is an entirely different thing, that doesn't use X11 at all (Qt opens `/dev/fb0` or similar and uses EGL to create OpenGL contextes over that). To be sure of what's happening, enable some debugging logging for the `qt.xcb.glintegration` category (aka set `QT_LOGGING_RULES="qt.xcb.*=true"` and run your application). – peppe Dec 15 '15 at 12:30
-
Hi yes I know EGLFS is very different but I know that there is an X11 backend as opposed to the standard KMS one for it even though it is mainly meant for development but I can't get that working. I am not seeing any logging output, is it being written to a file or do I need to set something else to see it? – Gerharddc Dec 15 '15 at 13:02
-
Ok the X11 backend on EGLFS behaves the same. I guess EGL isn't the solution then... – Gerharddc Dec 15 '15 at 16:08
-
Do you have vsync enabled or not? That's the big thing. – peppe Dec 15 '15 at 16:34
-
Yes I believe I do because now that I have EGLFS I can force it to be off and that makes things worse. I'm not sure if there is a xorg setting for it though. It does only tear when I am animating more than one item at a time in qml. I'm guessing this could be a qml vsync issue? – Gerharddc Dec 15 '15 at 16:38