[Libav-user] pts < dts error
YIRAN LI
mrfun.china at gmail.com
Tue Oct 13 12:36:14 CEST 2015
2015-10-13 21:17 GMT+11:00 Carl Eugen Hoyos <cehoyos at ag.or.at>:
> YIRAN LI <mrfun.china at ...> writes:
>
> > And does this mean, for any encoders that can
> > generate B frames, I need to do similar
> > pre-processing before calling av_write_frame()?
>
> No, only for encoders that produce broken pts/dts.
>
> Hi Carl,
I don't have the source code now so I don't know the bframes
configuration of the x264encoder.
But from one file I used I see that PTS == DTS. Could this be produced by
an encoder configure with non-zero max bframes? If yes, do I still need to
subtract that from PTS even if PTS == DTS?
If the encoder is configured with max b frames == 1, is it ok to subtract
2 from PTS?
Thanks
> So if I don't know possible max B frames, then I
> > can't use av_write_frame to correctly mux?
>
> You set max_bframes when you init the encoder.
>
> Feel free to subtract 1 from dts as an alternative.
>
> Carl Eugen
>
> _______________________________________________
> Libav-user mailing list
> Libav-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/libav-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20151013/164be09a/attachment.html>
More information about the Libav-user
mailing list