From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Mon, 13 Feb 2023 15:57:38 +0100 Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1pRaGy-006JZj-DF for lore@lore.pengutronix.de; Mon, 13 Feb 2023 15:57:38 +0100 Received: from localhost ([127.0.0.1] helo=metis.ext.pengutronix.de) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1pRaGn-0006h9-1O; Mon, 13 Feb 2023 15:57:29 +0100 Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pRaGk-0006gF-Tx; Mon, 13 Feb 2023 15:57:26 +0100 Received: from [2a0a:edc0:0:1101:1d::28] (helo=dude02.red.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1pRaGj-004g5x-3L; Mon, 13 Feb 2023 15:57:26 +0100 Received: from mfe by dude02.red.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1pRaGj-00H50P-HF; Mon, 13 Feb 2023 15:57:25 +0100 From: Marco Felsch To: oss-tools@pengutronix.de, graphics@pengutronix.de Date: Mon, 13 Feb 2023 15:57:22 +0100 Message-Id: <20230213145723.4065393-2-m.felsch@pengutronix.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230213145723.4065393-1-m.felsch@pengutronix.de> References: <20230213145723.4065393-1-m.felsch@pengutronix.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [OSS-Tools] [PATCH 2/3] set pipeline latency and add some max-lateness slack X-BeenThere: oss-tools@pengutronix.de X-Mailman-Version: 2.1.29 Precedence: list List-Id: Pengutronix Public Open-Source-Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "OSS-Tools" X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: oss-tools-bounces@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false From: Lucas Stach Set the pipeline latency via the processing deadline property to something that can actually be reached under real system load. Also add some more slack to the allowed buffer lateness. As the whole pipeline is running at 30fps, the default 5ms is a bit harsh and drops frames that are still fine to present. Signed-off-by: Lucas Stach --- plugin/gstplayer.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugin/gstplayer.cpp b/plugin/gstplayer.cpp index 909843b..df2c0c9 100644 --- a/plugin/gstplayer.cpp +++ b/plugin/gstplayer.cpp @@ -378,7 +378,9 @@ void QtGstPlayer::updatePipeline() GstElement *upload = gst_element_factory_make("glupload", NULL); GstElement *sink = gst_element_factory_make("qmlglsink", NULL); - g_object_set(G_OBJECT(sink), "widget", m_sink, NULL); + g_object_set(G_OBJECT(sink), "widget", m_sink, + "processing-deadline", 35 * GST_MSECOND, + "max-lateness", 15 * GST_MSECOND, NULL); gst_bin_add_many(GST_BIN(sinkBin), upload, sink, NULL); gst_element_link_many(upload, sink, NULL); -- 2.30.2