Add AV1 to matroska plugin

https://bugzilla.gnome.org/show_bug.cgi?id=784160
This commit is contained in:
Sean DuBois 2017-12-13 09:22:17 +00:00 committed by Edward Hervey
parent 3464aac3c9
commit de8f080a5c
4 changed files with 9 additions and 2 deletions

View file

@ -3812,7 +3812,8 @@ gst_matroska_demux_parse_blockgroup_or_simpleblock (GstMatroskaDemux * demux,
delta_unit = TRUE;
invisible_frame = ((flags & 0x08)) &&
(!strcmp (stream->codec_id, GST_MATROSKA_CODEC_ID_VIDEO_VP8) ||
!strcmp (stream->codec_id, GST_MATROSKA_CODEC_ID_VIDEO_VP9));
!strcmp (stream->codec_id, GST_MATROSKA_CODEC_ID_VIDEO_VP9) ||
!strcmp (stream->codec_id, GST_MATROSKA_CODEC_ID_VIDEO_AV1));
}
/* If we're doing a keyframe-only trickmode, only push keyframes on video
@ -5609,6 +5610,9 @@ gst_matroska_demux_video_caps (GstMatroskaTrackVideoContext *
} else if (!strcmp (codec_id, GST_MATROSKA_CODEC_ID_VIDEO_VP9)) {
caps = gst_caps_new_empty_simple ("video/x-vp9");
*codec_name = g_strdup_printf ("On2 VP9");
} else if (!strcmp (codec_id, GST_MATROSKA_CODEC_ID_VIDEO_AV1)) {
caps = gst_caps_new_empty_simple ("video/x-av1");
*codec_name = g_strdup_printf ("AOM AV1");
} else if (!strcmp (codec_id, GST_MATROSKA_CODEC_ID_VIDEO_PRORES)) {
guint32 fourcc;
const gchar *variant, *variant_descr = "";

View file

@ -358,6 +358,7 @@
#define GST_MATROSKA_CODEC_ID_VIDEO_DIRAC "V_DIRAC"
#define GST_MATROSKA_CODEC_ID_VIDEO_VP8 "V_VP8"
#define GST_MATROSKA_CODEC_ID_VIDEO_VP9 "V_VP9"
#define GST_MATROSKA_CODEC_ID_VIDEO_AV1 "V_AV1"
#define GST_MATROSKA_CODEC_ID_VIDEO_MPEGH_HEVC "V_MPEGH/ISO/HEVC"
#define GST_MATROSKA_CODEC_ID_VIDEO_PRORES "V_PRORES"

View file

@ -1210,6 +1210,8 @@ skip_details:
gst_matroska_mux_set_codec_id (context, GST_MATROSKA_CODEC_ID_VIDEO_VP8);
} else if (!strcmp (mimetype, "video/x-vp9")) {
gst_matroska_mux_set_codec_id (context, GST_MATROSKA_CODEC_ID_VIDEO_VP9);
} else if (!strcmp (mimetype, "video/x-av1")) {
gst_matroska_mux_set_codec_id (context, GST_MATROSKA_CODEC_ID_VIDEO_AV1);
} else if (!strcmp (mimetype, "video/mpeg")) {
gint mpegversion;

View file

@ -66,7 +66,7 @@ static GstStaticPadTemplate webm_videosink_templ =
GST_PAD_SINK,
GST_PAD_REQUEST,
GST_STATIC_CAPS ("video/x-vp8, " COMMON_VIDEO_CAPS ";"
"video/x-vp9, " COMMON_VIDEO_CAPS)
"video/x-vp9, " COMMON_VIDEO_CAPS ";" "video/x-av1, " COMMON_VIDEO_CAPS)
);
static GstStaticPadTemplate webm_audiosink_templ =