aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAurelien Jacobs <aurel@gnuage.org>2007-03-13 00:16:31 +0000
committerAurelien Jacobs <aurel@gnuage.org>2007-03-13 00:16:31 +0000
commit086b0ad8ca5d7e1420b8ffa3e757e31b23692e55 (patch)
treec06e45957154b2e98beac3801a53e849cfa52373
parent9b54ab15e74c1600a6298a0ff5b8ee5fbb2d6918 (diff)
downloadffmpeg-086b0ad8ca5d7e1420b8ffa3e757e31b23692e55.tar.gz
set pkt->duration for laced packets too
Originally committed as revision 8366 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r--libavformat/matroska.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/libavformat/matroska.c b/libavformat/matroska.c
index 548e84e29c..85232278cc 100644
--- a/libavformat/matroska.c
+++ b/libavformat/matroska.c
@@ -2593,6 +2593,7 @@ matroska_parse_block(MatroskaDemuxContext *matroska, uint8_t *data, int size,
pkt->pts = timecode;
pkt->pos = pos;
+ pkt->duration = duration;
if (matroska->tracks[track]->flags & MATROSKA_TRACK_REORDER)
matroska_queue_packet_reordered(matroska, pkt, is_bframe);
@@ -2692,14 +2693,6 @@ matroska_parse_blockgroup (MatroskaDemuxContext *matroska,
duration, is_keyframe, is_bframe,
&track, &pkt);
- if (pkt)
- {
- if (duration != AV_NOPTS_VALUE)
- pkt->duration = duration;
- else if (track >= 0 && track < matroska->num_tracks)
- pkt->duration = matroska->tracks[track]->default_duration;
- }
-
return res;
}