Hi again, after reading more information about how currently ffmpeg/libav is interrelated (basically ffmpeg borrows from libav, but not vice versa), I decided to look into the sources to see how av_frame_get_best_effort_timestamp works.
It turns out that it is just a get accessor for best_effort_timestamp field and the corresponding set accessor (av_frame_set_best_effort_timestamp) is called twice (in avcodec_decode_video2 and in avcodec_decode_audio4) in the utils.c with a similar lines av_frame_set_best_effort_timestamp(..., guess_correct_pts(avctx, .... ); There's no any "best_effort" symbols in libav, but the function guess_correct_pts exists in libav, the code of both versions (ffmpeg vs libav) looks almost identical. So, probably one who wants to keep compatibility with both libraries should conditionally use either the field accessor (ffmpeg) or function (libav), but the feature actually exists in both libraries. Probably looking at how guess_correct_pts is called in ffmpeg one might probably always use guess_correct_pts instead of av_frame_get_best_effort_timestamp, but this is just a hypothesis. Max On Mon, Feb 23, 2015 at 2:31 PM, wm4 <[email protected]> wrote: > On Mon, 23 Feb 2015 13:51:33 +0300 > Max Vlasov <[email protected]> wrote: > > > Frankly, I thought that all alternatives should be considered _after_ > > av_frame_get_best_effort_timestamp returned AV_NOPTS_VALUE. At least the > > name suggests so. .... > > The heuristic in av_frame_get_best_effort_timestamp() is pretty weak, > and the function doesn't exist in Libav, so you don't have to use it. > It's really just a helper. > >
_______________________________________________ Libav-user mailing list [email protected] http://ffmpeg.org/mailman/listinfo/libav-user
