diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2007-08-09 16:29:30 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2007-08-09 16:29:30 +0000 |
commit | 874abace12a8fee0b74307939783dd4fc06ef906 (patch) | |
tree | 0a12fee27e0833ba2f09e8f59fed0993ea9dd476 /libavformat/nutdec.c | |
parent | 9cb5a11ea879fbbab45aaa28b13fccf1fc15b64f (diff) | |
download | ffmpeg-874abace12a8fee0b74307939783dd4fc06ef906.tar.gz |
move syncpoint timestamp resetting code to a common file
Originally committed as revision 10020 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/nutdec.c')
-rw-r--r-- | libavformat/nutdec.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/libavformat/nutdec.c b/libavformat/nutdec.c index 1ef7bcd73b..322ed2518e 100644 --- a/libavformat/nutdec.c +++ b/libavformat/nutdec.c @@ -447,7 +447,6 @@ static int decode_syncpoint(NUTContext *nut, int64_t *ts, int64_t *back_ptr){ AVFormatContext *s= nut->avf; ByteIOContext *bc = &s->pb; int64_t end, tmp; - int i; AVRational time_base; nut->last_syncpoint_pos= url_ftell(bc)-8; @@ -460,16 +459,7 @@ static int decode_syncpoint(NUTContext *nut, int64_t *ts, int64_t *back_ptr){ if(*back_ptr < 0) return -1; - time_base= nut->time_base[tmp % nut->time_base_count]; - for(i=0; i<s->nb_streams; i++){ - nut->stream[i].last_pts= av_rescale_rnd( - tmp / nut->time_base_count, - time_base.num * (int64_t)nut->stream[i].time_base->den, - time_base.den * (int64_t)nut->stream[i].time_base->num, - AV_ROUND_DOWN); - //last_key_frame ? - } - //FIXME put this in a reset func maybe + ff_nut_reset_ts(nut, nut->time_base[tmp % nut->time_base_count], tmp); if(skip_reserved(bc, end) || get_checksum(bc)){ av_log(s, AV_LOG_ERROR, "sync point checksum mismatch\n"); |