mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-26 01:02:33 +00:00
avcodec/mpegaudio_tablegen: fix build with hardcoded tables
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
fbdc98c758
commit
2f31b73a11
@ -63,7 +63,7 @@ static void mpegaudio_tableinit(void)
|
||||
/* cbrtf() isn't available on all systems, so we use powf(). */
|
||||
double f = (double)value * pow(value, 1.0 / 3.0) * pow(2, (exponent - 400) * 0.25 + FRAC_BITS + 5) / IMDCT_SCALAR;
|
||||
/* llrint() isn't always available, so round and cast manually. */
|
||||
expval_table_fixed[exponent][value] = (long long int) FFMIN(floor(f + 0.5), 0xFFFFFFFF);
|
||||
expval_table_fixed[exponent][value] = (long long int) (f < 0xFFFFFFFF ? floor(f + 0.5) : 0xFFFFFFFF);
|
||||
expval_table_float[exponent][value] = f;
|
||||
}
|
||||
exp_table_fixed[exponent] = expval_table_fixed[exponent][1];
|
||||
|
Loading…
Reference in New Issue
Block a user