# HG changeset patch # User Chris Cannam # Date 1541591244 0 # Node ID 36b4872e894a94b54dad3ad2eb48dedb41450eb3 # Parent f6e7d0e783e8a1021fa7fec8fa7bfd6b70c753b9 Properly align window with signal, in oversampled case diff -r f6e7d0e783e8 -r 36b4872e894a data/model/FFTModel.cpp --- a/data/model/FFTModel.cpp Tue Nov 06 11:12:58 2018 +0000 +++ b/data/model/FFTModel.cpp Wed Nov 07 11:47:24 2018 +0000 @@ -330,7 +330,7 @@ Profiler profiler("FFTModel::getFFTColumn (cache miss)"); auto samples = getSourceSamples(n); - m_windower.cut(samples.data()); + m_windower.cut(samples.data() + (m_fftSize - m_windowSize) / 2); breakfastquay::v_fftshift(samples.data(), m_fftSize); cvec &col = m_cached[m_cacheWriteIndex].col;