Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Where is well described FFT divisor 5 ? (Read 4023 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Where is well described FFT divisor 5 ?

It is known that FFT not must works only on 2^n values, but also for 2^a*3^b*5^c. For example in FAAD sources are functions: passf2pos,passf3,passf4pos,passf5. In Opus are kf_bfly3,kf_bfly5 etc. FAAD sources of MDCT are more clear than Opus and I want use it, but FAAD uses only 2^n frame length. I check that divisor 3 is also good (libfaad issue 2) but divisor 5 is bad. Where is described algorithm for this, for example in PDF file? Opus's kf_bfly5 is shorter and differs than FAAD's passf5 function. Function passf5 is long and complicated.


Where is well described FFT divisor 5 ?

Reply #2
It is known that FFT not must works only on 2^n values, but also for 2^a*3^b*5^c.


The discrete fourier transform works for any number of values, not just ones of those forms.  Individual FFTs can work on whatever range of inputs the author wants.  Since almost all audio formats use power of two transforms, those are the ones you'll see in most codecs.

For example in FAAD sources are functions: passf2pos,passf3,passf4pos,passf5. In Opus are kf_bfly3,kf_bfly5 etc. FAAD sources of MDCT are more clear than Opus and I want use it, but FAAD uses only 2^n frame length. I check that divisor 3 is also good (libfaad issue 2) but divisor 5 is bad. Where is described algorithm for this, for example in PDF file? Opus's kf_bfly5 is shorter and differs than FAAD's passf5 function. Function passf5 is long and complicated.


AAC (ignoring some obscure variants that are rarely if ever used) has a power of 2 transform length.  Rather then trying to add support for whatever size you're using, I would just grab a version of the MDCT that supports the sizes you need. 

That and the libfaad MDCT is painfully slow.