From f35afcd7ae0d32cdf34625546b0fe28f6a71fd8b Mon Sep 17 00:00:00 2001 From: Aleix Pol Date: Fri, 7 Apr 2023 15:46:07 +0200 Subject: [PATCH] screencast: Still set the size to 0 for cursor-only frames Otherwise OBS glitches (and so does KPipeWire-based software) --- src/plugins/screencast/screencaststream.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugins/screencast/screencaststream.cpp b/src/plugins/screencast/screencaststream.cpp index e3c2c199ba..a1dc71b2ed 100644 --- a/src/plugins/screencast/screencaststream.cpp +++ b/src/plugins/screencast/screencaststream.cpp @@ -633,6 +633,7 @@ void ScreenCastStream::recordCursor() // in pipewire terms, corrupted means "do not look at the frame contents" and here they're empty. spa_buffer->datas[0].chunk->flags = SPA_CHUNK_FLAG_CORRUPTED; + spa_buffer->datas[0].chunk->size = 0; sendCursorData(Cursors::self()->currentCursor(), (spa_meta_cursor *)spa_buffer_find_meta_data(spa_buffer, SPA_META_Cursor, sizeof(spa_meta_cursor)));