Update _kiss_fft_guts.h

Fix for DIVSCALAR off by 1 (#83)
This commit is contained in:
fbarchard 2022-09-19 14:07:04 -07:00 committed by GitHub
parent 8f47a67f59
commit 47e321b195
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -71,7 +71,7 @@ struct kiss_fft_state{
(m).i = sround( smul((a).r,(b).i) + smul((a).i,(b).r) ); }while(0)
# define DIVSCALAR(x,k) \
(x) = sround( smul( x, SAMP_MAX/k ) )
(x) = sround( smul( x, (SAMPPROD)(1u<<FRACBITS)/k ) )
# define C_FIXDIV(c,div) \
do { DIVSCALAR( (c).r , div); \