Re: Recommendations for DEMUXER layer
Arpi <[email protected]> Mon, 29 Dec 2003 20:53:40 +0100 (CET)
| Newsgroups | gmane.comp.video.mplayer.g2.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi, > > > OK, one more... > > > > > > 3. PTS handling is really bogus in some demuxers. Sometimes ds->pts is > > > scaled by rate_d, sometimes not. > > > > WTF? > > AVI demuxer outputs rate_m*framenumber for pts. huh? ah, i think i remember now. it was more clever idea behind it. to get frame number: frameno=ptsvalue/rate_d to get time position: seconds=ptsvalue/rate_m and ptsvalue is always integer and can produce accurate values for both things. so, demuxers for formats storing frame/chunk number (avi) will scale by rate_d, demuxers for timestamp-based formats (asf) will scale by rate_m so for both kind of formats, only integer*integer multiply is done, so no bit loss :) > > > My recommendation is for pts to always be in units of rate_d/rate_m. > > > > it _IS_ ok, it isn't... i was wrong :) A'rpi / Astral & ESP-team -- Developer of MPlayer G2, the Movie Framework for all - http://www.MPlayerHQ.hu