diff mbox series

[FFmpeg-devel,18/19] fate/matroska: Test remuxing tracks for hearing/visually impaired

Message ID 20210217101356.1723370-18-andreas.rheinhardt@gmail.com
State Superseded
Headers show
Series [FFmpeg-devel,01/19] fate/matroska: Add test for mastering display metadata | expand

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished
andriy/PPC64_make success Make finished
andriy/PPC64_make_fate warning Make fate failed

Commit Message

Andreas Rheinhardt Feb. 17, 2021, 10:13 a.m. UTC
The tests also test the other dispositions: commentary, descriptions
as well as dub and original language. Furthermore they test e.g. muxing
alac in Matroska.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
 tests/fate/matroska.mak              |  23 +++++
 tests/ref/fate/matroska-mpegts-remux |  52 +++++++++++
 tests/ref/fate/matroska-wtv-remux    | 134 +++++++++++++++++++++++++++
 3 files changed, 209 insertions(+)
 create mode 100644 tests/ref/fate/matroska-mpegts-remux
 create mode 100644 tests/ref/fate/matroska-wtv-remux
diff mbox series

Patch

diff --git a/tests/fate/matroska.mak b/tests/fate/matroska.mak
index 4c10fe663f..b907da40f3 100644
--- a/tests/fate/matroska.mak
+++ b/tests/fate/matroska.mak
@@ -100,6 +100,29 @@  FATE_MATROSKA_FFMPEG_FFPROBE-$(call ALLYES, FILE_PROTOCOL MATROSKA_DEMUXER \
                                += fate-matroska-vp8-alpha-remux
 fate-matroska-vp8-alpha-remux: CMD = transcode matroska $(TARGET_SAMPLES)/vp8_alpha/vp8_video_with_alpha.webm matroska "-c copy -disposition +hearing_impaired -cluster_size_limit 100000" "-c copy -t 0.2" "" "-show_entries stream_disposition:stream_side_data_list"
 
+# The second input audio track is for the hearing impaired. It is muxed twice,
+# once using streamcopy and once encoded with alac to test that dispositions
+# are preserved during encoding; the streamcopied track is also marked as
+# commentary. The other audio stream is also muxed twice, once streamcopied,
+# once as pcm_s24be; one of them is marked as dub and one as original language.
+# The subtitle stream is furthermore marked as containing descriptions.
+FATE_MATROSKA_FFMPEG_FFPROBE-$(call ALLYES, FILE_PROTOCOL WTV_DEMUXER       \
+                                            MPEGAUDIO_PARSER DVBSUB_PARSER  \
+                                            MP2_DECODER ARESAMPLE_FILTER    \
+                                            ALAC_ENCODER PCM_S24BE_ENCODER  \
+                                            MATROSKA_MUXER MATROSKA_DEMUXER \
+                                            FRAMECRC_MUXER PIPE_PROTOCOL)   \
+                               += fate-matroska-wtv-remux
+fate-matroska-wtv-remux: CMD = transcode wtv $(TARGET_SAMPLES)/wtv/law-and-order-partial.wtv matroska "-map 0 -vn -map 0:a:1 -c:s copy -disposition:s +descriptions -c:a:0 copy -disposition:a:0 +original -c:a:1 copy -disposition:a:1 +comment -c:a:2 alac -map 0:a:0 -filter:a:3 aresample -c:a:3 pcm_s24be -disposition:a:3 +dub" "-map 0 -c copy -t 0.2" "" "-show_entries stream_disposition:stream=index,codec_name"
+
+# The audio stream to be remuxed here has AV_DISPOSITION_VISUAL_IMPAIRED.
+FATE_MATROSKA_FFMPEG_FFPROBE-$(call ALLYES, FILE_PROTOCOL MPEGTS_DEMUXER    \
+                                            AC3_DECODER MATROSKA_MUXER      \
+                                            MATROSKA_DEMUXER FRAMECRC_MUXER \
+                                            PIPE_PROTOCOL)                  \
+                               += fate-matroska-mpegts-remux
+fate-matroska-mpegts-remux: CMD = transcode mpegts $(TARGET_SAMPLES)/mpegts/pmtchange.ts matroska "-map 0:2 -map 0:2 -c copy -disposition:a:1 -visual_impaired+hearing_impaired" "-map 0 -c copy" "" "-show_entries stream_disposition:stream=index"
+
 FATE_MATROSKA_FFPROBE-$(call ALLYES, MATROSKA_DEMUXER) += fate-matroska-spherical-mono
 fate-matroska-spherical-mono: CMD = run ffprobe$(PROGSSUF)$(EXESUF) -show_entries stream_side_data_list -select_streams v -v 0 $(TARGET_SAMPLES)/mkv/spherical.mkv
 
diff --git a/tests/ref/fate/matroska-mpegts-remux b/tests/ref/fate/matroska-mpegts-remux
new file mode 100644
index 0000000000..3c0b41cca9
--- /dev/null
+++ b/tests/ref/fate/matroska-mpegts-remux
@@ -0,0 +1,52 @@ 
+4e6253c1f5f96ff64ae855dea426547d *tests/data/fate/matroska-mpegts-remux.matroska
+6509 tests/data/fate/matroska-mpegts-remux.matroska
+#tb 0: 1/1000
+#media_type 0: audio
+#codec_id 0: ac3
+#sample_rate 0: 48000
+#channel_layout 0: 3
+#channel_layout_name 0: stereo
+#tb 1: 1/1000
+#media_type 1: audio
+#codec_id 1: ac3
+#sample_rate 1: 48000
+#channel_layout 1: 3
+#channel_layout_name 1: stereo
+0,          0,          0,       32,      768, 0xa63778d4
+1,          0,          0,       32,      768, 0xa63778d4
+0,         32,         32,       32,      768, 0x7d577f3f
+1,         32,         32,       32,      768, 0x7d577f3f
+0,         64,         64,       32,      768, 0xd86b7c8f
+1,         64,         64,       32,      768, 0xd86b7c8f
+0,         96,         96,       32,      626, 0x09f4382f
+1,         96,         96,       32,      626, 0x09f4382f
+[STREAM]
+index=0
+DISPOSITION:default=1
+DISPOSITION:dub=0
+DISPOSITION:original=0
+DISPOSITION:comment=0
+DISPOSITION:lyrics=0
+DISPOSITION:karaoke=0
+DISPOSITION:forced=0
+DISPOSITION:hearing_impaired=0
+DISPOSITION:visual_impaired=1
+DISPOSITION:clean_effects=0
+DISPOSITION:attached_pic=0
+DISPOSITION:timed_thumbnails=0
+[/STREAM]
+[STREAM]
+index=1
+DISPOSITION:default=0
+DISPOSITION:dub=0
+DISPOSITION:original=0
+DISPOSITION:comment=0
+DISPOSITION:lyrics=0
+DISPOSITION:karaoke=0
+DISPOSITION:forced=0
+DISPOSITION:hearing_impaired=1
+DISPOSITION:visual_impaired=0
+DISPOSITION:clean_effects=0
+DISPOSITION:attached_pic=0
+DISPOSITION:timed_thumbnails=0
+[/STREAM]
diff --git a/tests/ref/fate/matroska-wtv-remux b/tests/ref/fate/matroska-wtv-remux
new file mode 100644
index 0000000000..6978ad50c6
--- /dev/null
+++ b/tests/ref/fate/matroska-wtv-remux
@@ -0,0 +1,134 @@ 
+1206b022950477c92c2313a1fa11143b *tests/data/fate/matroska-wtv-remux.matroska
+752499 tests/data/fate/matroska-wtv-remux.matroska
+#extradata 0:        5, 0x001c0014
+#extradata 1:       22, 0x12dc010c
+#extradata 2:       22, 0x12dc010c
+#extradata 3:       36, 0x435d0438
+#tb 0: 1/1000
+#media_type 0: subtitle
+#codec_id 0: dvb_subtitle
+#tb 1: 1/1000
+#media_type 1: audio
+#codec_id 1: mp2
+#sample_rate 1: 48000
+#channel_layout 1: 3
+#channel_layout_name 1: stereo
+#tb 2: 1/1000
+#media_type 2: audio
+#codec_id 2: mp2
+#sample_rate 2: 48000
+#channel_layout 2: 4
+#channel_layout_name 2: mono
+#tb 3: 1/1000
+#media_type 3: audio
+#codec_id 3: alac
+#sample_rate 3: 48000
+#channel_layout 3: 4
+#channel_layout_name 3: mono
+#tb 4: 1/1000
+#media_type 4: audio
+#codec_id 4: pcm_s24be
+#sample_rate 4: 48000
+#channel_layout 4: 3
+#channel_layout_name 4: stereo
+1,          0,          0,       24,      576, 0x9b6e1638
+4,          0,          0,       24,     6912, 0x3c9d4857
+1,         24,         24,       24,      576, 0x0ca91183
+4,         24,         24,       24,     6912, 0x2c6d0715
+1,         48,         48,       24,      576, 0xec6a180f
+4,         48,         48,       24,     6912, 0x2b1df5f0
+1,         72,         72,       24,      576, 0x478a2b9b
+4,         72,         72,       24,     6912, 0x84df4f03
+1,         96,         96,       24,      576, 0x00fa15b3
+4,         96,         96,       24,     6912, 0x071d6767
+1,        120,        120,       24,      576, 0xfb551816
+4,        120,        120,       24,     6912, 0x2aeb66ea
+1,        144,        144,       24,      576, 0x422e12bd
+4,        144,        144,       24,     6912, 0xfccb037f
+2,        163,        163,       24,      192, 0xc948791d
+3,        163,        163,        0,       19, 0x09f10390
+1,        168,        168,       24,      576, 0xa7581b29
+4,        168,        168,       24,     6912, 0xa650ad97
+2,        187,        187,       24,      192, 0xc948791d
+1,        192,        192,       24,      576, 0xd4b31a74
+4,        192,        192,       24,     6912, 0x1b33cb40
+[STREAM]
+index=0
+codec_name=dvb_subtitle
+DISPOSITION:default=1
+DISPOSITION:dub=0
+DISPOSITION:original=0
+DISPOSITION:comment=0
+DISPOSITION:lyrics=0
+DISPOSITION:karaoke=0
+DISPOSITION:forced=0
+DISPOSITION:hearing_impaired=0
+DISPOSITION:visual_impaired=0
+DISPOSITION:clean_effects=0
+DISPOSITION:attached_pic=0
+DISPOSITION:timed_thumbnails=0
+[/STREAM]
+[STREAM]
+index=1
+codec_name=mp2
+DISPOSITION:default=1
+DISPOSITION:dub=0
+DISPOSITION:original=1
+DISPOSITION:comment=0
+DISPOSITION:lyrics=0
+DISPOSITION:karaoke=0
+DISPOSITION:forced=0
+DISPOSITION:hearing_impaired=0
+DISPOSITION:visual_impaired=0
+DISPOSITION:clean_effects=0
+DISPOSITION:attached_pic=0
+DISPOSITION:timed_thumbnails=0
+[/STREAM]
+[STREAM]
+index=2
+codec_name=mp2
+DISPOSITION:default=0
+DISPOSITION:dub=0
+DISPOSITION:original=0
+DISPOSITION:comment=1
+DISPOSITION:lyrics=0
+DISPOSITION:karaoke=0
+DISPOSITION:forced=0
+DISPOSITION:hearing_impaired=1
+DISPOSITION:visual_impaired=0
+DISPOSITION:clean_effects=0
+DISPOSITION:attached_pic=0
+DISPOSITION:timed_thumbnails=0
+[/STREAM]
+[STREAM]
+index=3
+codec_name=alac
+DISPOSITION:default=0
+DISPOSITION:dub=0
+DISPOSITION:original=0
+DISPOSITION:comment=0
+DISPOSITION:lyrics=0
+DISPOSITION:karaoke=0
+DISPOSITION:forced=0
+DISPOSITION:hearing_impaired=1
+DISPOSITION:visual_impaired=0
+DISPOSITION:clean_effects=0
+DISPOSITION:attached_pic=0
+DISPOSITION:timed_thumbnails=0
+[/STREAM]
+[STREAM]
+index=4
+codec_name=pcm_s24be
+DISPOSITION:default=0
+DISPOSITION:dub=1
+DISPOSITION:original=0
+DISPOSITION:comment=0
+DISPOSITION:lyrics=0
+DISPOSITION:karaoke=0
+DISPOSITION:forced=0
+DISPOSITION:hearing_impaired=0
+DISPOSITION:visual_impaired=0
+DISPOSITION:clean_effects=0
+DISPOSITION:attached_pic=0
+DISPOSITION:timed_thumbnails=0
+[/STREAM]