diff options
author | Edward Hervey <bilboed@bilboed.com> | 2009-06-17 16:20:25 +0200 |
---|---|---|
committer | Edward Hervey <bilboed@bilboed.com> | 2009-06-24 12:48:32 +0200 |
commit | 30dd45856736a7cbeb6c867139a9eb5a111a2452 (patch) | |
tree | 8e9b4da9e79fb6565d5c2515a77654d426761cf6 /gst/qtdemux | |
parent | 4e6808bc5266797e4602cef53a3cffa71045b77b (diff) |
qtdemux: Take last sample duration for dummy segment calculation.
This fixes the cases where files without EDL wouldn't output their
last buffer.
Diffstat (limited to 'gst/qtdemux')
-rw-r--r-- | gst/qtdemux/qtdemux.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gst/qtdemux/qtdemux.c b/gst/qtdemux/qtdemux.c index 639338a9..a7d677ca 100644 --- a/gst/qtdemux/qtdemux.c +++ b/gst/qtdemux/qtdemux.c @@ -3824,10 +3824,12 @@ done: stream->segments = g_new (QtDemuxSegment, 1); /* samples know best */ - if (stream->n_samples > 0) + if (stream->n_samples > 0) { stream_duration = stream->samples[stream->n_samples - 1].timestamp + - stream->samples[stream->n_samples - 1].pts_offset; + stream->samples[stream->n_samples - 1].pts_offset + + stream->samples[stream->n_samples - 1].duration; + } stream->segments[0].time = 0; stream->segments[0].stop_time = stream_duration; |