moq-rs/media/fragment

13 lines
432 B
Plaintext
Raw Normal View History

2022-11-08 13:18:35 +00:00
#!/bin/bash
2023-04-27 20:21:16 +00:00
cd "$(dirname "$0")"
# empty_moov: Uses moof fragments instead of one giant moov/mdat pair.
# frag_every_frame: Creates a moof for each frame.
# separate_moof: Splits audio and video into separate moof flags.
# omit_tfhd_offset: Removes absolute byte offsets so we can fragment.
2023-05-08 16:30:32 +00:00
ffmpeg -i source.mp4 -y \
-c copy \
2023-04-27 20:21:16 +00:00
-movflags empty_moov+frag_every_frame+separate_moof+omit_tfhd_offset \
2023-05-08 16:30:32 +00:00
fragmented.mp4 2>&1