mirror of
https://github.com/cjcliffe/CubicSDR.git
synced 2026-07-25 03:24:20 -04:00
Merge pull request #124 from cjcliffe/ui_visuals_to_panels
Ui visuals to panels
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#include "DemodulatorInstance.h"
|
||||
|
||||
DemodulatorInstance::DemodulatorInstance() :
|
||||
pipeIQInputData(NULL), demodulatorThread(NULL), t_PreDemod(NULL), t_Demod(NULL), t_Audio(NULL), currentAudioGain(1.0) {
|
||||
t_PreDemod(NULL), t_Demod(NULL), t_Audio(NULL) {
|
||||
|
||||
terminated.store(true);
|
||||
audioTerminated.store(true);
|
||||
@@ -16,7 +16,7 @@ DemodulatorInstance::DemodulatorInstance() :
|
||||
currentFrequency.store(0);
|
||||
currentBandwidth.store(0);
|
||||
currentOutputDevice.store(-1);
|
||||
|
||||
currentAudioGain.store(1.0);
|
||||
|
||||
label = new std::string("Unnamed");
|
||||
pipeIQInputData = new DemodulatorThreadInputQueue;
|
||||
@@ -30,17 +30,17 @@ DemodulatorInstance::DemodulatorInstance() :
|
||||
demodulatorPreThread->setOutputQueue("NotifyQueue",pipeDemodNotify);
|
||||
demodulatorPreThread->setInputQueue("CommandQueue",pipeDemodCommand);
|
||||
|
||||
audioInputQueue = new AudioThreadInputQueue;
|
||||
pipeAudioData = new AudioThreadInputQueue;
|
||||
threadQueueControl = new DemodulatorThreadControlCommandQueue;
|
||||
|
||||
demodulatorThread = new DemodulatorThread();
|
||||
demodulatorThread->setInputQueue("IQDataInput",pipeIQDemodData);
|
||||
demodulatorThread->setInputQueue("ControlQueue",threadQueueControl);
|
||||
demodulatorThread->setOutputQueue("NotifyQueue",pipeDemodNotify);
|
||||
demodulatorThread->setOutputQueue("AudioDataOutput", audioInputQueue);
|
||||
demodulatorThread->setOutputQueue("AudioDataOutput", pipeAudioData);
|
||||
|
||||
audioThread = new AudioThread();
|
||||
audioThread->setInputQueue("AudioDataInput", audioInputQueue);
|
||||
audioThread->setInputQueue("AudioDataInput", pipeAudioData);
|
||||
audioThread->setOutputQueue("NotifyQueue", pipeDemodNotify);
|
||||
|
||||
currentDemodType = demodulatorThread->getDemodulatorType();
|
||||
@@ -56,7 +56,7 @@ DemodulatorInstance::~DemodulatorInstance() {
|
||||
delete pipeDemodCommand;
|
||||
delete pipeDemodNotify;
|
||||
delete threadQueueControl;
|
||||
delete audioInputQueue;
|
||||
delete pipeAudioData;
|
||||
}
|
||||
|
||||
void DemodulatorInstance::setVisualOutputQueue(DemodulatorThreadOutputQueue *tQueue) {
|
||||
|
||||
@@ -18,7 +18,6 @@ public:
|
||||
std::thread *t_Demod;
|
||||
#endif
|
||||
|
||||
AudioThreadInputQueue *audioInputQueue;
|
||||
AudioThread *audioThread;
|
||||
std::thread *t_Audio;
|
||||
|
||||
@@ -86,6 +85,7 @@ public:
|
||||
protected:
|
||||
DemodulatorThreadInputQueue* pipeIQInputData;
|
||||
DemodulatorThreadPostInputQueue* pipeIQDemodData;
|
||||
AudioThreadInputQueue *pipeAudioData;
|
||||
DemodulatorThreadCommandQueue* pipeDemodCommand;
|
||||
DemodulatorThreadCommandQueue* pipeDemodNotify;
|
||||
DemodulatorPreThread *demodulatorPreThread;
|
||||
|
||||
@@ -266,7 +266,6 @@ void DemodulatorThread::run() {
|
||||
} else if (demodulatorType == DEMOD_TYPE_RAW) {
|
||||
// do nothing here..
|
||||
} else {
|
||||
float p;
|
||||
switch (demodulatorType.load()) {
|
||||
case DEMOD_TYPE_LSB:
|
||||
currentDemodLock = false;
|
||||
|
||||
Reference in New Issue
Block a user