summaryrefslogtreecommitdiff
path: root/libavformat/hlsenc.c
Commit message (Collapse)AuthorAge
* avformat/hlsenc: avformat/hlsenc: add error message for encrypt fmp4 modeSteven Liu2018-04-16
| | | | | | | and refine the warning message when use both hls_key_info_file and hls_enc Reviewed-by: Gyan Doshi <ffmpeg@gyani.pro> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: add option hls_delete_thresholdSteven Liu2018-04-13
| | | | | | | | | | | When using hls_list_size with hls_flags delete_segments, currently hls_list_size * 2 +- segments remain on disk. With this new option, the amount of disk space used can be controlled by the user. fix ticket: #7131 Signed-off-by: Steven Liu <lq@chinaffmpeg.org> Signed-off-by: Aman Gupta <aman@tmm1.net>
* lavf/hlsenc: use ff_get_chomp_lineJun Zhao2018-04-12
| | | | Signed-off-by: Jun Zhao <mypopydev@gmail.com>
* avformat/hlsenc: fix handling of delete_segments when %v is presentBela Bodecs2018-04-11
| | | | | | | | | | | | | | | | | | | | When var_stream_map option is used, %v must appear either in segment name template or in the directory path. This latter case currently is not handled and delete_segments flag of hls_flags is broken now. This patch fix this. The root cause of the bug was that HLSSegment struct only stores the final filename part, but not the final directory path. Most of the cases, final path info is unneded, It only necessary when you want to delete old segments (e.g in case of live streaming). Without variant streams it was unnecessary to store the final directory path, because all segment were stored into the same directory. But introducing %v in directory names either require to store the final directory path into HLSSegment or associate segments with their variant streams to be able deleting them later. I have choosen the second solution and introduced a variant index data member into the segment struct. Signed-off-by: Bela Bodecs <bodecsb@vivanet.hu> Signed-off-by: Steven Liu <lq@onvideo.cn>
* avformat/hlsenc: initialize saveptrsTimo Rothenpieler2018-03-27
| | | | | | | | | | av_strtok calls strspn on a non-NULL *saveptr, so not NULL initializing it is an issue. Fixes CID #1428568 Reviewed-by: Karthick Jeyapal <kjeyapal@akamai.com> Signed-off-by: Steven Liu <lq@onvideo.cn> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: use stream's maximum bit rate as fall-back advertised rateJan Ekström2018-03-25
| | | | | | | | | | Enables having proper bit rate values being written into the master playlist in case of hard-constrained VBR where the maximum bit rate utilized is known before hand. Does the same thing as movenc.c, for example. Signed-off-by: Jan Ekström <jan.ekstrom@aminocom.com>
* avformat/hlsenc: reindent after previous commitsSteven Liu2018-03-18
| | | | Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix fmp4 single init file problemSteven Liu2018-03-18
| | | | | | fix ticket: #7021 Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix memleak problem about fmp4_init_filenameSteven Liu2018-03-18
| | | | | | | move fmp4_init_filename init in if else for first fmp4_init_filename set value operation. Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: reindent after previous commitsSteven Liu2018-03-18
| | | | Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix write wrong init file URI string problemSteven Liu2018-03-18
| | | | | | fmp4_init_filename should append after base_output_dirname Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: Option to set timeout for socket I/O operationRavindra2018-03-14
| | | | Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix for zero EXTINF tag durationVishwanath Dixit2018-03-12
| | | | | | | This is the fix for bug https://trac.ffmpeg.org/ticket/7073 Tested-by: Brainiarc7 Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: add reference stream index for split segmentSteven Liu2018-03-02
| | | | | | | | | fix ticket: #7044 Get the first video stream to reference for split segment when there have more than one video stream Signed-off-by: Steven Liu <lq@chinaffmpeg.org> Reviewed-by: Karthick Jeyapal <kjeyapal@akamai.com>
* hlsenc: Fixing HLS_TEMP_FILE usage with HLS_SECOND_LEVEL_SEGMENT_...Bela Bodecs2018-02-23
| | | | | | | | | | | Currently using HLS_TEMP together with HLS_SECOND_LEVEL_SEGMENT_DURATION or HLS_SECOND_LEVEL_SEGMENT_SIZE gives error at end of each segment writing and the final segment file names do not contain the desired data. This patch fixes this bug by delaying the initilization of original segment filename after actual temp file renaming will skip the interfering. Signed-off-by: Bela Bodecs <bodecsb@vivanet.hu>
* avformat/hls: migrate to AVFormatContext->urlMarton Balint2018-01-28
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/hlsenc: use av_bprintf without buffer limit in ↵Marton Balint2018-01-28
| | | | | | | | replace_int_data_in_filename In preparation for the deprecation of AVFormatContext->filename. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/hlsenc: closed caption tags in the master playlistVishwanath Dixit2018-01-24
|
* avformat/hlsenc: Check that data is setBrendan McGrath2018-01-21
| | | | | | | | | | | | | | | If codecpar->extradata is not set (for example, when the stream goes through the 'tee' muxer), then a segfault occurs. This patch ensures the data variable is not null before attempting to access it Before the var_stream_map option was available - I was using the tee muxer to create each resolution as an individual stream. When running this configuration after the most recent hlsenc change I hit a segfault The most simple command which recreates the segfault is: ffmpeg -i in.ts -map 0:a -map 0:v -c:a aac -c:v h264 -f tee [select=\'a,v\':f=hls]tv_hls_hd.m3u8 Signed-off-by: Brendan McGrath <redmcg@redmandi.dyndns.org>
* avformat/hlsenc: Add CODECS attribute to master playlistKarthick Jeyapal2018-01-19
|
* avformat/hlsenc: creation of variant streams in subdirectoriesVishwanath Dixit2018-01-02
| | | | Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: configurable variant stream index position in filenamesVishwanath Dixit2018-01-02
|
* avformat/hlsenc: revamped master playlist url creation logicVishwanath Dixit2018-01-02
|
* avformat/hlsenc, utils: Moved is_http_proto from hlsenc to utils for re-useKarthick Jeyapal2017-12-29
| | | | | Reviewed-by: Aman Gupta <aman@tmm1.net> Reviewed-by: Steven Liu <lq@onvideo.cn>
* avformat/hlsplaylist: Audio rendition's name and defaultness made configurableKarthick Jeyapal2017-12-29
| | | | Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: Modularized audio rendition playlist write to allow reuseKarthick Jeyapal2017-12-29
| | | | Reviewed-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix resource leakSteven Liu2017-12-25
| | | | fix CID: 1426931 1426929
* avformat/hlsenc: Signal http end of chunk(http_shutdown) during ↵Karthick Jeyapal2017-12-25
| | | | | | | | hlsenc_io_close() Currently http end of chunk is signalled implicitly in hlsenc_io_open(). This mean playlists http writes would have to wait upto a segment duration to signal end of chunk causing delays. This patch will fix that problem and improve performance.
* avformat/hlsenc:addition of #EXT-X-MEDIA tag and AUDIO attributeVishwanath Dixit2017-12-23
| | | | Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: set EXT-X-TARGETDURATION use lrint(EXTINF)Karthick J2017-12-22
|
* avformat/hlsenc: Fix a memory leak when http_persistent is 1Karthick J2017-12-21
| | | | Reviewed-by: Steven Liu <lq@onvideo.cn>
* avformat/hlsenc: reindent after previous commitsSteven Liu2017-12-21
| | | | | Reviewed-by: Karthick J <kjeyapal@akamai.com> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix first fragment mp4 do not split bugSteven Liu2017-12-21
| | | | | | | fix ticket id: 6888 Tested-by: beloko <beloko@gmail.com> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: Extend persistent http connections to playlistsKarthick J2017-12-15
| | | | | | | | Before this patch persistent http connections would work only for media segments. The playlists were still opening a new connection everytime. This patch extends persistent http connections to playlists as well. Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: Handle NULL input in IO open and close utility functionsKarthick J2017-12-15
| | | | Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: Call avio_flush during persistent http connectionsKarthick J2017-12-15
| | | | | | | Since close is not called, during http persistent connection, flush needs to be called so that output is written on time. Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: reindent after previous commitsSteven Liu2017-12-12
|
* avformat/hlsenc: move init operations from write_header to initSteven Liu2017-12-11
| | | | | Reviewed-by: Vishwanath Dixit <vdixit@akamai.com> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix compiling error when disable-networkSteven Liu2017-12-04
|
* avformat/hlsplaylist: add int type of API ff_hls_write_file_entrySteven Liu2017-12-04
| | | | Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: fix baseurl missing last charRobert Nagy2017-12-04
| | | | Reviewed-by: Steven Liu <lq@onvideo.cn>
* avformat/hlsenc: Refactored 'get_int_from_double' function to allow reuseKarthick J2017-11-30
|
* avformat/hlsenc: Modularized playlist creation to allow reuseKarthick J2017-11-29
|
* libavformat/hlsenc: Persistent HTTP connections supported as an optionJeyapal, Karthick2017-11-29
|
* avformat/hlsenc: Fixed initial setting for end_ptsKarthick J2017-11-28
| | | | | | | | | | This patch fixes Bug #6868 Sometimes end_pts is getting initialized to audio stream's first pts, while the duration is calculated based on video stream's pts. In this patch the end_pts is initialized with the correct stream's first pts. Reviewed-by: Steven Liu <lq@onvideo.cn> Tested-by: beloko
* avformat/hlsenc: Added option to add EXT-X-INDEPENDENT-SEGMENTS tagKarthick J2017-11-24
|
* avformat/hlsenc: Refactor an inconsistent variable nameKarthick J2017-11-24
|
* avformat/hlsenc: Minor fix in setting http options for master playlistKarthick J2017-11-24
|
* avformat/hlsenc: use FFABS to instead of absSteven Liu2017-11-20
| | | | | Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/hlsenc: creation of hls master playlist fileVishwanath Dixit2017-11-20
| | | | Reviewed-by: Steven Liu <lingjiujianke@gmail.com>