Skip to content

Commit d1ae60a

Browse files
committed
gstplayer: don't use gst_video_info_new_from_caps
Was added in gstreamer 1.20, debian bullseye is still on 1.18.
1 parent 6027cca commit d1ae60a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/plugins/gstplayer.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
#include "plugins/gstplayer.h"
2727
#include "texture_registry.h"
2828
#include "util/logging.h"
29+
#include "util/macros.h"
2930

3031
#include "config.h"
3132

@@ -811,8 +812,10 @@ UNUSED static GstPadProbeReturn on_video_sink_event(GstPad *pad, GstPadProbeInfo
811812
return GST_PAD_PROBE_OK;
812813
}
813814

814-
GstVideoInfo *videoinfo = gst_video_info_new_from_caps(caps);
815-
if (!videoinfo) {
815+
GstVideoInfo *videoinfo = gst_video_info_new();
816+
ASSUME(videoinfo != NULL);
817+
818+
if (!gst_video_info_from_caps(videoinfo, caps)) {
816819
LOG_ERROR("Could not determine video properties of caps event.\n");
817820
return GST_PAD_PROBE_OK;
818821
}

0 commit comments

Comments
 (0)