From eba540551232386b7fcf5de51a5714718e5e1939 Mon Sep 17 00:00:00 2001 From: Guillaume Desmottes Date: Wed, 24 Jul 2024 22:22:03 +0200 Subject: [PATCH] qroverlay: redraw overlay when caps changes The position needs to be updated as it depends of the video size. Part-of: --- subprojects/gst-plugins-bad/ext/qroverlay/gstbaseqroverlay.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/subprojects/gst-plugins-bad/ext/qroverlay/gstbaseqroverlay.c b/subprojects/gst-plugins-bad/ext/qroverlay/gstbaseqroverlay.c index 420d643fb7..5f112bdd56 100644 --- a/subprojects/gst-plugins-bad/ext/qroverlay/gstbaseqroverlay.c +++ b/subprojects/gst-plugins-bad/ext/qroverlay/gstbaseqroverlay.c @@ -131,6 +131,9 @@ gst_base_qr_overlay_caps_changed_cb (GstBaseQROverlay * self, GstCaps * caps, priv->valid = TRUE; else priv->valid = FALSE; + + /* needs to redraw the overlay as its position depends of the video size */ + gst_mini_object_replace (((GstMiniObject **) & priv->prev_overlay), NULL); } static GstVideoOverlayComposition *