From 1ab68188326685ab4e427e7a6eab0694e0b0b60a Mon Sep 17 00:00:00 2001 From: Mark Sargent <99003+sarge@users.noreply.github.com> Date: Thu, 6 Jul 2023 09:18:41 +1200 Subject: [PATCH 1/7] fix: hls, set the DEFAULT explicitly to NO. Supports native HLS players. (#1170) It appears that not all Apple implementations follow the HLS guidelines. While the DEFAULT=NO for an audio track should be optional and default to NO, in practice native HLS players Safari and iOS devices treat the missing DEFAULT as a MAYBE. Fixes #1169 --- .../output.m3u8 | 2 +- packager/app/test/testdata/avc-aac-ts/output.m3u8 | 2 +- packager/app/test/testdata/avc-ac3-ts-to-mp4/output.m3u8 | 2 +- .../app/test/testdata/avc-ac3-ts-with-encryption/output.m3u8 | 2 +- packager/app/test/testdata/avc-ac3-ts/output.m3u8 | 2 +- .../avc-ts-aac-packed-audio-with-encryption/output.m3u8 | 2 +- .../avc-ts-ac3-packed-audio-with-encryption/output.m3u8 | 2 +- packager/app/test/testdata/avc-ts-event-playlist/output.m3u8 | 2 +- .../output.m3u8 | 2 +- .../avc-ts-live-playlist-with-key-rotation/output.m3u8 | 2 +- .../avc-ts-live-playlist-with-segment-deletion/output.m3u8 | 2 +- packager/app/test/testdata/avc-ts-live-playlist/output.m3u8 | 2 +- .../testdata/avc-ts-with-encryption-and-fairplay/output.m3u8 | 2 +- packager/app/test/testdata/avc-ts-with-encryption/output.m3u8 | 2 +- packager/app/test/testdata/bandwidth-override/output.m3u8 | 2 +- .../ec3-and-hls-single-segment-mp4-encrypted/output.m3u8 | 2 +- .../app/test/testdata/ec3-packed-audio-encrypted/output.m3u8 | 2 +- .../testdata/encryption-and-ad-cues-split-content/output.m3u8 | 2 +- packager/app/test/testdata/encryption-and-ad-cues/output.m3u8 | 2 +- .../app/test/testdata/encryption-with-multi-drms/output.m3u8 | 2 +- packager/app/test/testdata/flac-with-encryption/output.m3u8 | 2 +- .../testdata/hls-audio-video-text-with-ad-cues/output.m3u8 | 4 ++-- .../hls-multi-segment-mp4-with-custom-path/output.m3u8 | 2 +- .../app/test/testdata/hls-only-dash-only-captions/output.m3u8 | 4 ++-- packager/app/test/testdata/hls-segmented-webvtt/output.m3u8 | 4 ++-- .../hls-single-segment-mp4-encrypted-and-ad-cues/output.m3u8 | 2 +- .../testdata/hls-single-segment-mp4-encrypted/output.m3u8 | 2 +- .../app/test/testdata/hls-with-bandwidth-override/output.m3u8 | 2 +- packager/app/test/testdata/live-profile-with-webm/output.m3u8 | 2 +- packager/app/test/testdata/mp4-trailing-moov/output.m3u8 | 2 +- packager/app/test/testdata/segmented-ttml-mp4/output.m3u8 | 2 +- packager/app/test/testdata/segmented-ttml-text/output.m3u8 | 2 +- packager/app/test/testdata/segmented-webvtt-mp4/output.m3u8 | 2 +- packager/app/test/testdata/segmented-webvtt-text/output.m3u8 | 2 +- .../segmented-webvtt-with-language-override/output.m3u8 | 2 +- .../app/test/testdata/single-file-webvtt-text/output.m3u8 | 2 +- .../test/testdata/vtt-text-to-mp4-with-ad-cues/output.m3u8 | 4 ++-- packager/hls/base/master_playlist.cc | 2 ++ 38 files changed, 43 insertions(+), 41 deletions(-) diff --git a/packager/app/test/testdata/audio-video-with-language-override-with-subtag/output.m3u8 b/packager/app/test/testdata/audio-video-with-language-override-with-subtag/output.m3u8 index 4019bde7a0..693caf2960 100644 --- a/packager/app/test/testdata/audio-video-with-language-override-with-subtag/output.m3u8 +++ b/packager/app/test/testdata/audio-video-with-language-override-with-subtag/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",LANGUAGE="pt-BR",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",LANGUAGE="pt-BR",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1106817,AVERAGE-BANDWIDTH=1004632,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/avc-aac-ts/output.m3u8 b/packager/app/test/testdata/avc-aac-ts/output.m3u8 index 9345f1c4c1..b827ca1dc8 100644 --- a/packager/app/test/testdata/avc-aac-ts/output.m3u8 +++ b/packager/app/test/testdata/avc-aac-ts/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1217520,AVERAGE-BANDWIDTH=1117320,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/avc-ac3-ts-to-mp4/output.m3u8 b/packager/app/test/testdata/avc-ac3-ts-to-mp4/output.m3u8 index 5d0edce3c9..cef562803f 100644 --- a/packager/app/test/testdata/avc-ac3-ts-to-mp4/output.m3u8 +++ b/packager/app/test/testdata/avc-ac3-ts-to-mp4/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1168321,AVERAGE-BANDWIDTH=1074156,CODECS="avc1.64001e,ac-3",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-ac3-video.m3u8 diff --git a/packager/app/test/testdata/avc-ac3-ts-with-encryption/output.m3u8 b/packager/app/test/testdata/avc-ac3-ts-with-encryption/output.m3u8 index 4ef87deb79..61e8f12578 100644 --- a/packager/app/test/testdata/avc-ac3-ts-with-encryption/output.m3u8 +++ b/packager/app/test/testdata/avc-ac3-ts-with-encryption/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1242863,AVERAGE-BANDWIDTH=1148679,CODECS="avc1.64001e,ac-3",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-ac3-video.m3u8 diff --git a/packager/app/test/testdata/avc-ac3-ts/output.m3u8 b/packager/app/test/testdata/avc-ac3-ts/output.m3u8 index 4ef87deb79..61e8f12578 100644 --- a/packager/app/test/testdata/avc-ac3-ts/output.m3u8 +++ b/packager/app/test/testdata/avc-ac3-ts/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1242863,AVERAGE-BANDWIDTH=1148679,CODECS="avc1.64001e,ac-3",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-ac3-video.m3u8 diff --git a/packager/app/test/testdata/avc-ts-aac-packed-audio-with-encryption/output.m3u8 b/packager/app/test/testdata/avc-ts-aac-packed-audio-with-encryption/output.m3u8 index 484c3b0d79..85bf835f17 100644 --- a/packager/app/test/testdata/avc-ts-aac-packed-audio-with-encryption/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-aac-packed-audio-with-encryption/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1154999,AVERAGE-BANDWIDTH=1054750,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/avc-ts-ac3-packed-audio-with-encryption/output.m3u8 b/packager/app/test/testdata/avc-ts-ac3-packed-audio-with-encryption/output.m3u8 index 0f3a8f7bbb..e228cf672e 100644 --- a/packager/app/test/testdata/avc-ts-ac3-packed-audio-with-encryption/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-ac3-packed-audio-with-encryption/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ac3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1216578,AVERAGE-BANDWIDTH=1122532,CODECS="avc1.64001e,ac-3",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-ac3-video.m3u8 diff --git a/packager/app/test/testdata/avc-ts-event-playlist/output.m3u8 b/packager/app/test/testdata/avc-ts-event-playlist/output.m3u8 index 9345f1c4c1..b827ca1dc8 100644 --- a/packager/app/test/testdata/avc-ts-event-playlist/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-event-playlist/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1217520,AVERAGE-BANDWIDTH=1117320,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/output.m3u8 b/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/output.m3u8 index e5678b089f..ce41556e99 100644 --- a/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=133919,AVERAGE-BANDWIDTH=126463,CODECS="mp4a.40.2",AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-audio.m3u8 diff --git a/packager/app/test/testdata/avc-ts-live-playlist-with-key-rotation/output.m3u8 b/packager/app/test/testdata/avc-ts-live-playlist-with-key-rotation/output.m3u8 index 9345f1c4c1..b827ca1dc8 100644 --- a/packager/app/test/testdata/avc-ts-live-playlist-with-key-rotation/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-live-playlist-with-key-rotation/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1217520,AVERAGE-BANDWIDTH=1117320,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/avc-ts-live-playlist-with-segment-deletion/output.m3u8 b/packager/app/test/testdata/avc-ts-live-playlist-with-segment-deletion/output.m3u8 index 6761ed1464..93e42b39e5 100644 --- a/packager/app/test/testdata/avc-ts-live-playlist-with-segment-deletion/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-live-playlist-with-segment-deletion/output.m3u8 @@ -1,4 +1,4 @@ #EXTM3U ## Generated with https://github.com/shaka-project/shaka-packager version -- -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" diff --git a/packager/app/test/testdata/avc-ts-live-playlist/output.m3u8 b/packager/app/test/testdata/avc-ts-live-playlist/output.m3u8 index 9345f1c4c1..b827ca1dc8 100644 --- a/packager/app/test/testdata/avc-ts-live-playlist/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-live-playlist/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1217520,AVERAGE-BANDWIDTH=1117320,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/avc-ts-with-encryption-and-fairplay/output.m3u8 b/packager/app/test/testdata/avc-ts-with-encryption-and-fairplay/output.m3u8 index 9345f1c4c1..b827ca1dc8 100644 --- a/packager/app/test/testdata/avc-ts-with-encryption-and-fairplay/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-with-encryption-and-fairplay/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1217520,AVERAGE-BANDWIDTH=1117320,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/avc-ts-with-encryption/output.m3u8 b/packager/app/test/testdata/avc-ts-with-encryption/output.m3u8 index 9345f1c4c1..b827ca1dc8 100644 --- a/packager/app/test/testdata/avc-ts-with-encryption/output.m3u8 +++ b/packager/app/test/testdata/avc-ts-with-encryption/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1217520,AVERAGE-BANDWIDTH=1117320,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/bandwidth-override/output.m3u8 b/packager/app/test/testdata/bandwidth-override/output.m3u8 index 077ed885ed..da47b929d6 100644 --- a/packager/app/test/testdata/bandwidth-override/output.m3u8 +++ b/packager/app/test/testdata/bandwidth-override/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=55555,AVERAGE-BANDWIDTH=1004632,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/ec3-and-hls-single-segment-mp4-encrypted/output.m3u8 b/packager/app/test/testdata/ec3-and-hls-single-segment-mp4-encrypted/output.m3u8 index 568dae01b1..7ec849768f 100644 --- a/packager/app/test/testdata/ec3-and-hls-single-segment-mp4-encrypted/output.m3u8 +++ b/packager/app/test/testdata/ec3-and-hls-single-segment-mp4-encrypted/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ec3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ec3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1174214,AVERAGE-BANDWIDTH=1061802,CODECS="avc1.64001e,ec-3",RESOLUTION=640x360,FRAME-RATE=9.990,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-ec3-video.m3u8 diff --git a/packager/app/test/testdata/ec3-packed-audio-encrypted/output.m3u8 b/packager/app/test/testdata/ec3-packed-audio-encrypted/output.m3u8 index 130c27c23e..d8374b9970 100644 --- a/packager/app/test/testdata/ec3-packed-audio-encrypted/output.m3u8 +++ b/packager/app/test/testdata/ec3-packed-audio-encrypted/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ec3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-ec3-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1216655,AVERAGE-BANDWIDTH=1104925,CODECS="avc1.64001e,ec-3",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-ec3-video.m3u8 diff --git a/packager/app/test/testdata/encryption-and-ad-cues-split-content/output.m3u8 b/packager/app/test/testdata/encryption-and-ad-cues-split-content/output.m3u8 index fd021d6aae..b5bb5fd155 100644 --- a/packager/app/test/testdata/encryption-and-ad-cues-split-content/output.m3u8 +++ b/packager/app/test/testdata/encryption-and-ad-cues-split-content/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1111200,AVERAGE-BANDWIDTH=1009412,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/encryption-and-ad-cues/output.m3u8 b/packager/app/test/testdata/encryption-and-ad-cues/output.m3u8 index fd021d6aae..b5bb5fd155 100644 --- a/packager/app/test/testdata/encryption-and-ad-cues/output.m3u8 +++ b/packager/app/test/testdata/encryption-and-ad-cues/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1111200,AVERAGE-BANDWIDTH=1009412,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/encryption-with-multi-drms/output.m3u8 b/packager/app/test/testdata/encryption-with-multi-drms/output.m3u8 index e453da6f3a..dd67ca69a5 100644 --- a/packager/app/test/testdata/encryption-with-multi-drms/output.m3u8 +++ b/packager/app/test/testdata/encryption-with-multi-drms/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1111406,AVERAGE-BANDWIDTH=1009412,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE stream_1.m3u8 diff --git a/packager/app/test/testdata/flac-with-encryption/output.m3u8 b/packager/app/test/testdata/flac-with-encryption/output.m3u8 index 0d8dd55cc1..927d4267a6 100644 --- a/packager/app/test/testdata/flac-with-encryption/output.m3u8 +++ b/packager/app/test/testdata/flac-with-encryption/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=672924,AVERAGE-BANDWIDTH=631380,CODECS="flac",AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE stream_0.m3u8 diff --git a/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/output.m3u8 b/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/output.m3u8 index c39e94749a..4611d7198d 100644 --- a/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/output.m3u8 +++ b/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/output.m3u8 @@ -3,9 +3,9 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="bear-english-text.m3u8",GROUP-ID="default-text-group",NAME="stream_2",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="bear-english-text.m3u8",GROUP-ID="default-text-group",NAME="stream_2",DEFAULT=NO,AUTOSELECT=YES #EXT-X-STREAM-INF:BANDWIDTH=1108115,AVERAGE-BANDWIDTH=1006069,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",SUBTITLES="default-text-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/output.m3u8 b/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/output.m3u8 index 74abafa996..ddb25cc7c9 100644 --- a/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/output.m3u8 +++ b/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="audio/audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="audio/audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1108115,AVERAGE-BANDWIDTH=1006069,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE video/video.m3u8 diff --git a/packager/app/test/testdata/hls-only-dash-only-captions/output.m3u8 b/packager/app/test/testdata/hls-only-dash-only-captions/output.m3u8 index de0f8c364b..ecc7771c68 100644 --- a/packager/app/test/testdata/hls-only-dash-only-captions/output.m3u8 +++ b/packager/app/test/testdata/hls-only-dash-only-captions/output.m3u8 @@ -3,9 +3,9 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_3.m3u8",GROUP-ID="default-text-group",NAME="stream_3",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_3.m3u8",GROUP-ID="default-text-group",NAME="stream_3",DEFAULT=NO,AUTOSELECT=YES #EXT-X-STREAM-INF:BANDWIDTH=1108115,AVERAGE-BANDWIDTH=1006069,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",SUBTITLES="default-text-group",CLOSED-CAPTIONS=NONE stream_1.m3u8 diff --git a/packager/app/test/testdata/hls-segmented-webvtt/output.m3u8 b/packager/app/test/testdata/hls-segmented-webvtt/output.m3u8 index 2b17374e40..3997a6e7c9 100644 --- a/packager/app/test/testdata/hls-segmented-webvtt/output.m3u8 +++ b/packager/app/test/testdata/hls-segmented-webvtt/output.m3u8 @@ -3,9 +3,9 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_2.m3u8",GROUP-ID="default-text-group",NAME="stream_2",AUTOSELECT=YES,CHARACTERISTICS="public.accessibility.transcribes-spoken-dialog,private.accessibility.widevine-special" +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_2.m3u8",GROUP-ID="default-text-group",NAME="stream_2",DEFAULT=NO,AUTOSELECT=YES,CHARACTERISTICS="public.accessibility.transcribes-spoken-dialog,private.accessibility.widevine-special" #EXT-X-STREAM-INF:BANDWIDTH=1217518,AVERAGE-BANDWIDTH=1117319,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",SUBTITLES="default-text-group",CLOSED-CAPTIONS=NONE stream_1.m3u8 diff --git a/packager/app/test/testdata/hls-single-segment-mp4-encrypted-and-ad-cues/output.m3u8 b/packager/app/test/testdata/hls-single-segment-mp4-encrypted-and-ad-cues/output.m3u8 index c34929fccb..27c623b822 100644 --- a/packager/app/test/testdata/hls-single-segment-mp4-encrypted-and-ad-cues/output.m3u8 +++ b/packager/app/test/testdata/hls-single-segment-mp4-encrypted-and-ad-cues/output.m3u8 @@ -1,7 +1,7 @@ #EXTM3U ## Generated with https://github.com/shaka-project/shaka-packager version -- -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1111200,AVERAGE-BANDWIDTH=1009412,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,AUDIO="default-audio-group" bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/hls-single-segment-mp4-encrypted/output.m3u8 b/packager/app/test/testdata/hls-single-segment-mp4-encrypted/output.m3u8 index bc4f0bdb3b..2f7d4ad0ad 100644 --- a/packager/app/test/testdata/hls-single-segment-mp4-encrypted/output.m3u8 +++ b/packager/app/test/testdata/hls-single-segment-mp4-encrypted/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1111406,AVERAGE-BANDWIDTH=1009412,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/app/test/testdata/hls-with-bandwidth-override/output.m3u8 b/packager/app/test/testdata/hls-with-bandwidth-override/output.m3u8 index 5cd3530db0..f701f1a92c 100644 --- a/packager/app/test/testdata/hls-with-bandwidth-override/output.m3u8 +++ b/packager/app/test/testdata/hls-with-bandwidth-override/output.m3u8 @@ -1,7 +1,7 @@ #EXTM3U ## Generated with https://github.com/shaka-project/shaka-packager version -- -#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=55555,AVERAGE-BANDWIDTH=983986,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,AUDIO="default-audio-group" stream_1.m3u8 diff --git a/packager/app/test/testdata/live-profile-with-webm/output.m3u8 b/packager/app/test/testdata/live-profile-with-webm/output.m3u8 index 7f855c39d6..57ad801cfc 100644 --- a/packager/app/test/testdata/live-profile-with-webm/output.m3u8 +++ b/packager/app/test/testdata/live-profile-with-webm/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=556353,AVERAGE-BANDWIDTH=412719,CODECS="vp08.00.10.08.01.02.02.02.00,vorbis",RESOLUTION=640x360,FRAME-RATE=30.303,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE stream_1.m3u8 diff --git a/packager/app/test/testdata/mp4-trailing-moov/output.m3u8 b/packager/app/test/testdata/mp4-trailing-moov/output.m3u8 index 2712e9c7e7..b6704051e0 100644 --- a/packager/app/test/testdata/mp4-trailing-moov/output.m3u8 +++ b/packager/app/test/testdata/mp4-trailing-moov/output.m3u8 @@ -3,7 +3,7 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="stream_0.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" #EXT-X-STREAM-INF:BANDWIDTH=1106817,AVERAGE-BANDWIDTH=1004632,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",CLOSED-CAPTIONS=NONE stream_1.m3u8 diff --git a/packager/app/test/testdata/segmented-ttml-mp4/output.m3u8 b/packager/app/test/testdata/segmented-ttml-mp4/output.m3u8 index ecf7a821e3..43ca58ff4c 100644 --- a/packager/app/test/testdata/segmented-ttml-mp4/output.m3u8 +++ b/packager/app/test/testdata/segmented-ttml-mp4/output.m3u8 @@ -3,4 +3,4 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES diff --git a/packager/app/test/testdata/segmented-ttml-text/output.m3u8 b/packager/app/test/testdata/segmented-ttml-text/output.m3u8 index ecf7a821e3..43ca58ff4c 100644 --- a/packager/app/test/testdata/segmented-ttml-text/output.m3u8 +++ b/packager/app/test/testdata/segmented-ttml-text/output.m3u8 @@ -3,4 +3,4 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES diff --git a/packager/app/test/testdata/segmented-webvtt-mp4/output.m3u8 b/packager/app/test/testdata/segmented-webvtt-mp4/output.m3u8 index ecf7a821e3..43ca58ff4c 100644 --- a/packager/app/test/testdata/segmented-webvtt-mp4/output.m3u8 +++ b/packager/app/test/testdata/segmented-webvtt-mp4/output.m3u8 @@ -3,4 +3,4 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES diff --git a/packager/app/test/testdata/segmented-webvtt-text/output.m3u8 b/packager/app/test/testdata/segmented-webvtt-text/output.m3u8 index ecf7a821e3..43ca58ff4c 100644 --- a/packager/app/test/testdata/segmented-webvtt-text/output.m3u8 +++ b/packager/app/test/testdata/segmented-webvtt-text/output.m3u8 @@ -3,4 +3,4 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES diff --git a/packager/app/test/testdata/segmented-webvtt-with-language-override/output.m3u8 b/packager/app/test/testdata/segmented-webvtt-with-language-override/output.m3u8 index 1566d6c65b..4c16b8cfa6 100644 --- a/packager/app/test/testdata/segmented-webvtt-with-language-override/output.m3u8 +++ b/packager/app/test/testdata/segmented-webvtt-with-language-override/output.m3u8 @@ -3,4 +3,4 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_1.m3u8",GROUP-ID="default-text-group",LANGUAGE="pt",NAME="stream_1",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_1.m3u8",GROUP-ID="default-text-group",LANGUAGE="pt",NAME="stream_1",DEFAULT=NO,AUTOSELECT=YES diff --git a/packager/app/test/testdata/single-file-webvtt-text/output.m3u8 b/packager/app/test/testdata/single-file-webvtt-text/output.m3u8 index ecf7a821e3..43ca58ff4c 100644 --- a/packager/app/test/testdata/single-file-webvtt-text/output.m3u8 +++ b/packager/app/test/testdata/single-file-webvtt-text/output.m3u8 @@ -3,4 +3,4 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="stream_0.m3u8",GROUP-ID="default-text-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES diff --git a/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.m3u8 b/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.m3u8 index c39e94749a..4611d7198d 100644 --- a/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.m3u8 +++ b/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.m3u8 @@ -3,9 +3,9 @@ #EXT-X-INDEPENDENT-SEGMENTS -#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",AUTOSELECT=YES,CHANNELS="2" +#EXT-X-MEDIA:TYPE=AUDIO,URI="bear-640x360-audio.m3u8",GROUP-ID="default-audio-group",NAME="stream_0",DEFAULT=NO,AUTOSELECT=YES,CHANNELS="2" -#EXT-X-MEDIA:TYPE=SUBTITLES,URI="bear-english-text.m3u8",GROUP-ID="default-text-group",NAME="stream_2",AUTOSELECT=YES +#EXT-X-MEDIA:TYPE=SUBTITLES,URI="bear-english-text.m3u8",GROUP-ID="default-text-group",NAME="stream_2",DEFAULT=NO,AUTOSELECT=YES #EXT-X-STREAM-INF:BANDWIDTH=1108115,AVERAGE-BANDWIDTH=1006069,CODECS="avc1.64001e,mp4a.40.2",RESOLUTION=640x360,FRAME-RATE=29.970,AUDIO="default-audio-group",SUBTITLES="default-text-group",CLOSED-CAPTIONS=NONE bear-640x360-video.m3u8 diff --git a/packager/hls/base/master_playlist.cc b/packager/hls/base/master_playlist.cc index c62f24f2d0..8928802781 100644 --- a/packager/hls/base/master_playlist.cc +++ b/packager/hls/base/master_playlist.cc @@ -312,6 +312,8 @@ void BuildMediaTag(const MediaPlaylist& playlist, if (is_default) { tag.AddString("DEFAULT", "YES"); + } else { + tag.AddString("DEFAULT", "NO"); } if (is_autoselect) { From 494769ca864e04d582f707934a6573cad78d2e8c Mon Sep 17 00:00:00 2001 From: Marcus Spangenberg Date: Wed, 5 Jul 2023 23:28:57 +0200 Subject: [PATCH 2/7] fix: TTML generator timestamp millisecond formatting (#1179) Fix bug where milliseconds were formatted with two digits instead of three, resulting in incorrect timestamps in TTML cues. Fixes #1180 --- AUTHORS | 1 + CONTRIBUTORS | 1 + packager/media/formats/ttml/ttml_generator.cc | 2 +- .../formats/ttml/ttml_generator_unittest.cc | 69 ++++++++++++------- 4 files changed, 48 insertions(+), 25 deletions(-) diff --git a/AUTHORS b/AUTHORS index 6cf584a1f2..dca683bf50 100644 --- a/AUTHORS +++ b/AUTHORS @@ -22,6 +22,7 @@ Chun-da Chen Daniel CantarĂ­n Dolby Laboratories <*@dolby.com> Evgeny Zajcev +Eyevinn Technology AB <*@eyevinn.se> Google Inc. <*@google.com> Ivi.ru LLC <*@ivi.ru> Leandro Moreira diff --git a/CONTRIBUTORS b/CONTRIBUTORS index b11338f611..108ed4d850 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -39,6 +39,7 @@ Joey Parrish Kongqun Yang Leandro Moreira Leo Law +Marcus Spangenberg Ole Andre Birkedal Piotr Srebrny Qingquan Wang diff --git a/packager/media/formats/ttml/ttml_generator.cc b/packager/media/formats/ttml/ttml_generator.cc index 883691f670..193810fba8 100644 --- a/packager/media/formats/ttml/ttml_generator.cc +++ b/packager/media/formats/ttml/ttml_generator.cc @@ -29,7 +29,7 @@ std::string ToTtmlTime(int64_t time, int32_t timescale) { remaining /= 60; const int hr = remaining; - return base::StringPrintf("%02d:%02d:%02d.%02d", hr, min, sec, ms); + return base::StringPrintf("%02d:%02d:%02d.%03d", hr, min, sec, ms); } std::string ToTtmlSize(const TextNumber& x, const TextNumber& y) { diff --git a/packager/media/formats/ttml/ttml_generator_unittest.cc b/packager/media/formats/ttml/ttml_generator_unittest.cc index 8ae644c8c8..8a3915e8ca 100644 --- a/packager/media/formats/ttml/ttml_generator_unittest.cc +++ b/packager/media/formats/ttml/ttml_generator_unittest.cc @@ -67,8 +67,8 @@ TEST_F(TtmlMuxerTest, WithOneSegmentAndWithOneSample) { " \n" " \n" "
\n" - "

payload

\n" + "

payload

\n" "
\n" " \n" "\n"; @@ -86,8 +86,8 @@ TEST_F(TtmlMuxerTest, MultipleFragmentsWithNewlines) { " \n" " \n" "
\n" - "

foo bar
baz

\n" + "

foo bar
baz

\n" "
\n" " \n" "\n"; @@ -109,8 +109,8 @@ TEST_F(TtmlMuxerTest, HandlesStyles) { " \n" " \n" "
\n" - "

\n" + "

\n" " foo\n" " bar\n" " baz\n" @@ -141,8 +141,8 @@ TEST_F(TtmlMuxerTest, HandlesRegions) { " \n" " \n" "

\n" - "

bar

\n" + "

bar

\n" "
\n" " \n" "\n"; @@ -169,8 +169,8 @@ TEST_F(TtmlMuxerTest, HandlesLanguage) { " \n" " \n" "
\n" - "

bar

\n" + "

bar

\n" "
\n" " \n" "\n"; @@ -192,8 +192,8 @@ TEST_F(TtmlMuxerTest, HandlesPosition) { "
\n" " \n" - "

bar

\n" + "

bar

\n" "
\n" " \n" "\n"; @@ -216,8 +216,8 @@ TEST_F(TtmlMuxerTest, HandlesOtherSettings) { " \n" " \n" "
\n" - "

bar

\n" "
\n" " \n" @@ -240,8 +240,8 @@ TEST_F(TtmlMuxerTest, HandlesCueId) { " \n" " \n" "
\n" - "

bar

\n" + "

bar

\n" "
\n" " \n" "\n"; @@ -265,8 +265,8 @@ TEST_F(TtmlMuxerTest, EscapesSpecialChars) { " \n" " \n" "
\n" - "

<tag>\"foo&bar\"

\n" "
\n" " \n" @@ -290,8 +290,8 @@ TEST_F(TtmlMuxerTest, HandlesReset) { " \n" " \n" "
\n" - "

foo

\n" + "

foo

\n" "
\n" " \n" "\n"; @@ -302,8 +302,8 @@ TEST_F(TtmlMuxerTest, HandlesReset) { " \n" " \n" "
\n" - "

bar

\n" + "

bar

\n" "
\n" " \n" "\n"; @@ -339,8 +339,8 @@ TEST_F(TtmlMuxerTest, HandlesImage) { " \n" " \n" "
\n" - "

\n" + "

\n" "

\n" " \n" "\n"; @@ -352,6 +352,27 @@ TEST_F(TtmlMuxerTest, HandlesImage) { ParseSingleCue(kExpectedOutput, properties); } +TEST_F(TtmlMuxerTest, FormatsTimeWithFixedNumberOfDigits) { + const char* kExpectedOutput = + "\n" + "\n" + " \n" + " \n" + "
\n" + "

payload

\n" + "
\n" + " \n" + "
\n"; + + TestProperties properties; + properties.body.body = "payload"; + properties.start = 0; + properties.end = 1; + ParseSingleCue(kExpectedOutput, properties); +} + } // namespace ttml } // namespace media } // namespace shaka From e407ec7beace56b4fae7e33084cc55e8f94bab8a Mon Sep 17 00:00:00 2001 From: "Dennis E. Mungai" <2356871+Brainiarc7@users.noreply.github.com> Date: Thu, 6 Jul 2023 00:31:39 +0300 Subject: [PATCH 3/7] docs: Update build_instructions.md to point to the `main` branch. (#1186) The default branch is `main`, not `master`. Indicate this on the documentation as its' not obvious. Fixes #1060 --- docs/source/build_instructions.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/build_instructions.md b/docs/source/build_instructions.md index 416c018496..69a756ba30 100644 --- a/docs/source/build_instructions.md +++ b/docs/source/build_instructions.md @@ -117,7 +117,7 @@ dependencies. ```shell gclient config https://github.com/shaka-project/shaka-packager.git --name=src --unmanaged -gclient sync +gclient sync -r main ``` To sync to a particular commit or version, add the '-r \' flag to From 998b9cf65e2aaa8982439982d44311bd16a8aa2b Mon Sep 17 00:00:00 2001 From: "Dennis E. Mungai" <2356871+Brainiarc7@users.noreply.github.com> Date: Thu, 6 Jul 2023 00:32:03 +0300 Subject: [PATCH 4/7] docs: Update AUTHORS (#1189) --- AUTHORS | 1 + 1 file changed, 1 insertion(+) diff --git a/AUTHORS b/AUTHORS index dca683bf50..dfe9a198e2 100644 --- a/AUTHORS +++ b/AUTHORS @@ -35,3 +35,4 @@ Richard Eklycke Sanil Raut Sergio Ammirata The Chromium Authors <*@chromium.org> +Dennis E. Mungai (Brainiarc7) From ef17cf81f2285cf96985fec9553920da88cfca5d Mon Sep 17 00:00:00 2001 From: "Dennis E. Mungai" <2356871+Brainiarc7@users.noreply.github.com> Date: Thu, 6 Jul 2023 00:32:24 +0300 Subject: [PATCH 5/7] docs: Update CONTRIBUTORS (#1190) --- CONTRIBUTORS | 1 + 1 file changed, 1 insertion(+) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 108ed4d850..de58caf56a 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -52,3 +52,4 @@ Thomas Inskip Tim Lansen Vincent Nguyen Weiguo Shao +Dennis E. Mungai (Brainiarc7) From d687ad1ed00da260c4f4e5169b042ef4291052a0 Mon Sep 17 00:00:00 2001 From: Caitlin O'Callaghan <38890251+CaitlinOCallaghan@users.noreply.github.com> Date: Wed, 5 Jul 2023 23:33:51 +0200 Subject: [PATCH 6/7] fix: Low Latency DASH: include the "availabilityTimeComplete=false" attribute (#1198) # Low Latency DASH - `availabilityTimeComplete=false` Low Latency DASH manifests generated by Packager were missing the attribute `availabilityTimeComplete`. As per the [DASH specs](https://dashif.org/docs/CR-Low-Latency-Live-r8.pdf): **_the AdaptationSet@availabilityTimeCompleteshould be present and be set to 'FALSE'_** ## The Issue The missing attribute caused ULL streams from Shaka Packager to no longer be compatible with DASH.js. Previous versions of DASH.js allowed users to specify ULL mode when initializing the player. However, the most recent releases of DASH.js automatically detect ULL by scanning the manifest for ULL specific attributes. Although there are many attributes only associated with ULL, [DASH.js only greps for `availabilityTimeComplete` in its detection logic](https://github.com/Dash-Industry-Forum/dash.js/blob/development/src/streaming/controllers/PlaybackController.js#L792-L805). Because of the missing attribute in Packager and the limited ULL verification criteria by DASH.js, Packager streams were not being treated as low latency streams by DASH.js. ## Testing ### Unit Testing `./mpd_unittest --gtest_filter="SegmentTemplateTest.OneSegmentLowLatency"` ` ./mpd_unittest --gtest_filter="LowLatencySegmentTest.LowLatencySegmentTemplate"` ### Manual Testing - Created a low latency stream with Shaka Packager - Observed the expected `availabilityTimeComplete=false` attribute in the generated DASH manifest. --- packager/mpd/base/representation_unittest.cc | 4 ++-- packager/mpd/base/xml/xml_node.cc | 5 +++++ packager/mpd/base/xml/xml_node_unittest.cc | 1 + 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/packager/mpd/base/representation_unittest.cc b/packager/mpd/base/representation_unittest.cc index 03f4e4db57..42a65872a6 100644 --- a/packager/mpd/base/representation_unittest.cc +++ b/packager/mpd/base/representation_unittest.cc @@ -559,8 +559,8 @@ TEST_F(SegmentTemplateTest, OneSegmentLowLatency) { " width=\"720\" height=\"480\" frameRate=\"10/5\">\n" " \n" + " availabilityTimeComplete=\"false\" initialization=\"init.mp4\" " + " media=\"$Time$.mp4\" startNumber=\"1\"/>\n" "\n"; EXPECT_THAT(representation_->GetXml(), XmlNodeEqual(kOutputTemplate)); } diff --git a/packager/mpd/base/xml/xml_node.cc b/packager/mpd/base/xml/xml_node.cc index a5630fca08..1a1ef64f94 100644 --- a/packager/mpd/base/xml/xml_node.cc +++ b/packager/mpd/base/xml/xml_node.cc @@ -483,6 +483,11 @@ bool RepresentationXmlNode::AddLiveOnlyInfo( "availabilityTimeOffset", media_info.availability_time_offset())); } + if (low_latency_dash_mode) { + RCHECK(segment_template.SetStringAttribute("availabilityTimeComplete", + "false")); + } + if (media_info.has_init_segment_url()) { RCHECK(segment_template.SetStringAttribute("initialization", media_info.init_segment_url())); diff --git a/packager/mpd/base/xml/xml_node_unittest.cc b/packager/mpd/base/xml/xml_node_unittest.cc index da0216e249..fd0efe394d 100644 --- a/packager/mpd/base/xml/xml_node_unittest.cc +++ b/packager/mpd/base/xml/xml_node_unittest.cc @@ -752,6 +752,7 @@ TEST_F(LowLatencySegmentTest, LowLatencySegmentTemplate) { XmlNodeEqual("" " " From 53d91cd0f1295a0c3456cb1a34e5235a0316c523 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Peter=20Zeb=C3=BChr?= <33069501+petzeb@users.noreply.github.com> Date: Thu, 6 Jul 2023 04:38:01 +0700 Subject: [PATCH 7/7] fix: Don't close upstream on HttpFile::Flush (#1201) Closing the upstream on flush will effectively terminate the ongoing curl connection. This means that we would need re-establish the connection in order to resume writing, this is not what we want. In the spirit of the documentation of File::Flush ```c++ /// Flush the file so that recently written data will survive an /// application crash (but not necessarily an OS crash). For /// instance, in LocalFile the data is flushed into the OS but not /// necessarily to disk. ``` We will instead wait for the curl thread to finish consuming what ever might be in the upload cache, but leave the connection open for subsequent writes. Fixes #1196 --- packager/file/http_file.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packager/file/http_file.cc b/packager/file/http_file.cc index 404ef6fb97..de6814bb97 100644 --- a/packager/file/http_file.cc +++ b/packager/file/http_file.cc @@ -243,6 +243,7 @@ int64_t HttpFile::Read(void* buffer, uint64_t length) { } int64_t HttpFile::Write(const void* buffer, uint64_t length) { + DCHECK(!upload_cache_.closed()); VLOG(2) << "Writing to " << url_ << ", length=" << length; return upload_cache_.Write(buffer, length); } @@ -253,7 +254,8 @@ int64_t HttpFile::Size() { } bool HttpFile::Flush() { - upload_cache_.Close(); + // Wait for curl to read any data we may have buffered. + upload_cache_.WaitUntilEmptyOrClosed(); return true; }