[MPlayer-dev-eng] [BUG] [PATCH] Ogg/Theora frametime broken on 0-length packets

David Kuehling dvdkhlng at gmx.de
Sat Apr 30 15:26:12 CEST 2011


>>>>> "Reimar" == Reimar Döffinger <Reimar.Doeffinger at gmx.de> writes:

> On Sat, Apr 30, 2011 at 03:06:38PM +0200, David Kuehling wrote:
>> >>>>> "Reimar" == Reimar Döffinger <Reimar.Doeffinger at gmx.de> writes:
>> 
>> > On Sat, Apr 30, 2011 at 02:34:20PM +0200, David Kuehling wrote:
>> >> (Ogg/Theora is strictly constant-framerate, so there is no reason
>> to >> do the complex per-frame frametime computation anyway).
>> 
>> > That is wrong. Maybe it is for the tools you are using, but it is
>> not > by design.
>> 
>> Hmm, well, AFAIK, for the Theora embedding in Ogg as defined by the
>> Theora spec, frametime is a constant.  Variable framerate is only
>> possible by using a short frametime, and injecting emtpy packets
>> every now and then to pad between actual frames.
>> 
>> So that's what I was referring to.  Did I overlook something?

> At the very least that theora might be stored in other containers like
> mkv without such arbitrary restrictions.  

This is why I wrote _Ogg_/Theora is constant-framerate.  You're right my
patch checks for theora but should also check for the ogg container.

> Then there's the thing that I am unsure that e.g. the FFmpeg muxer
> does behave like this.

You really mean muxer not demuxer?  

> Not sure how "short frametime" is defined, but I would take a guess
> that this might be broken by your change.  

"Short frametime" is not defined.  Using a short frametime is just a
hack to emulate variable-framerate video with a fixed-framerate video
format such as Ogg/Theora.  No without my change that wouldn't work at
all, because all padding frames that come as 0-sized packets would get a
frametime of 0 assigned, thus the video plays back at 1/short_frametime
instead of the actual variable framerate of the video.

Note: with frametime I refer to frame duration, not pts.  

cheers,

David
-- 
GnuPG public key: http://user.cs.tu-berlin.de/~dvdkhlng/dk.gpg
Fingerprint: B17A DC95 D293 657B 4205  D016 7DEF 5323 C174 7D40
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20110430/51be7b78/attachment.asc>


More information about the MPlayer-dev-eng mailing list