[FFmpeg-devel] [PATCH] In get_video_frame(), use frame->pkt_pts rather than the deprecated reordered_opaque API, which is deprecated for this specific use.
Stefano Sabatini
stefano.sabatini-lala
Sat Jan 22 18:29:01 CET 2011
On date Sunday 2011-01-16 19:29:00 +0100, Michael Niedermayer encoded:
> On Sun, Jan 16, 2011 at 06:41:12PM +0100, Stefano Sabatini wrote:
> > ---
> > ffplay.c | 5 ++---
> > 1 files changed, 2 insertions(+), 3 deletions(-)
>
> ok if you added a av_log and diffed the output to make sure the values stay the
> same.
With the attached patch:
$ ffplay -loglevel debug slow.flv -nostats
[...]
pkt_pts:0 reordered_opaque:0
pkt_pts:1201 reordered_opaque:1201
pkt_pts:1235 reordered_opaque:1235
pkt_pts:1268 reordered_opaque:1268
pkt_pts:1301 reordered_opaque:1301
pkt_pts:1335 reordered_opaque:1335
pkt_pts:1368 reordered_opaque:1368
pkt_pts:1401 reordered_opaque:1401
pkt_pts:1435 reordered_opaque:1435
pkt_pts:1468 reordered_opaque:1468
pkt_pts:1502 reordered_opaque:1502
$ ffplay -loglevel debug -f video4linux2 /dev/video0 -nostats
[...]
pkt_pts:0 reordered_opaque:1295716878360213
pkt_pts:0 reordered_opaque:1295716878392241
pkt_pts:0 reordered_opaque:1295716878424240
pkt_pts:0 reordered_opaque:1295716878460225
pkt_pts:0 reordered_opaque:1295716878492244
pkt_pts:0 reordered_opaque:1295716878524256
pkt_pts:0 reordered_opaque:1295716878560294
pkt_pts:0 reordered_opaque:1295716878600246
pkt_pts:0 reordered_opaque:1295716878648249
pkt_pts:0 reordered_opaque:1295716878708263
pkt_pts:0 reordered_opaque:1295716878780285
pkt_pts:0 reordered_opaque:1295716878848275
pkt_pts:0 reordered_opaque:1295716878940307
pkt_pts:0 reordered_opaque:1295716879040322
pkt_pts:0 reordered_opaque:1295716879160314
pkt_pts:0 reordered_opaque:1295716879300289
pkt_pts:0 reordered_opaque:1295716879460302
pkt_pts:0 reordered_opaque:1295716879640305
pkt_pts:0 reordered_opaque:1295716879832292
I noticed the problem today when debugging the movie source, I can see in
avcodec_decode_video2() that the pkt_dts is set:
picture->pkt_dts= avpkt->dts;
but not pkt_pts.
I'll have a further look.
--
FFmpeg = Fabulous Fantastic Mastodontic Puritan Erroneous Gorilla
More information about the ffmpeg-devel
mailing list