diff options
author | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2008-05-23 21:51:33 +0000 |
---|---|---|
committer | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2008-05-23 21:51:33 +0000 |
commit | 7ef94d221bf3fa7ae893c034d8d388542f63e017 (patch) | |
tree | 945024c019019ede5c0aba7b7c5361114c8c877e /libavformat/flvdec.c | |
parent | 19719bc631fe505e0d88489653c3b9ef75a520e8 (diff) | |
download | ffmpeg-7ef94d221bf3fa7ae893c034d8d388542f63e017.tar.gz |
in flv this field is dts finally
Originally committed as revision 13268 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/flvdec.c')
-rw-r--r-- | libavformat/flvdec.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c index 3ff88681a5..2ae375da80 100644 --- a/libavformat/flvdec.c +++ b/libavformat/flvdec.c @@ -281,7 +281,7 @@ static int flv_read_header(AVFormatContext *s, static int flv_read_packet(AVFormatContext *s, AVPacket *pkt) { int ret, i, type, size, flags, is_audio, next, pos; - unsigned pts; + unsigned dts; AVStream *st = NULL; for(;;){ @@ -289,9 +289,9 @@ static int flv_read_packet(AVFormatContext *s, AVPacket *pkt) url_fskip(s->pb, 4); /* size of previous packet */ type = get_byte(s->pb); size = get_be24(s->pb); - pts = get_be24(s->pb); - pts |= get_byte(s->pb) << 24; -// av_log(s, AV_LOG_DEBUG, "type:%d, size:%d, pts:%d\n", type, size, pts); + dts = get_be24(s->pb); + dts |= get_byte(s->pb) << 24; +// av_log(s, AV_LOG_DEBUG, "type:%d, size:%d, dts:%d\n", type, size, dts); if (url_feof(s->pb)) return AVERROR(EIO); url_fskip(s->pb, 3); /* stream id, always 0 */ @@ -337,7 +337,7 @@ static int flv_read_packet(AVFormatContext *s, AVPacket *pkt) continue; } if ((flags & FLV_VIDEO_FRAMETYPE_MASK) == FLV_FRAME_KEY) - av_add_index_entry(st, pos, pts, size, 0, AVINDEX_KEYFRAME); + av_add_index_entry(st, pos, dts, size, 0, AVINDEX_KEYFRAME); break; } @@ -376,7 +376,7 @@ static int flv_read_packet(AVFormatContext *s, AVPacket *pkt) /* note: we need to modify the packet size here to handle the last packet */ pkt->size = ret; - pkt->pts = pts; + pkt->dts = dts; pkt->stream_index = st->index; if (is_audio || ((flags & FLV_VIDEO_FRAMETYPE_MASK) == FLV_FRAME_KEY)) |