|
|
|
@ -35,8 +35,10 @@ void ff_hls_write_playlist_version(AVIOContext *out, int version) { |
|
|
|
|
avio_printf(out, "#EXT-X-VERSION:%d\n", version); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void ff_hls_write_audio_rendition(AVIOContext *out, char *agroup, |
|
|
|
|
const char *filename, char *language, int name_id, int is_default) { |
|
|
|
|
void ff_hls_write_audio_rendition(AVIOContext *out, const char *agroup, |
|
|
|
|
const char *filename, const char *language, |
|
|
|
|
int name_id, int is_default) |
|
|
|
|
{ |
|
|
|
|
if (!out || !agroup || !filename) |
|
|
|
|
return; |
|
|
|
|
|
|
|
|
@ -48,8 +50,10 @@ void ff_hls_write_audio_rendition(AVIOContext *out, char *agroup, |
|
|
|
|
avio_printf(out, "URI=\"%s\"\n", filename); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void ff_hls_write_subtitle_rendition(AVIOContext *out, char *sgroup, |
|
|
|
|
const char *filename, char *language, int name_id, int is_default) { |
|
|
|
|
void ff_hls_write_subtitle_rendition(AVIOContext *out, const char *sgroup, |
|
|
|
|
const char *filename, const char *language, |
|
|
|
|
int name_id, int is_default) |
|
|
|
|
{ |
|
|
|
|
if (!out || !filename) |
|
|
|
|
return; |
|
|
|
|
|
|
|
|
@ -61,10 +65,11 @@ void ff_hls_write_subtitle_rendition(AVIOContext *out, char *sgroup, |
|
|
|
|
avio_printf(out, "URI=\"%s\"\n", filename); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void ff_hls_write_stream_info(AVStream *st, AVIOContext *out, |
|
|
|
|
int bandwidth, const char *filename, char *agroup, |
|
|
|
|
char *codecs, char *ccgroup, char *sgroup) { |
|
|
|
|
|
|
|
|
|
void ff_hls_write_stream_info(AVStream *st, AVIOContext *out, int bandwidth, |
|
|
|
|
const char *filename, const char *agroup, |
|
|
|
|
const char *codecs, const char *ccgroup, |
|
|
|
|
const char *sgroup) |
|
|
|
|
{ |
|
|
|
|
if (!out || !filename) |
|
|
|
|
return; |
|
|
|
|
|
|
|
|
@ -112,7 +117,7 @@ void ff_hls_write_playlist_header(AVIOContext *out, int version, int allowcache, |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void ff_hls_write_init_file(AVIOContext *out, char *filename, |
|
|
|
|
void ff_hls_write_init_file(AVIOContext *out, const char *filename, |
|
|
|
|
int byterange_mode, int64_t size, int64_t pos) { |
|
|
|
|
avio_printf(out, "#EXT-X-MAP:URI=\"%s\"", filename); |
|
|
|
|
if (byterange_mode) { |
|
|
|
@ -125,8 +130,8 @@ int ff_hls_write_file_entry(AVIOContext *out, int insert_discont, |
|
|
|
|
int byterange_mode, |
|
|
|
|
double duration, int round_duration, |
|
|
|
|
int64_t size, int64_t pos, //Used only if HLS_SINGLE_FILE flag is set
|
|
|
|
|
char *baseurl, //Ignored if NULL
|
|
|
|
|
char *filename, double *prog_date_time, |
|
|
|
|
const char *baseurl /* Ignored if NULL */, |
|
|
|
|
const char *filename, double *prog_date_time, |
|
|
|
|
int64_t video_keyframe_size, int64_t video_keyframe_pos, int iframe_mode) { |
|
|
|
|
if (!out || !filename) |
|
|
|
|
return AVERROR(EINVAL); |
|
|
|
|