This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM5728: Screen capture synchonized to VSYNC using DRM

Part Number: AM5728

Hi,

In trying to achieve 30 fps screen recording on Wayland, I've mapped DRM dumb buffers to 3 framebuffer IDs that I found using modetest. I've gotten this to work, however my resulting video has significant tearing. I figure I am not capturing the dumb buffers in sync with Wayland/EGL updating them. I tried to utilize the DRM_IOCTL_WAIT_VBLANK, but this only blocks until the next VBLANK (during which buffers are updated AFAIK) ; I want the time when the buffers are not being modified so I can safely capture them and feed into my Gstreamer pipeline.

Does anyone know of a way to access the raw Vsync signal in a userspace application (QT)? Any other tips/solutions are welcome.

Thanks,

Vishal