summaryrefslogtreecommitdiff
path: root/libavformat/hlsenc.c
Commit message (Collapse)AuthorAge
* avformat/hlsenc: Warn if a non file protocol is usedMichael Niedermayer2015-02-23
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: Use ff_rename() only for local filesMichael Niedermayer2015-02-21
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* hlsenc: write playlist into a temp file and replace the original atomicallyHendrik Leppkes2015-02-21
| | | | | Reviewed-by: Lukasz Marek <lukasz.m.luki2@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* hlsenc: remove the AVIOContext for the playlist from the muxer contextHendrik Leppkes2015-02-20
| | | | | | Its only used in one function, having it in the context serves no purpose. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: more robust error testsMichael Niedermayer2015-01-11
| | | | | | errors are negative throughout ffmpeg Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: Use avio_closep() to avoid leaving stale pointers in memoryMichael Niedermayer2015-01-08
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: Use av_freep() to avoid leaving stale pointers in memoryMichael Niedermayer2014-12-16
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: fix hls_write_trailer() on hls_start() failureChristian Suloway2014-12-16
| | | | | | | | Close segment I/O context and append segment in hls_write_trailer() only when segment I/O context is allocated. Signed-off-by: Christian Suloway <csuloway@globaleagleent.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: added segment file deletionChristian Suloway2014-12-10
| | | | | | | | | This option flag deletes segment files removed from the playlist after a period of time equal to the duration of the segment plus the duration of the playlist. Signed-off-by: Christian Suloway <csuloway@globaleagleent.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: added segment filename optionChristian Suloway2014-12-06
| | | | | | | | | | | | | This option allows segment filenames to be specified. Unless -hls_flags single_file is set the filename is used as a string format with the segment number. Example: ffmpeg -f lavfi -i testsrc -c:v h264 -map 0 -hls_segment_filename bar%03d.ts foo.m3u8 Signed-off-by: Christian Suloway <csuloway@globaleagleent.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avformat/hlsenc: Free context after hls_append_segmentMichael Niedermayer2014-11-16
| | | | | | Fixes reading uninitialized memory Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* hlsenc.c, segment.c: propagate defaults to mpegtsMika Raento2014-10-17
| | | | | | | | | This fixes the abnormally high ts overhead in the files produced by the HLS and segments muxers. See https://trac.ffmpeg.org/ticket/2857 . For example makes it much more likely that it can produces streams that fit under the 64kb App store limit. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* Merge commit '28816050e47b6dba430a52e429d21a864cffda8e'Michael Niedermayer2014-10-07
|\ | | | | | | | | | | | | | | | | | | * commit '28816050e47b6dba430a52e429d21a864cffda8e': lavf: Set the stream time base hint properly for chained muxers Conflicts: libavformat/segment.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: Set the stream time base hint properly for chained muxersMartin Storsjö2014-10-06
| | | | | | | | | | | | | | This avoids warnings about using the codec time base as time base hint. Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit '55f03d872640175a00bfa262da4652b7312b905f'Michael Niedermayer2014-10-03
|\| | | | | | | | | | | | | | | | | | | | | | | | | * commit '55f03d872640175a00bfa262da4652b7312b905f': hlsenc: Add parameter -hls_allow_cache Conflicts: doc/muxers.texi libavformat/hlsenc.c libavformat/version.h See: 3edb9aaea6aaa6b93d708693cfa6454c17e03732 Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hlsenc: Add parameter -hls_allow_cacheJoakim Roubert2014-10-03
| | | | | | | | | | | | | | | | | | | | | | | | | | The -hls_allow_cache parameter enables explicitly setting the EXT-X-ALLOW-CACHE tag in the manifest file. That tag indicates whether the client MAY or MUST NOT cache downloaded media segments for later replay. Valid values are 1 (=YES) or 0 (=NO) and the EXT-X-ALLOW-CACHE will not show in the manifest for other values (or if -hls_allow_cache is not used. Signed-off-by: Martin Storsjö <martin@martin.st>
* | avformat/hlsenc: fix outter typoMichael Niedermayer2014-09-29
| | | | | | | | | | Found-by: beastd Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: export inner muxer timebaseMichael Niedermayer2014-09-28
| | | | | | | | | | | | | | Fixes "Non-monotonous DTS in output stream 0:0" Fies Ticket 3797 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: Added parameter -hls_allow_cacheJoakim Roubert2014-09-28
| | | | | | | | | | | | | | | | | | | | | | | | | | The -hls_allow_cache parameter enables explicitly setting the EXT-X-ALLOW-CACHE tag in the manifest file. That tag indicates whether the client MAY or MUST NOT cache downloaded media segments for later replay. Valid values are 1 (=YES) or 0 (=NO) and the EXT-X-ALLOW-CACHE will not show in the manifest for other values (or if -hls_allow_cache is not used. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf/hls: add hls_ts_optionSteven Liu2014-09-16
| | | | | | | | | | | | Same as COMMITID 4f5493fe2380ad4aba67759baa7d7d4437f2e776. Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
* | hlsenc: single_file, support HLS ver 4 byterangesMika Raento2014-09-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds a new option -hls_flags single_file that creates one .ts file for HLS and adds byteranges to the .m3u8 file, instead of creating one .ts file for each segment. This is helpful at least for storing large number of videos, as the number of files per video is drastically reduced and copying and storing those files takes less requests and inodes. This is based on work by Nicolas Martyanoff, discussed on ffmpeg-devel in July 2014. That patch seems abandoned by the author, and contained unrelated changes. This patch tries to add the minimum amount of code to support the byterange playlists. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: add some empty lines to make the code easier to readNicolas Martyanoff2014-07-31
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: rename some identifers to make the code easier to readNicolas Martyanoff2014-07-31
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: Add some comments to make the code easier to readNicolas Martyanoff2014-07-31
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: fix cleanup after avformat_write_header()Nicolas Martyanoff2014-07-29
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/mux: support re-interleaving packets in ff_write_chained()Michael Niedermayer2014-07-24
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: correctly compute target durationNicolas Martyanoff2014-07-10
| | | | | | | | | | | | | | | | | | | | With HLS, the duration of all segments must be lower or equal to the target duration. Therefore floor(duration + 0.5) yields incorrect results. For example, for duration = 1.35, floor(duration + 0.5) yields 1.0, but the correct result is 2.0. Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
* | Merge commit '34e2ce5dde073244ccb2b62f930e96fe612690f7'Michael Niedermayer2014-05-17
|\| | | | | | | | | | | | | * commit '34e2ce5dde073244ccb2b62f930e96fe612690f7': hlsenc: Set the default codecs to AAC and H264 Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hlsenc: Set the default codecs to AAC and H264Martin Storsjö2014-05-17
| | | | | | | | | | | | Most HLS implementation only support these codecs. Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit '7266e24f176389d2e81bfc7c829934f7c8ae361c'Michael Niedermayer2014-04-30
|\| | | | | | | | | | | | | | | | | | | * commit '7266e24f176389d2e81bfc7c829934f7c8ae361c': hls: Sync the file number with the start sequence Conflicts: libavformat/hlsenc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hls: Sync the file number with the start sequenceLuca Barbato2014-04-30
| |
* | Merge commit 'a16431034d9bd44182bf844d6bbde2c98bc4e6b5'Michael Niedermayer2014-04-30
|\| | | | | | | | | | | | | | | | | | | * commit 'a16431034d9bd44182bf844d6bbde2c98bc4e6b5': hls: Factor the sequence computation Conflicts: libavformat/hlsenc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hls: Factor the sequence computationLuca Barbato2014-04-30
| |
* | Merge commit 'c7603b3c243331057300337a61464e6ac4a605cb'Michael Niedermayer2014-04-30
|\| | | | | | | | | | | | | | | | | | | * commit 'c7603b3c243331057300337a61464e6ac4a605cb': hls: Print start_number as first sequence value Conflicts: libavformat/hlsenc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hls: Print start_number as first sequence valueLuca Barbato2014-04-30
| | | | | | | | The option now behaves as expected.
* | Merge commit '344f7b5a7e0d50573dec402dfe6228676f3889d9'Michael Niedermayer2014-04-30
|\| | | | | | | | | | | | | * commit '344f7b5a7e0d50573dec402dfe6228676f3889d9': hls: Report the current media sequence Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hls: Report the current media sequenceLuca Barbato2014-04-30
| | | | | | | | Useful for debugging mostly.
* | Merge commit '5a70a783f04919514efec7751d710b64d8975fd7'Michael Niedermayer2014-04-29
|\| | | | | | | | | | | | | | | | | | | | | * commit '5a70a783f04919514efec7751d710b64d8975fd7': hls: Add an option to prepend a baseurl to the playlist entries Conflicts: doc/muxers.texi libavformat/hlsenc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hls: Add an option to prepend a baseurl to the playlist entriesLuca Barbato2014-04-29
| | | | | | | | | | | | Useful to generate playlists with absolute paths. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | avformat/hlsenc: remove unneeded l prefix from %lfMichael Niedermayer2014-04-03
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | hlsenc: added floating point time support.Senthilnathan M2014-04-02
| | | | | | | | | | | | | | Necessary for HLS version 3 and above. Fixes ticket #3505. Signed-off-by: Senthilnathan M <senthil.codr@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | HLS: Handle the case when hls_list_size=0. Playlist file should contain all ↵Senthilnathan M2014-03-01
| | | | | | | | | | | | | | the segments. Fixes bug #3376. Signed-off-by: Senthilnathan M <senthil.codr@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/hlsenc: copy metadataMichael Niedermayer2013-12-12
| | | | | | | | | | | | Fixes Ticket2296 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2013-11-24
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: Add missing #includes for *INT64_MAX and *INT64_C Conflicts: ffmpeg.c ffmpeg_filter.c ffplay.c libavformat/assdec.c libavformat/avidec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * Add missing #includes for *INT64_MAX and *INT64_CDiego Biurrun2013-11-23
| |
| * hlsenc: Don't reset the number variable when wrappingCarl Eugen Hoyos2013-08-15
| | | | | | | | | | | | | | | | The counter itself shouldn't be wrapped, since it is used for determining end_pts for the next segment - only wrap the number used for the segment file name. Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge commit '09c93b1b957f2049ea5fd8fb0e6f4d82680172f2'Michael Niedermayer2013-08-16
|\| | | | | | | | | | | | | | | | | | | | | * commit '09c93b1b957f2049ea5fd8fb0e6f4d82680172f2': hlsenc: Append the last incomplete segment when closing the output Conflicts: libavformat/hlsenc.c See: 4630dfd1ebb6550f352ea69ce7150aaaba96d413 Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hlsenc: Append the last incomplete segment when closing the outputStefano Sabatini2013-08-15
| | | | | | | | | | | | | | Also avoid comparing NOPTS values. Bug-id: 551 Signed-off-by: Martin Storsjö <martin@martin.st>
* | lavf/hlsenc: fix bogus hls segment index rewrapping logicCarl Eugen Hoyos2013-06-06
| | | | | | | | | | | | | | | | | | The counter should not be reset since it detects the hls segment increasing timeframe. Fixes ticket #2643. Reviewed-by: Stefano Sabatini
* | Merge commit 'cf679b9476727a237c8006c685ace18acba149ab'Michael Niedermayer2013-04-28
|\| | | | | | | | | | | | | | | | | | | | | * commit 'cf679b9476727a237c8006c685ace18acba149ab': hls, segment: fix splitting for audio-only streams. Conflicts: libavformat/hlsenc.c libavformat/segment.c Merged-by: Michael Niedermayer <michaelni@gmx.at>