summaryrefslogtreecommitdiffstats
path: root/libavformat/segment.c
Commit message (Collapse)AuthorAgeFilesLines
...
* | lavf/segment: slight refactor to seg_write_packetRodger Combs2016-04-021-5/+7
| | | | | | | | | | This reduces some code duplication, and ensures that cur_entry.last_duration is always set.
* | lavf/segment: style nitRodger Combs2016-04-021-1/+1
| |
* | lavf/segment: support automatic bitstream filteringRodger Combs2016-04-021-5/+25
| | | | | | | | | | Most useful for MPEG-TS. Works by having the underlying muxer configure the bitstream filters, then moving them to our own AVStreams.
* | avformat/segment: set format options for all segmentsMarton Balint2016-03-261-1/+5
| | | | | | | | | | | | | | Fixes ticket #5318. Reviewed-by: Stefano Sabatini <[email protected]> Signed-off-by: Marton Balint <[email protected]>
* | avformat/segment: Fix "occured" typoMichael Niedermayer2016-03-171-1/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | lavf/segment: change type of increment_tc to BOOLStefano Sabatini2016-03-151-1/+1
| |
* | lavf/segment: add increment_tc optionMartin Vignali2016-03-151-0/+32
| | | | | | | | | | | | | | | | | | For example you can split a file, keeping a continuous timecode between each segment: ffmpeg -i src.mov -timecode 10:00:00:00 -vcodec copy -f segment \ -segment_time 2 -reset_timestamps 1 -increment_tc 1 target_%03d.mov Signed-off-by: Stefano Sabatini <[email protected]>
* | avformat/segment: Fix header_filename handlingMichael Niedermayer2016-02-101-1/+3
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | Merge commit '9f61abc8111c7c43f49ca012e957a108b9cc7610'Derek Buitenhuis2016-02-101-14/+13
|\| | | | | | | | | | | | | | | | | This also deprecates our old duplicated callbacks. * commit '9f61abc8111c7c43f49ca012e957a108b9cc7610': lavf: allow custom IO for all files Merged-by: Derek Buitenhuis <[email protected]>
| * lavf: allow custom IO for all filesAnton Khirnov2016-01-241-18/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some (de)muxers open additional files beyond the main IO context. Currently, they call avio_open() directly, which prevents the caller from using custom IO for such streams. This commit adds callbacks to AVFormatContext that default to avio_open2()/avio_close(), but can be overridden by the caller. All muxers and demuxers using AVIO are switched to using those callbacks instead of calling avio_open()/avio_close() directly. (de)muxers that use the URLProtocol layer directly instead of AVIO remain unconverted for now. This should be fixed in later commits.
* | Update demuxers and protocols for protocol whitelist supportMichael Niedermayer2016-02-021-8/+9
| | | | | | | | | | Reviewed-by: Andreas Cadhalpun <[email protected]> Signed-off-by: Michael Niedermayer <[email protected]>
* | lavf/segment: add new option segment_clocktime_wrap_durationMarton Balint2016-01-281-1/+3
| | | | | | | | | | | | | | | | | | | | This option can force the segmenter to only start a new segment if a packet reaches the muxer within the specified duration after the segmenting clock time, which makes it more resilient to backward local time jumps, such as leap seconds or transition to standard time from daylight savings time. Reviewed-by: Stefano Sabatini <[email protected]> Signed-off-by: Marton Balint <[email protected]>
* | lavf/segment: add support for specifying clock time offsetMarton Balint2016-01-281-1/+10
| | | | | | | | | | Reviewed-by: Stefano Sabatini <[email protected]> Signed-off-by: Marton Balint <[email protected]>
* | avformat/segment: Fix memory leak of cur_entry.filenameLvqier2015-12-121-3/+3
| | | | | | | | | | Solution suggested-by: Hendrik Leppkes <[email protected]> Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat: use AV_OPT_TYPE_BOOL in a bunch of placesClément Bœsch2015-12-041-6/+6
| |
* | avformat/segment: atomically update list if possibleMichael Niedermayer2015-08-281-2/+12
| | | | | | | | | | | | Fixes Ticket4802 Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/segment: Do not free the filename twiceMichael Niedermayer2015-08-261-0/+1
| | | | | | | | | | | | Bug introduced in 83a508cda5115c61b456aeb227bf770d61010961 Signed-off-by: Michael Niedermayer <[email protected]>
* | lavf/segment: Fix memleak.Carl Eugen Hoyos2015-08-251-0/+1
| | | | | | | | | | Reviewed-by: Stefano Sabatini Reviewed-by: Ganesh Ajjanagadde
* | Replace av_dlog with ff_dlog.Ronald S. Bultje2015-08-181-1/+2
| | | | | | | | | | ff_dlog checks compilability, and is non-public. av_dlog is deprecated and no longer exists if FF_API_DLOG=0.
* | Merge commit '8a78ae2d2101622fd244b99178d8bc61175c878e'Michael Niedermayer2015-06-121-1/+2
|\| | | | | | | | | | | | | * commit '8a78ae2d2101622fd244b99178d8bc61175c878e': segment: Check open_null_ctx() return value Merged-by: Michael Niedermayer <[email protected]>
| * segment: Check open_null_ctx() return valueVittorio Giovara2015-06-121-1/+2
| | | | | | | | Reported-By: infer
* | lavf/segment: add an option to allow breaking on non-keyframesRodger Combs2015-06-091-1/+3
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/segment: Change enum to int, which is accessed via AVOption as intMichael Niedermayer2015-04-071-1/+1
| | | | | | | | | | | | This fixes depending on implementation defined behavior Signed-off-by: Michael Niedermayer <[email protected]>
* | lavf/segment: style nitsRodger Combs2015-03-311-4/+4
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | lavf/segment: Mark output contexts as non-seekable when applicableRodger Combs2015-03-291-0/+6
| | | | | | | | | | | | | | | | | | | | This prevents sub-muxers from trying to seek back to the beginning of the whole stream, only to find themselves overwriting some video data in the current (often last) segment. We only do this when not writing individual header/trailers. Signed-off-by: Michael Niedermayer <[email protected]>
* | libavformat/segment: add an option to write the header to a separate fileRodger Combs2015-03-291-3/+15
| | | | | | | | | | | | | | | | This permits some interesting segmenting techniques with formats like Matroska, where you can concatenate the header and segments [N, nb_segments) and get a working file that starts at segment N's start time. Signed-off-by: Michael Niedermayer <[email protected]>
* | libavformat/segment: don't leave the list pb open when not in useRodger Combs2015-03-291-4/+5
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | Merge commit 'daf8cf358a098a903d59adb6c0d0cc3262a8c93e'Michael Niedermayer2015-02-141-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'daf8cf358a098a903d59adb6c0d0cc3262a8c93e': avformat: Don't anonymously typedef structs Conflicts: libavformat/adtsenc.c libavformat/aiffenc.c libavformat/avidec.c libavformat/gif.c libavformat/iff.c libavformat/img2dec.c libavformat/jvdec.c libavformat/matroskadec.c libavformat/udp.c libavformat/wtvdec.c Merged-by: Michael Niedermayer <[email protected]>
| * avformat: Don't anonymously typedef structsDiego Biurrun2015-02-141-1/+1
| |
| * segment: Check av_get_frame_filename() return valueVittorio Giovara2015-01-231-1/+5
| | | | | | | | | | CC: [email protected] Bug-Id: CID 1265713
* | avformat/segment: Clear contexts after deallocationMichael Niedermayer2015-01-071-4/+5
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | Merge commit 'b3f04657368a32a9903406395f865e230b1de348'Michael Niedermayer2015-01-071-7/+20
|\| | | | | | | | | | | | | | | | | | | * commit 'b3f04657368a32a9903406395f865e230b1de348': segment: Fix the failure paths Conflicts: libavformat/segment.c Merged-by: Michael Niedermayer <[email protected]>
| * segment: Fix the failure pathsLuca Barbato2015-01-071-12/+20
| | | | | | | | | | | | | | | | | | A failure in segment_end() or segment_start() would lead to freeing a dangling pointer and in general further calls to seg_write_packet() or to seg_write_trailer() would have the same faulty behaviour. CC: [email protected] Reported-By: [email protected]
* | libavformat/segment.c: Add strftime expansion for segment filename templatesPedro E. M. Brito2014-12-281-2/+13
| | | | | | | | | | | | | | | | | | | | | | Allows expansion of the filename template with strftime() with the option -strftime 1 (disabled by default). This allows segments to be named by time of creation, adding some flexibility. Fixes Ticket 4104 (add strftime to segment muxer) Signed-off-by: Pedro E. M. Brito <[email protected]> Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/segment: Use av_freep() avoid leaving stale pointers in memoryMichael Niedermayer2014-12-251-7/+7
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/segment: export inner muxer timebaseMichael Niedermayer2014-11-161-0/+8
| | | | | | | | | | | | | | Fixes "Non-monotonous DTS in output stream 0:0" Fixes Ticket4020 Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/segment: use time_internal.h, simplify codeMichael Niedermayer2014-11-021-4/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | hlsenc.c, segment.c: propagate defaults to mpegtsMika Raento2014-10-171-0/+1
| | | | | | | | | | | | | | | | | | 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 <[email protected]>
* | Merge commit '28816050e47b6dba430a52e429d21a864cffda8e'Michael Niedermayer2014-10-071-0/+1
|\| | | | | | | | | | | | | | | | | | | * commit '28816050e47b6dba430a52e429d21a864cffda8e': lavf: Set the stream time base hint properly for chained muxers Conflicts: libavformat/segment.c Merged-by: Michael Niedermayer <[email protected]>
| * lavf: Set the stream time base hint properly for chained muxersMartin Storsjö2014-10-061-0/+1
| | | | | | | | | | | | | | This avoids warnings about using the codec time base as time base hint. Signed-off-by: Martin Storsjö <[email protected]>
| * cosmetics: Write NULL pointer inequality checks more compactlyGabriel Dume2014-08-151-1/+1
| | | | | | | | Signed-off-by: Diego Biurrun <[email protected]>
* | lavf/segment: abort in case of invalid segment format optionsStefano Sabatini2014-09-081-1/+4
| |
* | lavf/segment: add segment_format_options optionStefano Sabatini2014-09-071-2/+23
| |
* | segment: fix copying stream metadataMika Raento2014-09-021-0/+1
| | | | | | | | | | | | To get mpegts metadata copied when segmenting. Signed-off-by: Michael Niedermayer <[email protected]>
* | segment: use mpegts_flags instead of the deprecated resend_headers optionMika Raento2014-09-021-1/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/segment: Use avformat_alloc_output_context2()Michael Niedermayer2014-09-021-4/+5
| | | | | | | | | | | | | | | | This avoids having to assign oformat, allows returning the correct error code and allocates priv_data Based on patch by: Mika Raento <[email protected]> Signed-off-by: Michael Niedermayer <[email protected]>
* | segment: don't access outside seg->frames arrayMika Raento2014-09-021-1/+1
| | | | | | | | | | | | Fixes wrong number of segments output and undefined memory access. Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/segment: re-interleave packets if neededMichael Niedermayer2014-07-241-1/+1
| | | | | | | | | | | | Fixes part of Ticket 3797 Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/mux: support re-interleaving packets in ff_write_chained()Michael Niedermayer2014-07-241-1/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | lavf/segment: sanitize segment end time in case last packet do not have a ↵Stefano Sabatini2014-07-221-0/+6
| | | | | | | | | | | | | | | | defined duration In particular, avoids to set segments with duration set to 0 (e.g. segment with a single reference frame for which duration is undefined).