From d266c5da25781fa6b30ec445c44e44bf3e675147 Mon Sep 17 00:00:00 2001 From: evgeny Date: Mon, 19 Oct 2026 17:43:45 +0200 Subject: [PATCH] Respect GPU pipeline capacity before submitting a new camera frame --- tools/chatgui/src/call_video_engine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/chatgui/src/call_video_engine.cpp b/tools/chatgui/src/call_video_engine.cpp index 9891e19e..e937c36f 100644 --- a/tools/chatgui/src/call_video_engine.cpp +++ b/tools/chatgui/src/call_video_engine.cpp @@ -282,7 +282,7 @@ void CallVideoEngine::transmit() { call_video_port_applied(m->id, format.generation, request, 0); } #ifdef HAVE_STREAM_CAPTURE - bool submit = state.can_encode && pts > lastPts; + bool submit = state.can_encode && pts > lastPts && encoder.pendingFrames() < 8; if (submit && (image.isNull() || nowUs() - pts > CallCameraMaxFrameAgeUs)) { DEBUG_WARN(DEBUG_CATEGORY_CALL, "video TX skips old capture age_us=%lld", (long long)(nowUs() - pts)); lastPts = pts; ++expired; continue;