[FFmpeg-devel] [PATCH][RFC] Lagarith Decoder.

Reimar Döffinger Reimar.Doeffinger
Thu Sep 17 17:24:36 CEST 2009


On Thu, Sep 17, 2009 at 02:46:07AM -0600, Nathan Caldwell wrote:
> 2009/9/5 Loren Merritt <lorenm at u.washington.edu>:
> > On Tue, 1 Sep 2009, Nathan Caldwell wrote:
> >
> >> Here are the latest lagarith patches.
> >
> > Your decoder disagrees with the official version on the 2nd frame of http://akuvian.org/stuff/lagarith_bork.avi
> 
> Finally got a chance to look into this, and found the problem, but I'm
> not sure how to fix it.
> What happens is on this clip when the probabilities get scaled in
> lag_read_prob_header(), one of the values gets rounded up instead of
> rounding down like reference does. For the offending value reference
> gives 0x6ff while the code below gives 0x700.

Besides a "told you so" as to using floating point giving no end of
issues for lossless, the exact input values would be the minimum
necessary to help out.
Adding a volatile float or volatile double at the right place might
be all that is necessary to make it work (well as far as it can be
called "working" while using floating point).



More information about the ffmpeg-devel mailing list