diff --git a/packager/app/test/testdata/acc-he/bear-640x360-aac_he-silent_right-audio.mp4 b/packager/app/test/testdata/acc-he/bear-640x360-aac_he-silent_right-audio.mp4
index 4bfebf3a61..67829e30ff 100644
Binary files a/packager/app/test/testdata/acc-he/bear-640x360-aac_he-silent_right-audio.mp4 and b/packager/app/test/testdata/acc-he/bear-640x360-aac_he-silent_right-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video-with-accessibilities-and-roles/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video-with-accessibilities-and-roles/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/audio-video-with-accessibilities-and-roles/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video-with-accessibilities-and-roles/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video-with-codec-switching-encryption-trick-play/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video-with-codec-switching-encryption-trick-play/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/audio-video-with-codec-switching-encryption-trick-play/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video-with-codec-switching-encryption-trick-play/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video-with-codec-switching/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video-with-codec-switching/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/audio-video-with-codec-switching/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video-with-codec-switching/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video-with-codec-switching/output.mpd b/packager/app/test/testdata/audio-video-with-codec-switching/output.mpd
index 5a7630776d..2aadb124ea 100644
--- a/packager/app/test/testdata/audio-video-with-codec-switching/output.mpd
+++ b/packager/app/test/testdata/audio-video-with-codec-switching/output.mpd
@@ -15,18 +15,18 @@
-
- bear-1280x720-video.mp4
-
-
-
-
-
+
bear-640x360-video.mp4
+
+ bear-1280x720-video.mp4
+
+
+
+
diff --git a/packager/app/test/testdata/audio-video-with-language-override-with-subtag/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video-with-language-override-with-subtag/bear-640x360-audio.mp4
index 42857986c7..50899857d2 100644
Binary files a/packager/app/test/testdata/audio-video-with-language-override-with-subtag/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video-with-language-override-with-subtag/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video-with-language-override/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video-with-language-override/bear-640x360-audio.mp4
index 42857986c7..50899857d2 100644
Binary files a/packager/app/test/testdata/audio-video-with-language-override/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video-with-language-override/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video-with-trick-play/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video-with-trick-play/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/audio-video-with-trick-play/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video-with-trick-play/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video-with-two-trick-play/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video-with-two-trick-play/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/audio-video-with-two-trick-play/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video-with-two-trick-play/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/audio-video/bear-640x360-audio.mp4 b/packager/app/test/testdata/audio-video/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/audio-video/bear-640x360-audio.mp4 and b/packager/app/test/testdata/audio-video/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/bear-640x360-audio-init.mp4
index f6ff48bc01..cd5b19acde 100644
Binary files a/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/avc-ts-live-playlist-dash-dynamic-with-segment-deletion/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/bandwidth-override/bear-640x360-audio.mp4 b/packager/app/test/testdata/bandwidth-override/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/bandwidth-override/bear-640x360-audio.mp4 and b/packager/app/test/testdata/bandwidth-override/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-ad-cues-and-dash-trick-play/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-ad-cues-and-dash-trick-play/bear-640x360-audio.mp4
index 1941c3bec3..d989336d24 100644
Binary files a/packager/app/test/testdata/encryption-and-ad-cues-and-dash-trick-play/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-ad-cues-and-dash-trick-play/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio1.mp4 b/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio1.mp4
index c9ad4cd161..2b97d2fba6 100644
Binary files a/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio1.mp4 and b/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio1.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio2.mp4 b/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio2.mp4
index c9c14f2f18..0a7b85b861 100644
Binary files a/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio2.mp4 and b/packager/app/test/testdata/encryption-and-ad-cues-split-content/bear-640x360-audio2.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-ad-cues/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-ad-cues/bear-640x360-audio.mp4
index 1941c3bec3..d989336d24 100644
Binary files a/packager/app/test/testdata/encryption-and-ad-cues/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-ad-cues/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-no-clear-lead/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-no-clear-lead/bear-640x360-audio.mp4
index 9cf72047ef..91b967fb27 100644
Binary files a/packager/app/test/testdata/encryption-and-no-clear-lead/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-no-clear-lead/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-no-clear-lead/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption-and-no-clear-lead/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-and-no-clear-lead/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption-and-no-clear-lead/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-no-pssh-in-stream/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-no-pssh-in-stream/bear-640x360-audio.mp4
index 22fcb0a3ac..22d9741b3c 100644
Binary files a/packager/app/test/testdata/encryption-and-no-pssh-in-stream/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-no-pssh-in-stream/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-non-dash-if-iop/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-non-dash-if-iop/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/encryption-and-non-dash-if-iop/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-non-dash-if-iop/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-output-media-info/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-output-media-info/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/encryption-and-output-media-info/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-output-media-info/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-trick-play/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-trick-play/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/encryption-and-trick-play/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-trick-play/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-trick-play/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption-and-trick-play/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-and-trick-play/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption-and-trick-play/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/encryption-and-two-trick-plays/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-and-two-trick-plays/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/encryption-and-two-trick-plays/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-and-two-trick-plays/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cbc-1/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-cbc-1/bear-640x360-audio.mp4
index cedd5fbc52..8bac0b7402 100644
Binary files a/packager/app/test/testdata/encryption-cbc-1/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-cbc-1/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cbc-1/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption-cbc-1/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-cbc-1/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption-cbc-1/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cbcs-with-full-protection/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-cbcs-with-full-protection/bear-640x360-audio.mp4
index 05fe6fa48c..8be897b313 100644
Binary files a/packager/app/test/testdata/encryption-cbcs-with-full-protection/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-cbcs-with-full-protection/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cbcs-with-full-protection/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption-cbcs-with-full-protection/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-cbcs-with-full-protection/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption-cbcs-with-full-protection/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cbcs/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-cbcs/bear-640x360-audio.mp4
index 05fe6fa48c..8be897b313 100644
Binary files a/packager/app/test/testdata/encryption-cbcs/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-cbcs/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cbcs/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption-cbcs/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-cbcs/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption-cbcs/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cens/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-cens/bear-640x360-audio.mp4
index 5f0e489582..9cc8dba201 100644
Binary files a/packager/app/test/testdata/encryption-cens/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-cens/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-cens/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption-cens/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-cens/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption-cens/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/encryption-multi-keys-with-stream-label/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-multi-keys-with-stream-label/bear-640x360-audio.mp4
index 09c04bf62e..b18f8880d6 100644
Binary files a/packager/app/test/testdata/encryption-multi-keys-with-stream-label/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-multi-keys-with-stream-label/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-multi-keys/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-multi-keys/bear-640x360-audio.mp4
index a5e112bcc5..9a75a53c53 100644
Binary files a/packager/app/test/testdata/encryption-multi-keys/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-multi-keys/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-of-only-video-stream/bear-640x360-audio-skip_encryption.mp4 b/packager/app/test/testdata/encryption-of-only-video-stream/bear-640x360-audio-skip_encryption.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-of-only-video-stream/bear-640x360-audio-skip_encryption.mp4 and b/packager/app/test/testdata/encryption-of-only-video-stream/bear-640x360-audio-skip_encryption.mp4 differ
diff --git a/packager/app/test/testdata/encryption-using-explicit-pssh/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-using-explicit-pssh/bear-640x360-audio.mp4
index 60adc5cf99..40ad67469b 100644
Binary files a/packager/app/test/testdata/encryption-using-explicit-pssh/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-using-explicit-pssh/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-using-fixed-key/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-using-fixed-key/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/encryption-using-fixed-key/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-using-fixed-key/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption-using-fixed-key/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption-using-fixed-key/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption-using-fixed-key/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption-using-fixed-key/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/encryption-with-multi-drms/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption-with-multi-drms/bear-640x360-audio.mp4
index 68521c6fb4..d9e4d1b766 100644
Binary files a/packager/app/test/testdata/encryption-with-multi-drms/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption-with-multi-drms/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption/bear-640x360-audio.mp4 b/packager/app/test/testdata/encryption/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/encryption/bear-640x360-audio.mp4 and b/packager/app/test/testdata/encryption/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/encryption/decrypted-bear-640x360-audio-0.mp4 b/packager/app/test/testdata/encryption/decrypted-bear-640x360-audio-0.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/encryption/decrypted-bear-640x360-audio-0.mp4 and b/packager/app/test/testdata/encryption/decrypted-bear-640x360-audio-0.mp4 differ
diff --git a/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/bear-640x360-audio-init.mp4
index 1ba3d9abb9..825a8072d2 100644
Binary files a/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/hls-audio-video-text-with-ad-cues/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/audio/audio-init.mp4 b/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/audio/audio-init.mp4
index 1ba3d9abb9..825a8072d2 100644
Binary files a/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/audio/audio-init.mp4 and b/packager/app/test/testdata/hls-multi-segment-mp4-with-custom-path/audio/audio-init.mp4 differ
diff --git a/packager/app/test/testdata/hls-only-dash-only-captions/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/hls-only-dash-only-captions/bear-640x360-audio-init.mp4
index 1ba3d9abb9..825a8072d2 100644
Binary files a/packager/app/test/testdata/hls-only-dash-only-captions/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/hls-only-dash-only-captions/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/hls-only-dash-only/bear-640x360-audio.mp4 b/packager/app/test/testdata/hls-only-dash-only/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/hls-only-dash-only/bear-640x360-audio.mp4 and b/packager/app/test/testdata/hls-only-dash-only/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/hls-single-segment-mp4-encrypted/bear-640x360-audio.mp4 b/packager/app/test/testdata/hls-single-segment-mp4-encrypted/bear-640x360-audio.mp4
index b82b25f618..81afce8c79 100644
Binary files a/packager/app/test/testdata/hls-single-segment-mp4-encrypted/bear-640x360-audio.mp4 and b/packager/app/test/testdata/hls-single-segment-mp4-encrypted/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-1280x720-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-1280x720-audio-init.mp4
index bb4986496e..5b46a8a3ba 100644
Binary files a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-1280x720-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-1280x720-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-320x180-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-320x180-audio-init.mp4
index 374d5fa05d..c5319cf20f 100644
Binary files a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-320x180-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-320x180-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-640x360-audio-init.mp4
index bb4986496e..5b46a8a3ba 100644
Binary files a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/output.mpd b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/output.mpd
index 5a82778bb8..565aaabd30 100644
--- a/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/output.mpd
+++ b/packager/app/test/testdata/live-profile-and-encryption-and-mult-files/output.mpd
@@ -7,15 +7,7 @@
AAAANHBzc2gBAAAAEHfv7MCyTQKs4zweUuL7SwAAAAExMjM0NTY3ODkwMTIzNDU2AAAAAA==
-
-
-
-
-
-
-
-
-
+
@@ -23,7 +15,7 @@
-
+
@@ -31,6 +23,14 @@
+
+
+
+
+
+
+
+
@@ -39,7 +39,7 @@
-
+
@@ -49,7 +49,7 @@
-
+
diff --git a/packager/app/test/testdata/live-profile-and-encryption-and-non-dash-if-iop/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-encryption-and-non-dash-if-iop/bear-640x360-audio-init.mp4
index bb4986496e..5b46a8a3ba 100644
Binary files a/packager/app/test/testdata/live-profile-and-encryption-and-non-dash-if-iop/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-encryption-and-non-dash-if-iop/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-encryption/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-encryption/bear-640x360-audio-init.mp4
index bb4986496e..5b46a8a3ba 100644
Binary files a/packager/app/test/testdata/live-profile-and-encryption/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-encryption/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-key-rotation-and-no-pssh-in-stream/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-key-rotation-and-no-pssh-in-stream/bear-640x360-audio-init.mp4
index 06cbf09f13..2b138e6923 100644
Binary files a/packager/app/test/testdata/live-profile-and-key-rotation-and-no-pssh-in-stream/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-key-rotation-and-no-pssh-in-stream/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-key-rotation-and-non-dash-if-iop/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-key-rotation-and-non-dash-if-iop/bear-640x360-audio-init.mp4
index 06cbf09f13..2b138e6923 100644
Binary files a/packager/app/test/testdata/live-profile-and-key-rotation-and-non-dash-if-iop/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-key-rotation-and-non-dash-if-iop/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-key-rotation-cbcs/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-key-rotation-cbcs/bear-640x360-audio-init.mp4
index 136514d671..056b2ef832 100644
Binary files a/packager/app/test/testdata/live-profile-and-key-rotation-cbcs/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-key-rotation-cbcs/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile-and-key-rotation/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile-and-key-rotation/bear-640x360-audio-init.mp4
index 06cbf09f13..2b138e6923 100644
Binary files a/packager/app/test/testdata/live-profile-and-key-rotation/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile-and-key-rotation/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-profile/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-profile/bear-640x360-audio-init.mp4
index 1ba3d9abb9..825a8072d2 100644
Binary files a/packager/app/test/testdata/live-profile/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-profile/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-static-profile-with-time-in-segment-name/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-static-profile-with-time-in-segment-name/bear-640x360-audio-init.mp4
index 1ba3d9abb9..825a8072d2 100644
Binary files a/packager/app/test/testdata/live-static-profile-with-time-in-segment-name/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-static-profile-with-time-in-segment-name/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/live-static-profile/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/live-static-profile/bear-640x360-audio-init.mp4
index 1ba3d9abb9..825a8072d2 100644
Binary files a/packager/app/test/testdata/live-static-profile/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/live-static-profile/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/mp4-trailing-moov/bear-640x360-trailing-moov-audio.mp4 b/packager/app/test/testdata/mp4-trailing-moov/bear-640x360-trailing-moov-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/mp4-trailing-moov/bear-640x360-trailing-moov-audio.mp4 and b/packager/app/test/testdata/mp4-trailing-moov/bear-640x360-trailing-moov-audio.mp4 differ
diff --git a/packager/app/test/testdata/video-audio-ttml/bear-640x360-audio.mp4 b/packager/app/test/testdata/video-audio-ttml/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/video-audio-ttml/bear-640x360-audio.mp4 and b/packager/app/test/testdata/video-audio-ttml/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/video-audio-webvtt/bear-640x360-audio.mp4 b/packager/app/test/testdata/video-audio-webvtt/bear-640x360-audio.mp4
index 87f89a93c0..7128d250eb 100644
Binary files a/packager/app/test/testdata/video-audio-webvtt/bear-640x360-audio.mp4 and b/packager/app/test/testdata/video-audio-webvtt/bear-640x360-audio.mp4 differ
diff --git a/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/bear-640x360-audio-init.mp4 b/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/bear-640x360-audio-init.mp4
index 1ba3d9abb9..825a8072d2 100644
Binary files a/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/bear-640x360-audio-init.mp4 and b/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/bear-640x360-audio-init.mp4 differ
diff --git a/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.mpd b/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.mpd
index fa415453e9..e51298416e 100644
--- a/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.mpd
+++ b/packager/app/test/testdata/vtt-text-to-mp4-with-ad-cues/output.mpd
@@ -2,22 +2,22 @@
-
-
-
-
+
+
+
-
-
+
-
-
-
+
+
+
+
-
+
+
@@ -35,21 +35,21 @@
-
-
-
-
+
+
+
-
+
-
-
-
+
+
+
+
-
+
diff --git a/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-1.mp4 b/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-1.mp4
index 372bb7827e..0127cfffbb 100644
Binary files a/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-1.mp4 and b/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-1.mp4 differ
diff --git a/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-3.mp4 b/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-3.mp4
index c5ec848107..ec42c301b6 100644
Binary files a/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-3.mp4 and b/packager/app/test/testdata/wvm-input-without-stripping-parameters-set-nalus/bear-multi-configs-3.mp4 differ
diff --git a/packager/app/test/testdata/wvm-input/bear-multi-configs-1.mp4 b/packager/app/test/testdata/wvm-input/bear-multi-configs-1.mp4
index 372bb7827e..0127cfffbb 100644
Binary files a/packager/app/test/testdata/wvm-input/bear-multi-configs-1.mp4 and b/packager/app/test/testdata/wvm-input/bear-multi-configs-1.mp4 differ
diff --git a/packager/app/test/testdata/wvm-input/bear-multi-configs-3.mp4 b/packager/app/test/testdata/wvm-input/bear-multi-configs-3.mp4
index c5ec848107..ec42c301b6 100644
Binary files a/packager/app/test/testdata/wvm-input/bear-multi-configs-3.mp4 and b/packager/app/test/testdata/wvm-input/bear-multi-configs-3.mp4 differ
diff --git a/packager/media/codecs/es_descriptor.cc b/packager/media/codecs/es_descriptor.cc
index 639ce4b5c2..bc17c7a3f9 100644
--- a/packager/media/codecs/es_descriptor.cc
+++ b/packager/media/codecs/es_descriptor.cc
@@ -219,7 +219,10 @@ bool ESDescriptor::ReadData(BitReader* reader) {
void ESDescriptor::WriteInternal(BufferWriter* writer) {
WriteHeader(writer);
- writer->AppendInt(esid_);
+ // According to ISO/IEC 14496-14:2018 Section 4.1.2,
+ // ES_ID is set to 0 when stored
+ const uint16_t kEsid = 0;
+ writer->AppendInt(kEsid);
const uint8_t kNoEsFlags = 0;
writer->AppendInt(kNoEsFlags);
diff --git a/packager/media/codecs/es_descriptor.h b/packager/media/codecs/es_descriptor.h
index e4caaf2b72..674a6620c0 100644
--- a/packager/media/codecs/es_descriptor.h
+++ b/packager/media/codecs/es_descriptor.h
@@ -175,7 +175,6 @@ class ESDescriptor : public BaseDescriptor {
ESDescriptor() : BaseDescriptor(DescriptorTag::kES) {}
uint16_t esid() const { return esid_; }
- void set_esid(uint16_t esid) { esid_ = esid; }
const DecoderConfigDescriptor& decoder_config_descriptor() const {
return decoder_config_descriptor_;
diff --git a/packager/media/codecs/es_descriptor_unittest.cc b/packager/media/codecs/es_descriptor_unittest.cc
index 2bd32c5a8d..2458d121e1 100644
--- a/packager/media/codecs/es_descriptor_unittest.cc
+++ b/packager/media/codecs/es_descriptor_unittest.cc
@@ -21,7 +21,7 @@ TEST(ESDescriptorTest, SingleByteLengthTest) {
// ESDescriptor tag with one byte size.
0x03, 0x19,
// ESDescriptor fields.
- 0x00, 0x01, 0x00,
+ 0x00, 0x00, 0x00,
// DecoderConfigDescriptor tag with one byte size.
0x04, 0x11,
// Object Type.
@@ -56,6 +56,19 @@ TEST(ESDescriptorTest, SingleByteLengthTest) {
EXPECT_THAT(
std::vector(writer.Buffer(), writer.Buffer() + writer.Size()),
ElementsAreArray(kBuffer));
+
+ EXPECT_EQ(0u, es_desc.esid());
+ const size_t kEsIdOffset = 3;
+ const uint8_t kEsId = 5;
+ data[kEsIdOffset] = kEsId;
+ ASSERT_TRUE(es_desc.Parse(data));
+ EXPECT_EQ(kEsId, es_desc.esid());
+
+ writer.Clear();
+ es_desc.Write(&writer);
+ EXPECT_THAT(
+ std::vector(writer.Buffer(), writer.Buffer() + writer.Size()),
+ ElementsAreArray(kBuffer));
}
TEST(ESDescriptorTest, NonAACTest) {
@@ -64,7 +77,7 @@ TEST(ESDescriptorTest, NonAACTest) {
// ESDescriptor tag with one byte size.
0x03, 0x19,
// ESDescriptor fields.
- 0x00, 0x01, 0x00,
+ 0x00, 0x00, 0x00,
// DecoderConfigDescriptor tag with one byte size.
0x04, 0x11,
// Object Type.
diff --git a/packager/media/formats/mp4/box_definitions_unittest.cc b/packager/media/formats/mp4/box_definitions_unittest.cc
index 96b9413ffd..19526922ae 100644
--- a/packager/media/formats/mp4/box_definitions_unittest.cc
+++ b/packager/media/formats/mp4/box_definitions_unittest.cc
@@ -383,7 +383,6 @@ class BoxDefinitionsTestGeneral : public testing::Test {
void Fill(ElementaryStreamDescriptor* esds) {
const uint8_t kDecoderSpecificInfo[] = {18, 16};
- esds->es_descriptor.set_esid(1);
esds->es_descriptor.mutable_decoder_config_descriptor()->set_object_type(
ObjectType::kISO_14496_3);
std::vector decoder_specific_info(
@@ -394,10 +393,6 @@ class BoxDefinitionsTestGeneral : public testing::Test {
->set_data(decoder_specific_info);
}
- void Modify(ElementaryStreamDescriptor* esds) {
- esds->es_descriptor.set_esid(2);
- }
-
void Fill(DTSSpecific* ddts) {
const uint8_t kDdtsExtraData[] = {0xe4, 0x7c, 0, 4, 0, 0x0f, 0};
ddts->max_bitrate = 768000;
diff --git a/packager/media/formats/mp4/mp4_muxer.cc b/packager/media/formats/mp4/mp4_muxer.cc
index 73dff8f4f9..356d7a9e9b 100644
--- a/packager/media/formats/mp4/mp4_muxer.cc
+++ b/packager/media/formats/mp4/mp4_muxer.cc
@@ -250,15 +250,15 @@ Status MP4Muxer::DelayInitializeMuxer() {
switch (stream->stream_type()) {
case kStreamVideo:
generate_trak_result = GenerateVideoTrak(
- static_cast(stream), &trak, i + 1);
+ static_cast(stream), &trak);
break;
case kStreamAudio:
generate_trak_result = GenerateAudioTrak(
- static_cast(stream), &trak, i + 1);
+ static_cast(stream), &trak);
break;
case kStreamText:
generate_trak_result = GenerateTextTrak(
- static_cast(stream), &trak, i + 1);
+ static_cast(stream), &trak);
break;
default:
NOTIMPLEMENTED() << "Not implemented for stream type: "
@@ -395,8 +395,7 @@ void MP4Muxer::InitializeTrak(const StreamInfo* info, Track* trak) {
}
bool MP4Muxer::GenerateVideoTrak(const VideoStreamInfo* video_info,
- Track* trak,
- uint32_t track_id) {
+ Track* trak) {
InitializeTrak(video_info, trak);
// width and height specify the track's visual presentation size as
@@ -449,8 +448,7 @@ bool MP4Muxer::GenerateVideoTrak(const VideoStreamInfo* video_info,
}
bool MP4Muxer::GenerateAudioTrak(const AudioStreamInfo* audio_info,
- Track* trak,
- uint32_t track_id) {
+ Track* trak) {
InitializeTrak(audio_info, trak);
trak->header.volume = 0x100;
@@ -460,7 +458,6 @@ bool MP4Muxer::GenerateAudioTrak(const AudioStreamInfo* audio_info,
CodecToFourCC(audio_info->codec(), H26xStreamFormat::kUnSpecified);
switch(audio_info->codec()){
case kCodecAAC: {
- audio.esds.es_descriptor.set_esid(track_id);
DecoderConfigDescriptor* decoder_config =
audio.esds.es_descriptor.mutable_decoder_config_descriptor();
decoder_config->set_object_type(ObjectType::kISO_14496_3); // MPEG4 AAC.
@@ -494,7 +491,6 @@ bool MP4Muxer::GenerateAudioTrak(const AudioStreamInfo* audio_info,
audio.dfla.data = audio_info->codec_config();
break;
case kCodecMP3: {
- audio.esds.es_descriptor.set_esid(track_id);
DecoderConfigDescriptor* decoder_config =
audio.esds.es_descriptor.mutable_decoder_config_descriptor();
uint32_t samplerate = audio_info->sampling_frequency();
@@ -567,8 +563,7 @@ bool MP4Muxer::GenerateAudioTrak(const AudioStreamInfo* audio_info,
}
bool MP4Muxer::GenerateTextTrak(const TextStreamInfo* text_info,
- Track* trak,
- uint32_t track_id) {
+ Track* trak) {
InitializeTrak(text_info, trak);
if (text_info->codec_string() == "wvtt") {
diff --git a/packager/media/formats/mp4/mp4_muxer.h b/packager/media/formats/mp4/mp4_muxer.h
index 58d1bb3dee..67e625b291 100644
--- a/packager/media/formats/mp4/mp4_muxer.h
+++ b/packager/media/formats/mp4/mp4_muxer.h
@@ -48,15 +48,9 @@ class MP4Muxer : public Muxer {
// Generate Audio/Video Track box.
void InitializeTrak(const StreamInfo* info, Track* trak);
- bool GenerateAudioTrak(const AudioStreamInfo* audio_info,
- Track* trak,
- uint32_t track_id);
- bool GenerateVideoTrak(const VideoStreamInfo* video_info,
- Track* trak,
- uint32_t track_id);
- bool GenerateTextTrak(const TextStreamInfo* video_info,
- Track* trak,
- uint32_t track_id);
+ bool GenerateAudioTrak(const AudioStreamInfo* audio_info, Track* trak);
+ bool GenerateVideoTrak(const VideoStreamInfo* video_info, Track* trak);
+ bool GenerateTextTrak(const TextStreamInfo* video_info, Track* trak);
// Gets |start| and |end| initialization range. Returns true if there is an
// init range and sets start-end byte-range-spec specified in RFC2616.