|
From: Martin G. <mar...@gm...> - 2025-11-29 13:37:51
|
Thanks, that's all clear now. > OK as long as buffer size is less than 1522 seconds @ 44100Hz sample rate I think we can guarantee that! > // just define FFTPACK_DOUBLE_PRECISION Good. SoX's internal "fft4g" routine has the same thing: #ifdef FFT4G_FLOAT #define double float #define sin sinf #define cos cosf #define atan atanf #define cdft lsx_cdft_f #define rdft lsx_rdft_f ... which means some jiggery pokery to compile it twice into different object files to get both versions (something I was already contemplating for fft4g) and that means including the pffft source in SoX' source tree to be able to do this, something that would be necessary anyway as it's not included in many distros, only ArchLinux, MacPorts and FreeBSD Ports. https://repology.org/project/pffft/versions Thanks for your exhaustive analysis of the necessary precision in DFTs. I will be careful with them. M |