diff options
author | Aman Gupta <aman@tmm1.net> | 2017-02-07 11:58:43 +0800 |
---|---|---|
committer | Steven Liu <lq@chinaffmpeg.org> | 2017-02-07 11:58:43 +0800 |
commit | 606eac7b07133b0904c2b8b4eb1dc70e1bd0c9a6 (patch) | |
tree | 84a252f532df392adb787abaf11e523f3f866f08 /doc | |
parent | a6cee50fa206466f7a5fe8a46f87561a403ff52f (diff) | |
download | ffmpeg-streaming-606eac7b07133b0904c2b8b4eb1dc70e1bd0c9a6.zip ffmpeg-streaming-606eac7b07133b0904c2b8b4eb1dc70e1bd0c9a6.tar.gz |
avformat/hlsenc: add hls_flag option to write segments to temporary file until complete
Adds a `-hls_flags +temp_file` which will write segment data to
filename.tmp, and then rename to filename when the segment is complete.
This patch is similar in spirit to one used in Plex's ffmpeg fork, and
allows a transcoding webserver to ensure incomplete segment files are
never served up accidentally.
Reviewed-by: Hendrik Leppkes <h.leppkes@gmail.com>
Reviewed-by: Bodecs Bela <bodecsb@vivanet.hu>
Signed-off-by: Aman Gupta <aman@tmm1.net>
Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/muxers.texi | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/doc/muxers.texi b/doc/muxers.texi index d07ae9b..cb875a4 100644 --- a/doc/muxers.texi +++ b/doc/muxers.texi @@ -656,6 +656,11 @@ Makes it possible to use segment duration (calculated in microseconds) as %%t i expression besides date/time values when use_localtime is on. To get fixed width numbers with trailing zeroes, %%0xt format is available where x is the required width. +@item temp_file +Write segment data to filename.tmp and rename to filename only once the segment is complete. A webserver +serving up segments can be configured to reject requests to *.tmp to prevent access to in-progress segments +before they have been added to the m3u8 playlist. + @example ffmpeg -i sample.mpeg \ -f hls -hls_time 3 -hls_list_size 5 \ |