[FFmpeg-devel] [PATCH] scale msadpcm table to fit in int8_t

Mike Melanson mike
Sat Jul 12 04:29:33 CEST 2008


Michael Niedermayer wrote:
> On Fri, Jul 11, 2008 at 06:14:44PM -0700, Mike Melanson wrote:
>> Reimar D?ffinger wrote:
>>> Hello,
>>> this implements the same change I did to the MPlayer decoder.
>>> Saves only a few bytes though and would probably be slower on an 8-bit
>>> CPU without good shift support (e.g. Atmel AVR) if someone cares...
>> I guess ADPCM algorithms are not specified to be bit exact? This changes 
>> the output from before. But as long as it sounds right, I can update the 
>> relevant FATE tests. However, you will be responsible for updating the 
>> regression tests (which are presently broken due to this change).
> 
> hmmmmmmmmmm
> i thought it was a bitexact optim just reducing the table sizes
> has reimar maybe missed some use of the tables? :)

Perhaps this:

-static const int AdaptCoeff2[] = {
-        0, -256, 0, 64, 0, -208, -232
+static const int8_t AdaptCoeff2[] = {
+        0, -64, 0, 16, 0, -52, -58

Maybe there are rounding implications due to the negative numbers?

-- 
	-Mike Melanson




More information about the ffmpeg-devel mailing list