[Ffmpeg-cvslog] r8424 - trunk/libavformat/utils.c

Baptiste Coudurier baptiste.coudurier
Tue Mar 20 11:05:18 CET 2007


Hi

michael wrote:
> Author: michael
> Date: Fri Mar 16 23:59:45 2007
> New Revision: 8424
> 
> Modified:
>    trunk/libavformat/utils.c
> 
> Log:
> add a delay variable to hold the timestamp buffer size
> set cur_dts correctly for delay>1
> 
> [...]
> @@ -611,8 +612,7 @@ static void compute_pkt_fields(AVFormatC
>      }
>  
>      if(st->cur_dts == AV_NOPTS_VALUE){
> -        if(presentation_delayed) st->cur_dts = -pkt->duration;
> -        else                     st->cur_dts = 0;
> +        st->cur_dts = -delay * pkt->duration;
>      }
>  

Would adding a check for pkt->duration != AV_NOPTS_VALUE hurt here ?

It seems that for packets without pts and without duration (adpcm,
codecs with frame_size to 0) cur_dts gets set to 0 and then all packets
have pts == 0 while they should have pts == AV_NOPTS_VALUE.

-- 
Baptiste COUDURIER                              GnuPG Key Id: 0x5C1ABAAA
SMARTJOG S.A.                                    http://www.smartjog.com
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
Phone: +33 1 49966312




More information about the ffmpeg-cvslog mailing list