[MPlayer-dev-eng] [PATCH] vf_eq2 extensions

D Richard Felker III dalias at aerifal.cx
Fri Jan 31 19:32:10 CET 2003


On Fri, Jan 31, 2003 at 06:17:20PM +0100, Michael Niedermayer wrote:
> Hi
> 
> On Friday 31 January 2003 17:20, D Richard Felker III wrote:
> [...]
> > > I am reluctant to put this stuff in vf_eq.c because the main
> > > function that I need (the main reason for vf_eq2 to exist) is
> > > gamma correction and that's the one thing that can't be done
> > > efficiently in vf_eq.c.
> >
> > Hmm, someone should add polynomial approx gamma correction to eq then
> > so we can just make eq2 obsolete.
> i doubt that evaluating a polynom is faster than a single L1 cache read from a 
> 256 byte LUT

Nope, it's not. But with MMX, evaluating 4 polynomials is just as fast
as evaluating one. :) And loading a single byte from memory, then
immediately using it as a 32bit offset into a lookup table, is VERY
SLOW. x86 cpu's don't like mixing register sizes these days. I spent a
lot of time trying to improve performance on stuff just like this in
another program, and I never could get it to work as fast as I wanted.

BTW, as a reference, eq2 uses well over twice the cpu time of eq on my
system, last I checked.

Rich




More information about the MPlayer-dev-eng mailing list