Feature Request #378

FFT Lib Design

Added by Tim Place about 2 years ago. Updated over 1 year ago.

Status:New Start date:2010-01-24
Priority:High Due date:
Assignee:Tim Place % Done:

0%

Category:- Spent time: -
Target version:-
Branch:fft

Description

(There is an FFT branch in Git for an FFT Lib extension already)

We should schedule a day where several of us can work on this. Some of the questions we should try to answer:

  • How do we control FFT size? Is it simply the vector size of the audio passed in? Or should it be fixed, and then we have to buffer the audio that comes in? If the former, then I guess we should create an object the buffers audio to provide the possibility of changing vector sizes?
  • How do we control the offset of an FFT? For example, in Max's fft~ object there is a third argument for this. However, why should we do this in the FFT? isn't it something we could control outside of the FFT? How?
  • For what is the second argument in Max's object useful? Do we need something like this?
  • I (tim) am assuming that windowing, overlapping, and adding, all happens outside of the fft object.
  • Are the FFT and IFFT objects the same object? Or are the different objects?
  • In Max, a sync outlet provides the fft bin number. If we simply process a the FFT based on the size of the audio signal passed in then we don't have to worry about this because we will be receiving and sending complete frames of the FFT rather than sending them piece-meal.

Related issues

related to DSP - Bug #640: jcom.fft~ is a stub Closed 2010-11-28

History

Updated by Tim Place about 2 years ago

Another thought: we don't really care about using this object in MSP, because there are alreadt FFT facilities in MSP.

We do care about using this in Multicore -- so if we are thinking about how to target our requirements, I think that should be our target.

Updated by Nils Peters about 2 years ago

maybe these tutorials might be handy: http://www.dspdimension.com/tutorials/

Updated by Nils Peters about 2 years ago

Oli Larkin made an autotune external for MSP, including the source code.
Seems he is using Miller Puckettes fft and ifft algorithms....

http://olilarkin.blogspot.com/2010/01/autotalent-msp-port.html

Updated by Nils Peters almost 2 years ago

http://cr.yp.to/djbfft.html

djbfft is an extremely fast library for floating-point convolution. The current version holds most of the speed records for double-precision FFTs on general-purpose computers.

FAQ: Can I use djbfft in my own code?

Yes. Please tell me what programs you're using it in so that I can let NSF know.

Updated by Nils Peters over 1 year ago

another BSD-licensed, easy-going FFT-lib: http://kissfft.sourceforge.net/

Updated by Trond Lossius over 1 year ago

My impression is that kissfft is actually one of the best, and actually far better performance-wise than ffnw. I don't have the link on hand, but I saw a test that indicated that FFTW results were pitched to turn out in their favour, and other libraries performing comparably or better in a number of real-world situations.

Updated by Nils Peters over 1 year ago

I second Trond. We should go with kissfft, because it's fast and their BSD-license is ideal for us now.

Also available in: Atom PDF