Stefano Sabatini
526bd7bdfa
lavf/segment: set segment end time when the first packet arrives
...
Avoid negative durations in case there is a single packet in the current
segment, since in that case the end time is still set to the previous
segment end time.
11 years ago
Stefano Sabatini
3d38c99041
lavf/segment: fix weird indent
11 years ago
Stefano Sabatini
b6a8c5245f
lavf/segment: show incoming packet duration in debug message
11 years ago
Stefano Sabatini
5acad50056
lavf/segment: only use reference frames for computing the segment end time
...
This avoids a systematic overestimate of the segments duration when there
are several streams.
Fix trac ticket #3724 .
11 years ago
Simon Thelen
fa6716c66d
libavformat/segment: change segment_list_size behavior to match hls_list_size behavior.
...
Make the segment muxer keep segment_list_size segments instead of
segment_list_size + 1 segments. This patch also changes the
documentation for segment_list_size to reduce possible confusion over
how many segments are kept.
this allows the segment list to
be limited to containing only one segment which used to be impossible
because a segment_list_size of 0 kept all the segments and a
segment_list_size of 1 kept 2 segments.
Signed-off-by: Simon Thelen <ffmpeg-dev@c-14.de>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
7125b6ca90
avformat/segment: remove gettimeofday() use, remove sys/time.h
...
It causes portability issues, and would need ifdef hell if its kept
Found-by: jamrial
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
b8d017adba
avformat/segment: simplify localtime* use
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Deti fliegl
8cda23f341
avformat/segment: Support cutting at clocktime
...
Signed-off-by: Deti fliegl <fliegl@baycom.de>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
1394e0a9e0
avformat/segment: Use av_malloc_array()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Luca Barbato
87a3ea3192
segment: Report the current media sequence
...
Useful for debugging mostly.
11 years ago
Enrique Arizón Benito
5c08ae4f37
segment: Add an option to prepend a string to the list entries
...
Useful to generate lists with absolute urls.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
11 years ago
Willy Aubry
65c95de213
avformat/HLS: modified EXT-X-MEDIA-SEQUENCE header in order to follow the HLS standard
...
When using the wrap option the EXT-X-MEDIA-SEQUENCE header of the playlist file was reset instead of being incremented.
It is now incremented by one for every media URI removed from the playlist file as the standard states.
Signed-off-by: Willy Aubry <waubry@viotech.net>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Stefano Sabatini
f57baf743f
lavf/segment: drop pointless variable oc from seg_write_packet()
11 years ago
Stefano Sabatini
169065fbfb
lavf/segment: remove duplicated and inconsistent cleanup code in seg_write_packet()
...
In particular, avoid to leave around the seg->avf pointer to freed
structure, and fix crash with:
ffmpeg -f lavfi -i testsrc -c:v h264 -map 0 -f segment foo-%d.ts
11 years ago
Stefano Sabatini
8937af7b6f
lavf/segment: increase logging level for message with segment start information
...
Help debugging.
11 years ago
Stefano Sabatini
c0f2e07135
lavf/segment: add a few log messages when avio_open2() fails
11 years ago
Stefano Sabatini
5e278c19c7
lavf/segment: add segment_list_entry_prefix option
...
This option allows to add a prefix to the segment list entry filenames.
Also set by default the list entry filenames to the corresponding
segment basename, consistent with the HLS muxer.
Based on an idea by Steven Liu <lingjiujianke@gmail.com>.
11 years ago
Stefano Sabatini
1120fd7852
lavf/segment: simplify logic and fix !=0 check on segment_end return value
...
A successfull return value can be > 0.
11 years ago
Billy Shambrook
67e507e10e
lavf/segment: log segments as they end to AV_LOG_VERBOSE
...
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
11 years ago
Stefano Sabatini
3b9f8e7cd9
lavf/segment: simplify segment_count update
...
Now segment_count mark the segment_count of the current segment.
11 years ago
Thilo Borgmann
d814a839ac
Reinstate proper FFmpeg license for all files.
11 years ago
Stefano Sabatini
71a2e5245c
lavf/segment: use AV_OPT_TIME_DURATION for time_delta
...
Simplify.
12 years ago
Stefano Sabatini
459dc81a64
lavf/segment: reindent after last commit
12 years ago
Stefano Sabatini
19ea08a11a
lavf/segment: add initial_offset option
...
Should address trac ticket #2224 .
12 years ago
Anton Khirnov
cf679b9476
hls, segment: fix splitting for audio-only streams.
...
CC:libav-stable@libav.org
12 years ago
Michael Niedermayer
0e02a5193f
segment: copy metadata
...
Fixes Ticket2230
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Stefano Sabatini
d95143ec82
lavf/segment: add support to ffconcat segment list
12 years ago
Stefano Sabatini
b3d2c6f8b9
lavf/segment: fix DTS inconsistencies with -reset_timestamps
...
The DTS needs to be resynched against the segment start PTS, or the
resulting DTS may result < PTS.
Reported-by: Owen Jones <riots6@gmail.com>
See thread:
Subject: [FFmpeg-user] pts/dts error using reset_timestamps while splitting a DVD
Date: Sat, 19 Jan 2013 08:58:27 +0000
12 years ago
Stefano Sabatini
a12787960e
lavf/segment: extend PTS debugging log with -reset_timestamps
12 years ago
Carl Eugen Hoyos
90020d7f4b
lavf/segment: use correct spelling and value for EXT-X-ALLOW-CACHE tag
...
Replace wrong "EXT-X-ALLOWCACHE" with "EXT-X-ALLOW-CACHE", and value 1/0
with YES/NO, as per spec.
Fix trac ticket #2228 .
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
12 years ago
Stefano Sabatini
e319725717
lavf/segment: exit immediately in case of invalid stream specifier
...
Avoid duplicated confusing error message, and propagate error code from
the failing avformat_match_stream_specifier() call.
12 years ago
Stefano Sabatini
bb539eb13a
lavf/segment: avoid failure in case -flags +live and -segment_times/frames are specified
...
The conflict does not apply any longer, since the M3U8 segment target
duration is re-computed every time a new segment is added to the list.
12 years ago
Stefano Sabatini
f4e4e5b841
lavf/segment: drop now pointless segment_list_close() function
12 years ago
Stefano Sabatini
ca68acd7ac
lavf/segment: mark #EXT-X-ENDLIST in M3U8 only at the end of stream
...
Should fix immediate playback termination.
In particular, should fix trac ticket #2172 .
12 years ago
Stefano Sabatini
30a40d4a55
lavf/segment: provide link to HTML M3U8 draft, also fix mentioned version in docs
12 years ago
Stefano Sabatini
d00df260ca
lavf/segment: do not auto-select a video stream with attached_pic disposition
...
In particular, fix trac ticket #2138 .
12 years ago
Stefano Sabatini
bbce913edf
lavf/segment: move reference stream selection code to a dedicated function
12 years ago
Stefano Sabatini
1de369a632
lavf/segment: remove now unused field list_max_segment_time
12 years ago
Stefano Sabatini
d4890c1068
lavf/segment: add support to segment list file entries sliding window listing
...
In particular, should fix trac ticket #1842 .
12 years ago
Stefano Sabatini
6b7d9d5153
lavf/segment: add SegmentListEntry and use it
...
This patch is propedeutic to the incoming patch which adds
support to sliding window segment listing.
12 years ago
Stefano Sabatini
0156dd6530
lavf/segment: add segment_frames option
...
This is meant to address trac ticket #1483 .
12 years ago
Stefano Sabatini
7a8face9fb
lavf/segment: add reference_stream option
12 years ago
Stefano Sabatini
ecebf6fc82
lavf/segment: provide more debug feedback when a new segment starts
12 years ago
Stefano Sabatini
df5f9496e6
lavf/segment: add missing flags to segmenter option constants
12 years ago
Stefano Sabatini
ddf6131a0a
lavf/segment: add segment_start_number option
...
Consistent with the image2 muxer.
12 years ago
Stefano Sabatini
d93d03a492
lavf/segment: add function set_segment_filename()
...
Factorize.
12 years ago
Stefano Sabatini
8e9056559e
lavf/segment: add reset_timestamps option
...
The new options reset the timestamps at each new segment, so that the
generated segments will have timestamps starting close to 0.
It is meant to address trac ticket #1425 .
12 years ago
Stefano Sabatini
ad47ac20ae
lavf/segment: remove silly assert(), improve feedback
...
The code should not assert in case of invalid user input. Fails
gracefully instead.
12 years ago
Stefano Sabatini
8b6aeb1fcd
lavf/segment: fix value for the M3U8 EXT-X-MEDIA
...
From the M3U8 specification:
|The EXT-X-MEDIA-SEQUENCE tag indicates the sequence number of the first
|URI that appears in a Playlist file.
Previously it was using the list index number. Also remove now unused
list_count field.
12 years ago
Stefano Sabatini
5a1ac463e0
lavf/segment: do not pre-increment segment_idx value
...
Increment the value just when a new segment with the given index is
started. Simplify logic, improve readability.
12 years ago