mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-06 03:18:13 +00:00
gen_audio_resampler_filter: Use SDL_PI_F
This commit is contained in:
@@ -84,7 +84,7 @@ kaiser_and_sinc(float *table, float *diffs, const int tablelen, const double bet
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (i = 1; i < tablelen; i++) {
|
for (i = 1; i < tablelen; i++) {
|
||||||
const float x = (((float) i) / ((float) RESAMPLER_SAMPLES_PER_ZERO_CROSSING)) * ((float) M_PI);
|
const float x = (((float) i) / ((float) RESAMPLER_SAMPLES_PER_ZERO_CROSSING)) * SDL_PI_F;
|
||||||
table[i] *= sinf(x) / x;
|
table[i] *= sinf(x) / x;
|
||||||
diffs[i - 1] = table[i] - table[i - 1];
|
diffs[i - 1] = table[i] - table[i - 1];
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user