[FFmpeg-devel] [PATCH] libavu: add pkt_timebase to AVFrame.
george at nsup.org
Fri Jul 18 12:13:49 CEST 2014
Le decadi 30 messidor, an CCXXII, Benoit Fouet a écrit :
> + if (frame && av_frame_get_pkt_timebase(frame).num)
> + avpkt->duration = av_rescale_q(av_frame_get_pkt_duration(frame),
> + av_frame_get_pkt_timebase(frame),
> + avctx->time_base);
I suspect this is not a good idea at all: in a lot of cases,
av_frame_get_pkt_duration(frame) contains a random value not correlated to
the actual duration of the packet.
Making use of a field that was previously unused is an API change, and it
must be considered very carefully.
I suspect you can observe the inconsistent behaviour just by using ffmpeg
with a frame rate change, but I am not certain that is as simple as that.
Other applications may break more easily.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 819 bytes
Desc: Digital signature
More information about the ffmpeg-devel