I have a pre-recorded sound effect (FX) that will be played every 5 seconds. Together with that, I also play a music track for a few minutes. The result is recorded.

Now, I want to remove the sound FX from the recorded result.

My research shows that it would involve using a filter with the noise profile (obtained using FFT) of the sound FX.

My questions:

  • The FFT will give me the frequencies and their amplitudes over a given time span (say 2 seconds). How do I apply the filter? Should I apply the filter continuously?
  • Which filter should I use? A band-pass filter?
  • Should I check for the presence of the noise before applying the filter? If I know the exact timing of the sound FX, should I just apply filtering for that moment?


PS: I'm using AudioKit.


1 Answer 1


Is the sound effect added on top of other audio digitally with no processing afterwards? If so, you could just find the time reference (cross correlation) and subtract it.

  • $\begingroup$ No, the sound FX is played on iPhone, while the music is played somewhere else. Both are recorded by the iPhone. Playing and recording happen at the same time. $\endgroup$
    – dz902
    Commented Apr 28 at 7:14
  • 1
    $\begingroup$ Ok. If the loudspeaker etc is reasonably linear and time invariant, then perhaps you can use an adaptive filter (an acoustic echo canceller) $\endgroup$
    – Knut Inge
    Commented Apr 28 at 7:38
  • $\begingroup$ Thanks, I'll take a look at the filter. $\endgroup$
    – dz902
    Commented Apr 28 at 14:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.