- This project just deals with DFT and Block Convoltuion using Two Overlap Methods in DSP
- Implement using C++11
- FFT uses the kiss_fft library
- Use Low-pass Filter
- it was tested on the Window 10, Visual Studio 15
- Download Project
git clone https://github.com/fbdp1202/DSP_Overlap-Save_Overlap_Add.git
-
Open Visual Studio Project "DSP_Overlap-Save_Overlap_Add.sln"
-
Just Build and Run
- Read and Write wav file
- WAV spectrogram
// main.cpp
std::string fileName = "sa1.wav";
const int N = 1024;
const int M = 512;
Block_conv* tests[4];
std::string strOverlapAdd = "overlap_add";
std::string strOverlapSave = "overlap_save";
std::string strFFT = "fft";
std::string stdDFT = "dft";
tests[0] = new Block_conv(fileName, strOverlapAdd, strFFT, N, M);
tests[1] = new Block_conv(fileName, strOverlapAdd, stdDFT, N, M);
tests[2] = new Block_conv(fileName, strOverlapSave, strFFT, N, M);
tests[3] = new Block_conv(fileName, strOverlapSave, stdDFT, N, M);
-
fileName : Choose Wav File (only Single Channel and 16bit Sample Length)
-
N : number of DFT
-
M : length of Low-Filter
-
Func@Block_conv( std::string input wav file Name,
std::string method // Choose method "overlap_add" or "overlap_save"
std::string ) mode // Choose mode "fft" or "dft"