From 721dc3da276ca8d50d3b934d82c7b4adc9ebdf39 Mon Sep 17 00:00:00 2001 From: Stefano D'Angelo Date: Tue, 4 Apr 2023 15:24:33 +0200 Subject: [PATCH] bw_src, removed useless casts --- include/bw_src.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/bw_src.h b/include/bw_src.h index 5df52c4..0397135 100644 --- a/include/bw_src.h +++ b/include/bw_src.h @@ -120,8 +120,8 @@ struct _bw_src_state { static inline void bw_src_init(bw_src_coeffs *BW_RESTRICT coeffs, float ratio) { coeffs->k = ratio >= 1.f ? 1.f / ratio : -1.f / ratio; // 4th-degree Butterworth with cutoff at ratio * Nyquist, using bilinear transform w/ prewarping - const float fc = bw_minf((float)(ratio >= 1.f ? 1.f / ratio : ratio), 0.9f); - const float T = bw_tanf_3(1.570796326794896f * (float)fc); + const float fc = bw_minf(ratio >= 1.f ? 1.f / ratio : ratio, 0.9f); + const float T = bw_tanf_3(1.570796326794896f * fc); const float T2 = T * T; const float k = 1.f / (T * (T * (T * (T + 2.613125929752753f) + 3.414213562373095f) + 2.613125929752753f) + 1.f); coeffs->b0 = k * T2 * T2;