[FFmpeg-devel] [PATCH] Make VP3/Theora Decoder Much Faster

Loren Merritt lorenm
Sun Dec 6 14:19:56 CET 2009


On Sun, 6 Dec 2009, Jason Garrett-Glaser wrote:

> Attached is a vague prototype for something I didn't mention
> earlier--a DC-only iDCT, the same type of thing I wrote for WMV a
> while back.  I don't have time to finish it right now, so I've
> attached a probably non-working but Basic Idea for it.  It would need
> asm code too, which would probably be easy enough (just blatantly copy
> the h264 ones and replace the C code for calculation of the DC value).

>+ if (num_coefs == 1 && block[0])
>+     s->dsp.idct_dc_put( output_plane + s->all_fragments[i].first_pixel, stride, block);
>+ else
>+     s->dsp.idct_put( output_plane + s->all_fragments[i].first_pixel, stride, block);

H264 does it this way because it has to keep track of num_coefs 
anyway. But you're creating this variable, so you can check 
index_of_highest_nonzero_coef == 0 instead.

--Loren Merritt



More information about the ffmpeg-devel mailing list