How to stream samples to IControl for FFT analysis

Hi everyone,
I’m in more and more need of an FFT analyzer and I’ve been having a bit of trouble streaming the output values of my ProcessBlock function. I’m obviously using the OnMsgFromDelegate function on the IControl end, but I’m unsure of a few things:

  • What sender class (ISender, etc) do I use to send entire blocks to the IControl?
  • What do I need to do in the OnMsgFromDelegate function to extract all of the values? I looked over the IControls and couldn’t find any example of this. Once I can get all of the values from ProcessBlock, I can feed them into a circular buffer and then feed that into an arbitrary FFT.

And while I’m on the subject, would WDL_FFT do the job? I’m probably going to be doing FFT on 44100 samples ever second or so. Thanks in advance.

-Sean

You probably need to write your only sender class - that is what I have done for FFT analysis. The ideal from my perspective is to do the FFT in the control after getting the block, as then you don’t suffer the FFT cost in the audio thread.

I think I copied the whole block in order to send it - that’s not super ideal, but it makes various things easier, and the copy shouldn’t take that long.

I have used the WDL FFT with up to 250,000 samples (in stereo, so double that) and it works really fast.