bypassing PTS in video filter layer
Arpi <[email protected]>
| Newsgroups | gmane.comp.video.mplayer.g2.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi, I have a problem. (who has no problems? :)) Currently the PTS info (absolute and relative timestamp, duration time) is stored in the mpi (mp_image_t) structure while going through the video filter layer. It's nice, and makes it's easy to handle frame delaying, reordering. But what happens at skipped/dropped frames? PTS info also gets dropped, so we end up guessing skipped time at the a-v sync core. The issue is already visible when playing that 405*.avi sample from mphq ftp. (it begins with around 4 seconds of zero (black, dropped) frames) I have 2 ideas to solve this, none of them is nice ;( method 1: always return an mpi, never return NULL (except for errors, maybe). also introduce a new mpi type, called NULL or ZERO. it means it only holds 'the place of picture', ie. timestamp and frame counter, but no actual image data. method 2: create a pts_info structure, and use it to hold PTS info through filters. it needs filter API changes, and i have no nice idea how to store/pass this data. (teh function return values is mpi or NULL, so it could be an offset-type parameter like process_image(mpi,&ptsinfo) maybe, but it makes frame delaying/reordering (including attaching ptsinfto to mpi frames) tricky) any better ideas? A'rpi / Astral & ESP-team -- Developer of MPlayer G2, the Movie Framework for all - http://www.MPlayerHQ.hu