]> git.sesse.net Git - ffmpeg/commit
avcodec/atrac3plus: Run-length encode length tables to make them smaller
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Sun, 1 Nov 2020 22:19:18 +0000 (23:19 +0100)
committerAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Tue, 8 Dec 2020 16:51:46 +0000 (17:51 +0100)
commit58fc810d42fde26ed6c1f2996122e98ab7005849
treedde8b38c8528eef903cd46993cbddca4e69cca55
parenta7dbeb77c3c30ac4904928978938b209ff6e1ab1
avcodec/atrac3plus: Run-length encode length tables to make them smaller

This is very beneficial for the scale factor tables where 4*64+4*15
bytes of length information can be replaced by eight codebooks of 12
bytes each; furthermore the number of codes as well as the maximum
length of a code can be easily derived from said codebooks, making
tables containing said information superfluous. This and combining the
symbols into one big array also made an array of pointers to the tables
redundant.

For the wordlen and code table tables the benefits are not that big
(given these tables don't contain that many elements), but all in all
using codebooks is also advantageouos for them. Therefore it has been
done.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
libavcodec/atrac3plus.c
libavcodec/atrac3plus_data.h