[FFmpeg-devel] [PATCH] Optionally hardcode PCM tables

Vitor Sessak vitor1001
Fri Jan 11 20:12:16 CET 2008


Diego 'Flameeyes' Petten? wrote:
> I've already tried to send a patch (depending on the previous one which
> allows the PCM tables to be shared), that optionally hardcodes the pcm
> tables, but it was a liittle too big, so this time I'm linking it ;)
> http://flameeyes.is-a-geek.org/patches/ffmpeg/libavcodec-hardcode-pcm-tables.patch
> I also have updated it for the new patch (renamed and moved [au]law to
> liner tables).
> The size of libavcodec increases by about 33KiB, but also saves 32KiB of
> memory per process whenever the PCM decoder is used, which is not an
> ignorable amount.

I've found a cosmetical change:

>          if (!ulaw_to_linear[255])
> -  	    for(i=0;i<256;i++)
> +            for(i=0;i<256;i++)
>                  ulaw_to_linear[i] = ulaw2linear(i);
> +#endif

Also, you forgot to attach your patch in the thread "[PATCH] 
(Non-optionally) hardcode qexp table in	snow.c".


More information about the ffmpeg-devel mailing list