Hi, I'm currently working on a project decoding mpeg2ts streams, and my problem is if can anyone explain to me why the PTS and DTS values seem to be inverted - each packet returned to me by avcodec_decode_video has the DTS in increasing order, but the PTS in every third packet is out of order.
This I know is expected behavior for an I B B P encoding, where it decodes packets in order I P B B P B B .. but needs to present I B B P B B P, but what I really don't understand is that if I display the video in order of DTS as they arrive from the decode function, I get a correct video, but if I sort the packets in order of PTS, I get an erratic video - so it seems to me that the dts in the packets is the actual presentation time ... The only clue I have is from dranger's tutorial: "However, ffmpeg reorders the packets so that the DTS of the packet being processed by avcodec_decode_video() will *always be the same* as the PTS of the frame it returns. " but sadly I don't really understand what that phrase means. -- Bogdan COANDA AIESEC Iasi AIESEC in Romania Mobile: +40-724 013 068 E-mail: [email protected] Website: www.aieseciasi.ro _____________________________________________________________________________ AIESEC - The international platform for young people to discover and develop their potential _______________________________________________ libav-user mailing list [email protected] https://lists.mplayerhq.hu/mailman/listinfo/libav-user
