RPi4 and constant screen tearing (no VSync)

Hi! Another day, another problem :slight_smile:
It seams like vertical synchronization is not working for me at all. My ofApp::setup() starts with:


As a test I’m running a simple project that is drawing 4 bars moving from side to side. It keeps stable 60fps but tearing is visible at all times. Mostly by the screens edge, but can also jump to the middle.

No temperature or voltage warnings. CPU at 20%.

Hardware: RPi4B+ 8GB RAM; 16GB microSD; FullHD 60Hz display.

Software: RaspberryOS Lite (Debian Buster), openFrameworks 0.11.0, GL fake KMS driver enabled, compositor disabled, forced turbo in config.txt.
Most of my setup described here: RPi4 + Buster Lite + oF 0.11.0

Mentioned it another thread (here: Arm video tearing), but no response and I’m still struggling finding solution.


I dont have experience on last oF and rpi4 but i worked a lot on rpi3b+ and prev oF (dont remember if 10 or 9.8) and did not see that behaviour.

Seems like last oF use same window system as other platforms using the opengl raspberry driver…

Maybe you can try disabling opengl driver and use previous oF version that will use ofAppEGLWindow

thank for the tip. Tomorrow I’ll try to make my app run with Legacy graphic drivers. Maybe this will work.

I have some experience with oF10 on RPi3B+. I was really excited with RPi4, hoping to create something with oF that will use the extra computing power. But the VSync issue is making me nuts!

Anyway, today I’ve installed experimental kernel and VideoCore with rpi-update - still no luck.

I think the point is also to use previous window system not a GLFW one, legacy mode and EGL window, i think im not confusing the names

Quick update.

Tried with dtoverlay=vc4-kms-v3d driver. I get “NO SIGNAL” on my display as soon as I run the app.

Also tried updating to experimental linux 5.10 with ‘rpi-update’ and the dtoverlay=vc4-kms-v3d driver. Image is back, audio is missing, screen tearing persists (still no VSync).

Just did this week a project on rpi3A+ EGL window, raspbian stretch and have some video playing with ofxOmxplayer and not tearing with and without X

@pandereto, I worked with oF on RPi3 before and I had none of these issues. This seams to be related specifically with the graphic driver used in RPi4.

Happy to inform that after performing sudo apt-get dist-upgrade
and recompiling the app sudo make clean && sudo make,
screen tearing is gone. Solid 60fps, no VSync issues. Not sure which system component or library was responsible for it but happy that it’s fixed now.

1 Like