2

I'm trying to use apple's Accelerate Framework to setup FFT, windowing, overlapping and downsampling with input taken from the device's microphone. I've been looking all over for some sample code/application on how to use it, but I didn't quite figure out how to implement something like this in an actual project. Could you help point me in the right direction? Thanks

UPDATE

Here is the code I've managed to put together so far from various sources, including some other questions answered here. What it's missing is a downsampling function and the overlapping. In Apple's documentation, I found the following function vDSP_zrdesamp for desampling but i'm having trouble implementing it.

The real problem is trying to put this in an actual project. I've tried modifying this github project but I didn't manage to fit it in, so any help would be more than welcome. The actual FFT (which I need to modify) takes places in the RIOInterface class, in the audio callback function.

Please note that the project I mention on github does not belong to me, but it does not have a licence that forbids me to modify it for my own purposes. Also, this project is for testing only until I reach a more stable algorithm.

Community
  • 1
  • 1
Andrei Filip
  • 1,145
  • 15
  • 33
  • 4
    From SO's about page "Don't ask questions you haven't tried to find an answer for (show your work!)" Where have you looked? What have you tried? – Bjorn Roche Sep 23 '13 at 02:08
  • 2
    Apple's aurioTouch sample app shows how to do almost exactly this. You may have to replace the app's FFT with a very similar one from the Accelerate framework. – hotpaw2 Sep 23 '13 at 02:33
  • You already have the code you posted in [your previous question](http://stackoverflow.com/questions/18931905/using-apples-accelerate-framework-fft-hann-windowing-and-overlapping) - what problem are you having in actually using this ? – Paul R Sep 23 '13 at 07:31
  • @BjornRoche I've tried finding an answer to this. please see updated question, where i post my put-together code and how i try implementing it. – Andrei Filip Sep 23 '13 at 12:20
  • @hotpaw2 auriotouch sample app is no longer available. Perhaps you are refering to AurioTouch2 sample app, which already uses the Accelerate framework, but it's way to complicated for me. I've tried using it in a better explained project as you can see in my updated question, but i didn't manage to do it properly. – Andrei Filip Sep 23 '13 at 12:22
  • @PaulR I'm actually having trouble implementing that code and a few other things, like the overlapping method and the downsampling function in the sample project i've updated the question with. – Andrei Filip Sep 23 '13 at 12:23
  • 2
    So why not take the advice from the earlier question and get a basic version working with no overlap and no downsampling - that will deal with most of the learning curve problems - once you have that working you can the move on to implementing overlap and downsampling etc. Trying to do everything at once when you have no prior experience is a recipe for disaster. – Paul R Sep 23 '13 at 13:05
  • Just trying to speed up the process. – Andrei Filip Oct 07 '13 at 12:40
  • Just in case you didn't find them, here you have a couple of resources you may find useful.- http://pkmital.com/home/2011/04/14/real-fftifft-with-the-accelerate-framework/ http://gerrybeauregard.wordpress.com/2013/01/28/using-apples-vdspaccelerate-fft/ http://stackoverflow.com/questions/3398753/using-the-apple-fft-and-accelerate-framework http://stackoverflow.com/questions/1964955/audio-file-fft-in-an-os-x-environment Hope it helps. – ssantos Oct 02 '13 at 07:54

0 Answers0