From c4733a364508f3af3fbbab25f140aae478b1f7bb Mon Sep 17 00:00:00 2001 From: srcejon Date: Tue, 12 Nov 2024 20:36:10 +0000 Subject: [PATCH] DemodAnalyzer: Ensure sample rate is set in worker. Fixes #2309. --- plugins/feature/demodanalyzer/demodanalyzer.cpp | 1 + plugins/feature/demodanalyzer/demodanalyzerworker.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/plugins/feature/demodanalyzer/demodanalyzer.cpp b/plugins/feature/demodanalyzer/demodanalyzer.cpp index bcc183f80..5e9bf95b3 100644 --- a/plugins/feature/demodanalyzer/demodanalyzer.cpp +++ b/plugins/feature/demodanalyzer/demodanalyzer.cpp @@ -131,6 +131,7 @@ void DemodAnalyzer::start() DemodAnalyzerWorker::MsgConfigureDemodAnalyzerWorker *msg = DemodAnalyzerWorker::MsgConfigureDemodAnalyzerWorker::create(m_settings, QList(), true); m_worker->getInputMessageQueue()->push(msg); + m_worker->applySampleRate(m_sampleRate); if (m_dataPipe) { diff --git a/plugins/feature/demodanalyzer/demodanalyzerworker.cpp b/plugins/feature/demodanalyzer/demodanalyzerworker.cpp index fdf29cfa4..cd57840e6 100644 --- a/plugins/feature/demodanalyzer/demodanalyzerworker.cpp +++ b/plugins/feature/demodanalyzer/demodanalyzerworker.cpp @@ -29,6 +29,7 @@ MESSAGE_CLASS_DEFINITION(DemodAnalyzerWorker::MsgConnectFifo, Message) DemodAnalyzerWorker::DemodAnalyzerWorker() : m_dataFifo(nullptr), + m_sinkSampleRate(0), m_msgQueueToFeature(nullptr), m_sampleBufferSize(0), m_wavFileRecord(nullptr),