[MPlayer-dev-eng] [PATCH] compute correct length for theora videos

Reimar Döffinger Reimar.Doeffinger at stud.uni-karlsruhe.de
Mon May 12 11:06:58 CEST 2008


On Sun, May 11, 2008 at 01:01:25AM +0200, Julian Kniephoff wrote:
> this is a patch to let mplayer compute the correct duration of a theora video 
> when libtheora support is compiled in (especially when running in "-identify 
> mode").

After Diego's comment I had a closer look, and I think this just can't
work like this, e.g. seeking should as well still be broken.
I think you must instead fix the place where ogg_d->final_granulepos is
assigned.
In addition I really think such a patch better should create a new
function instead of duplicating the code that is already around line
293, where pack->granulepos and pts is calculated.
Though something seems quite wrong, since as far as I can tell
demux_ogg_read_packet already fixes the granulepos and supposedly it is
that fixed one that is assigned to final_granulepos...



More information about the MPlayer-dev-eng mailing list