mirror of
https://github.com/AlexandreRouma/SDRPlusPlus.git
synced 2026-04-19 14:52:43 +00:00
Fixed issues with new module system
This commit is contained in:
47
core/src/signal_path/vfo_manager.h
Normal file
47
core/src/signal_path/vfo_manager.h
Normal file
@@ -0,0 +1,47 @@
|
||||
#pragma once
|
||||
#include <dsp/vfo.h>
|
||||
#include <gui/waterfall.h>
|
||||
#include <gui/gui.h>
|
||||
|
||||
class VFOManager {
|
||||
public:
|
||||
VFOManager();
|
||||
|
||||
class VFO {
|
||||
public:
|
||||
VFO(std::string name, int reference, float offset, float bandwidth, float sampleRate, int blockSize);
|
||||
~VFO();
|
||||
|
||||
void setOffset(float offset);
|
||||
void setCenterOffset(float offset);
|
||||
void setBandwidth(float bandwidth);
|
||||
void setSampleRate(float sampleRate, float bandwidth);
|
||||
void setReference(int ref);
|
||||
int getOutputBlockSize();
|
||||
|
||||
dsp::stream<dsp::complex_t>* output;
|
||||
|
||||
friend class VFOManager;
|
||||
|
||||
private:
|
||||
std::string name;
|
||||
dsp::VFO* dspVFO;
|
||||
ImGui::WaterfallVFO* wtfVFO;
|
||||
|
||||
};
|
||||
|
||||
VFOManager::VFO* createVFO(std::string name, int reference, float offset, float bandwidth, float sampleRate, int blockSize);
|
||||
void deleteVFO(VFOManager::VFO* vfo);
|
||||
|
||||
void setOffset(std::string name, float offset);
|
||||
void setCenterOffset(std::string name, float offset);
|
||||
void setBandwidth(std::string name, float bandwidth);
|
||||
void setSampleRate(std::string name, float sampleRate, float bandwidth);
|
||||
void setReference(std::string name, int ref);
|
||||
int getOutputBlockSize(std::string name);
|
||||
|
||||
void updateFromWaterfall(ImGui::WaterFall* wtf);
|
||||
|
||||
private:
|
||||
std::map<std::string, VFO*> vfos;
|
||||
};
|
||||
Reference in New Issue
Block a user