summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
authorSteven Liu <lq@chinaffmpeg.org>2021-11-18 14:58:55 +0800
committerSteven Liu <lq@chinaffmpeg.org>2021-12-13 18:45:37 +0800
commit6cf55b9da2b41d5c2b8a0b6e4405dd84858cae35 (patch)
tree3d79e7364f3fe0bc36e8e4d1e50fe7311f8ec5aa /libavformat
parent38fbe6a34cfe48c91156e26806aeb81e0dd09f77 (diff)
avformat/hlsenc: deprecate hls_ts_options option
Because the hls_ts_options will be misunderstand by user, and then user can use hls_segment_options instead of hls_ts_options. Signed-off-by: Steven Liu <liuqi05@kuaishou.com>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/hlsenc.c4
-rw-r--r--libavformat/version.h1
2 files changed, 4 insertions, 1 deletions
diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c
index b75c1cc746..459129818a 100644
--- a/libavformat/hlsenc.c
+++ b/libavformat/hlsenc.c
@@ -3101,7 +3101,9 @@ static const AVOption options[] = {
{"hls_init_time", "set segment length at init list", OFFSET(init_time), AV_OPT_TYPE_DURATION, {.i64 = 0}, 0, INT64_MAX, E},
{"hls_list_size", "set maximum number of playlist entries", OFFSET(max_nb_segments), AV_OPT_TYPE_INT, {.i64 = 5}, 0, INT_MAX, E},
{"hls_delete_threshold", "set number of unreferenced segments to keep before deleting", OFFSET(hls_delete_threshold), AV_OPT_TYPE_INT, {.i64 = 1}, 1, INT_MAX, E},
- {"hls_ts_options","set hls mpegts list of options for the container format used for hls", OFFSET(format_options), AV_OPT_TYPE_DICT, {.str = NULL}, 0, 0, E},
+#if FF_HLS_TS_OPTIONS
+ {"hls_ts_options","set hls mpegts list of options for the container format used for hls (deprecated, use hls_segment_options instead of it.)", OFFSET(format_options), AV_OPT_TYPE_DICT, {.str = NULL}, 0, 0, E | AV_OPT_FLAG_DEPRECATED},
+#endif
{"hls_vtt_options","set hls vtt list of options for the container format used for hls", OFFSET(vtt_format_options_str), AV_OPT_TYPE_STRING, {.str = NULL}, 0, 0, E},
{"hls_allow_cache", "explicitly set whether the client MAY (1) or MUST NOT (0) cache media segments", OFFSET(allowcache), AV_OPT_TYPE_INT, {.i64 = -1}, INT_MIN, INT_MAX, E},
{"hls_base_url", "url to prepend to each playlist entry", OFFSET(baseurl), AV_OPT_TYPE_STRING, {.str = NULL}, 0, 0, E},
diff --git a/libavformat/version.h b/libavformat/version.h
index 1623835a78..379a68cc7c 100644
--- a/libavformat/version.h
+++ b/libavformat/version.h
@@ -58,6 +58,7 @@
#define FF_API_LAVF_PRIV_OPT (LIBAVFORMAT_VERSION_MAJOR < 60)
#define FF_API_COMPUTE_PKT_FIELDS2 (LIBAVFORMAT_VERSION_MAJOR < 60)
#define FF_API_AVIOCONTEXT_WRITTEN (LIBAVFORMAT_VERSION_MAJOR < 60)
+#define FF_HLS_TS_OPTIONS (LIBAVFORMAT_VERSION_MAJOR < 60)
#define FF_API_AVSTREAM_CLASS (LIBAVFORMAT_VERSION_MAJOR > 59)