Smoothing audio output of filters applied frame by frame

2 vues (au cours des 30 derniers jours)
Ayrton Urviola
Ayrton Urviola le 13 Nov 2020
Commenté : Mathieu NOE le 20 Déc 2020
Hello everyone,
I have a bank of N FIR filters. I want to use ach one of them to filter a each of the N frames of an audio signal. My code is something like this:
for i = 1:N
audioFrame = audioSignal(1 + (I - 1)*frameLength:I*frameLength);
audioOutFrame(:, I) = fftfilt(filterBank(:, I), audioFrame);
end
audioOut = audioOutFrame(:);
In the end, both audioOut and audioSignal are column vectors of the same length (N*frameLength). The problem is that when I playback audioOut (using the sound function, for example), it sounds... "glitchy" (there is a periodic pulsating-like noise).
When I zoomed to look what whats happening with audioOut, I found that the transition of the frames was "too rough".
If anyone coud guide me on how to fix this problem. I would gladly appreciate it. Thanks in advance.
  1 commentaire
Mathieu NOE
Mathieu NOE le 20 Déc 2020
hello
I wonder if using filter instead of fftfilt would reduce the transients at start / end of buffers
second, if the problem persists, why not doing a kind of moving average of a few samples where end of previous buffer joins the start of the next buffer
attached a moving average window filter code

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Audio I/O and Waveform Generation dans Help Center et File Exchange

Produits


Version

R2019b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by