matroskamux: Write interlaced flag if the input video content is interlaced

Unfortunately Matroska has no way to specify TFF and friends...
This commit is contained in:
Sebastian Dröge 2010-05-01 14:12:28 +02:00
parent c1d24699f5
commit db6a3e55c6

View file

@ -661,6 +661,7 @@ gst_matroska_mux_video_pad_setcaps (GstPad * pad, GstCaps * caps)
const GstBuffer *codec_buf = NULL;
gint width, height, pixel_width, pixel_height;
gint fps_d, fps_n;
gboolean interlaced = FALSE;
mux = GST_MATROSKA_MUX (GST_PAD_PARENT (pad));
@ -677,6 +678,10 @@ gst_matroska_mux_video_pad_setcaps (GstPad * pad, GstCaps * caps)
mimetype = gst_structure_get_name (structure);
if (gst_structure_get_boolean (structure, "interlaced", &interlaced)
&& interlaced)
context->flags |= GST_MATROSKA_VIDEOTRACK_INTERLACED;
if (!strcmp (mimetype, "video/x-theora")) {
/* we'll extract the details later from the theora identification header */
goto skip_details;