summaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorSteven Liu <lq@chinaffmpeg.org>2017-07-07 10:05:54 +0800
committerSteven Liu <lq@chinaffmpeg.org>2017-07-07 10:05:54 +0800
commit23e21130bbbe3f9c7ee9050e3a720b6ba2767022 (patch)
treeff1949d17957b40d48211201f391fae68c028eed /libavformat
parentdc11a467e622d78330295d3973999c4d2d6beb03 (diff)
downloadffmpeg-streaming-23e21130bbbe3f9c7ee9050e3a720b6ba2767022.zip
ffmpeg-streaming-23e21130bbbe3f9c7ee9050e3a720b6ba2767022.tar.gz
avformat/hlsenc: add warn message when use both fmp4 and single_file
have not implementation the fmp4 single file yet before this commit. Suggested-by: Derek Buitenhuis <derek.buitenhuis@gmail.com> Signed-off-by: Steven Liu <lq@onvideo.cn>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/hlsenc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c
index dd6a62b..d93ca84 100644
--- a/libavformat/hlsenc.c
+++ b/libavformat/hlsenc.c
@@ -1304,9 +1304,14 @@ static int hls_write_header(AVFormatContext *s)
const char *pattern_localtime_fmt = get_default_pattern_localtime_fmt();
const char *vtt_pattern = "%d.vtt";
AVDictionary *options = NULL;
+ int byterange_mode = (hls->flags & HLS_SINGLE_FILE) || (hls->max_seg_size > 0);
int basename_size;
int vtt_basename_size;
+ if (hls->segment_type == SEGMENT_TYPE_FMP4 && byterange_mode) {
+ av_log(s, AV_LOG_WARNING, "Have not support fmp4 byterange mode yet now\n");
+ return AVERROR_PATCHWELCOME;
+ }
if ((hls->start_sequence_source_type == HLS_START_SEQUENCE_AS_SECONDS_SINCE_EPOCH) ||
(hls->start_sequence_source_type == HLS_START_SEQUENCE_AS_FORMATTED_DATETIME)) {
time_t t = time(NULL); // we will need it in either case
OpenPOWER on IntegriCloud