1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-26 17:58:43 -05:00

Channel analyzer NG: created settings - correction

This commit is contained in:
f4exb 2018-05-19 05:10:17 +02:00
parent 3e5bcf7e00
commit d6f5de1ad7

View File

@ -372,16 +372,13 @@ void ChannelAnalyzerNG::applySettings(const ChannelAnalyzerNGSettings& settings,
if ((settings.m_downSample != m_settings.m_downSample) || force)
{
int sampleRate = settings.m_downSample ? settings.m_downSampleRate : m_inputSampleRate;
m_settingsMutex.lock();
m_useInterpolator = settings.m_downSample;
if (settings.m_downSample)
{
setFilters(settings.m_downSampleRate, settings.m_bandwidth, settings.m_lowCutoff);
m_pll.setSampleRate(settings.m_downSampleRate / (1<<settings.m_spanLog2));
m_fll.setSampleRate(settings.m_downSampleRate / (1<<settings.m_spanLog2));
}
setFilters(sampleRate, settings.m_bandwidth, settings.m_lowCutoff);
m_pll.setSampleRate(sampleRate / (1<<settings.m_spanLog2));
m_fll.setSampleRate(sampleRate / (1<<settings.m_spanLog2));
m_settingsMutex.unlock();
}