Search code examples
linuxqtx11vsynctearing

Avoiding screen tearing in linux + QT


As far as i understand X11 does not support double\triple buffer mechanism to avoid screen tearing. so I tried to use the openGL widgets, then i understood there no support what so ever for openGL+raspberry pi +qt4.

All i am asking is a very basic thing, catch frames from video camera, process them, and show on screen, and I am getting very! bad screen tearing.

I know QT5+WAYLAND+PI does has some sort(?) of support for openGL, will this help me solve this problem?(reasonably easy, and i mean not big changes in my application!!) is there is anything else i can do? (besides changing the source code of X11...) :)


Solution

  • If you are targeting Raspberry Pi I suggest you use the eglfs Qt 5 plugin, which means OpenGL through EGL without X11. Tearing is prevented by EGL and performance is very good.