You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
g723.1: replace loop of normalize_bits( by av_log2()
idea by vitor Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -216,8 +216,8 @@ static int normalize_bits(int num, int width)
|
|||||||
return bits;
|
return bits;
|
||||||
if (num < 0)
|
if (num < 0)
|
||||||
num = ~num;
|
num = ~num;
|
||||||
for (i = 0; num < limit; i++)
|
i= bits - av_log2(num) - 1;
|
||||||
num <<= 1;
|
i= FFMAX(i, 0);
|
||||||
}
|
}
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user