aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Almer <jamrial@gmail.com>2016-10-11 14:36:16 -0300
committerJames Almer <jamrial@gmail.com>2016-10-11 19:49:19 -0300
commit8063978bfc864e6e57621d9e103169f995e7d95b (patch)
treec99f36d790048bceee9174ad7d265720b988ac41
parent51f3278089bb5d65d4a1c47cd037d9d706a254f0 (diff)
downloadffmpeg-8063978bfc864e6e57621d9e103169f995e7d95b.tar.gz
avformat/matroskaenc: don't write a FlagInterlaced element if it would write the default value
The spec says: "Mandatory elements with a default value may be left out of the file. In the absence of a mandatory element, the element's default value is used." Reviewed-by: Hendrik Leppkes <h.leppkes@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
-rw-r--r--libavformat/matroskaenc.c2
-rw-r--r--tests/fate/matroska.mak2
2 files changed, 1 insertions, 3 deletions
diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c
index 5293a9b5e3..a48f5bb3c6 100644
--- a/libavformat/matroskaenc.c
+++ b/libavformat/matroskaenc.c
@@ -876,8 +876,6 @@ static void mkv_write_field_order(AVIOContext *pb, int mode,
{
switch (field_order) {
case AV_FIELD_UNKNOWN:
- put_ebml_uint(pb, MATROSKA_ID_VIDEOFLAGINTERLACED,
- MATROSKA_VIDEO_INTERLACE_FLAG_UNDETERMINED);
break;
case AV_FIELD_PROGRESSIVE:
put_ebml_uint(pb, MATROSKA_ID_VIDEOFLAGINTERLACED,
diff --git a/tests/fate/matroska.mak b/tests/fate/matroska.mak
index 7de9a5904b..63a42523f6 100644
--- a/tests/fate/matroska.mak
+++ b/tests/fate/matroska.mak
@@ -4,6 +4,6 @@
FATE_MATROSKA-$(call DEMMUX, MATROSKA, MATROSKA) += fate-matroska-remux
fate-matroska-remux: CMD = md5 -i $(TARGET_SAMPLES)/vp9-test-vectors/vp90-2-2pass-akiyo.webm -color_trc 4 -c:v copy -fflags +bitexact -strict -2 -f matroska
fate-matroska-remux: CMP = oneline
-fate-matroska-remux: REF = d1a5fc15908ba10ca3efa282059ca79f
+fate-matroska-remux: REF = 84e950f59677e306f944fca484888c5d
FATE_SAMPLES_AVCONV += $(FATE_MATROSKA-yes)