On Thu, Apr 16, 2009 at 8:04 AM, Mike Kazmier <[email protected]> wrote: > We are using libavcodec to decode various types of video streams. To date, > we have not found a way to get the PTS set in the decoded frame. What we do > now is maintain a "queue" of PTS values, and sort these, then assign the > lowest PTS to the next frame that comes out of the decoder because the > decoder seems to consistently deliver frames in display order. While this > mostly works, its a terrible hack and I think we're doing something wrong. > Is there a some setting we need to enable in our context in order to have > libavcodec attach the correct PTS to our decoded frames? >
Take a look at ffplay.c; it uses the relatively recently introduced reorded_opaque field in the AVCodecContext and AVFrame objects to make sure the PTS of a returned AVFrame actually is correct. - Art -- http://www.xuggle.com/ xu‧ggle (zŭ' gl) v. To freely encode, decode, and experience audio and video. Use Xuggle to get the power of FFMPEG in Java. _______________________________________________ libav-user mailing list [email protected] https://lists.mplayerhq.hu/mailman/listinfo/libav-user
