kopia lustrzana https://github.com/f4exb/sdrangel
Modulators: changed single Tx channel samples feed handling. Pure virtual function is useless
rodzic
1afd8df5f9
commit
f74e3b83a7
|
@ -136,19 +136,6 @@ void AMMod::pull(Sample& sample)
|
|||
sample.m_imag = (FixReal) ci.imag();
|
||||
}
|
||||
|
||||
void AMMod::feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples)
|
||||
{
|
||||
SampleVector::iterator writeAt;
|
||||
sampleFifo->getWriteIterator(writeAt);
|
||||
|
||||
for (int i = 0; i < nbSamples; i++)
|
||||
{
|
||||
pull((*writeAt));
|
||||
sampleFifo->bumpIndex(writeAt);
|
||||
}
|
||||
}
|
||||
|
||||
void AMMod::modulateSample()
|
||||
{
|
||||
Real t;
|
||||
|
|
|
@ -185,11 +185,6 @@ public:
|
|||
bool playLoop);
|
||||
|
||||
virtual void pull(Sample& sample);
|
||||
|
||||
/** direct feeding of sample source FIFO */
|
||||
virtual void feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples);
|
||||
|
||||
virtual void start();
|
||||
virtual void stop();
|
||||
virtual bool handleMessage(const Message& cmd);
|
||||
|
|
|
@ -151,19 +151,6 @@ void NFMMod::pull(Sample& sample)
|
|||
sample.m_imag = (FixReal) ci.imag();
|
||||
}
|
||||
|
||||
void NFMMod::feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples)
|
||||
{
|
||||
SampleVector::iterator writeAt;
|
||||
sampleFifo->getWriteIterator(writeAt);
|
||||
|
||||
for (int i = 0; i < nbSamples; i++)
|
||||
{
|
||||
pull((*writeAt));
|
||||
sampleFifo->bumpIndex(writeAt);
|
||||
}
|
||||
}
|
||||
|
||||
void NFMMod::modulateSample()
|
||||
{
|
||||
Real t;
|
||||
|
|
|
@ -190,11 +190,6 @@ public:
|
|||
float ctcssFrequency);
|
||||
|
||||
virtual void pull(Sample& sample);
|
||||
|
||||
/** direct feeding of sample source FIFO */
|
||||
virtual void feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples);
|
||||
|
||||
virtual void start();
|
||||
virtual void stop();
|
||||
virtual bool handleMessage(const Message& cmd);
|
||||
|
|
|
@ -182,19 +182,6 @@ void SSBMod::pull(Sample& sample)
|
|||
sample.m_imag = (FixReal) ci.imag();
|
||||
}
|
||||
|
||||
void SSBMod::feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples)
|
||||
{
|
||||
SampleVector::iterator writeAt;
|
||||
sampleFifo->getWriteIterator(writeAt);
|
||||
|
||||
for (int i = 0; i < nbSamples; i++)
|
||||
{
|
||||
pull((*writeAt));
|
||||
sampleFifo->bumpIndex(writeAt);
|
||||
}
|
||||
}
|
||||
|
||||
void SSBMod::modulateSample()
|
||||
{
|
||||
pullAF(m_modSample);
|
||||
|
|
|
@ -190,11 +190,6 @@ public:
|
|||
bool playLoop);
|
||||
|
||||
virtual void pull(Sample& sample);
|
||||
|
||||
/** direct feeding of sample source FIFO */
|
||||
virtual void feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples);
|
||||
|
||||
virtual void start();
|
||||
virtual void stop();
|
||||
virtual bool handleMessage(const Message& cmd);
|
||||
|
|
|
@ -139,19 +139,6 @@ void WFMMod::pull(Sample& sample)
|
|||
sample.m_imag = (FixReal) ci.imag();
|
||||
}
|
||||
|
||||
void WFMMod::feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples)
|
||||
{
|
||||
SampleVector::iterator writeAt;
|
||||
sampleFifo->getWriteIterator(writeAt);
|
||||
|
||||
for (int i = 0; i < nbSamples; i++)
|
||||
{
|
||||
pull((*writeAt));
|
||||
sampleFifo->bumpIndex(writeAt);
|
||||
}
|
||||
}
|
||||
|
||||
void WFMMod::pullAF(Complex& sample)
|
||||
{
|
||||
int16_t audioSample[2];
|
||||
|
|
|
@ -187,11 +187,6 @@ public:
|
|||
bool playLoop);
|
||||
|
||||
virtual void pull(Sample& sample);
|
||||
|
||||
/** direct feeding of sample source FIFO */
|
||||
virtual void feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples);
|
||||
|
||||
virtual void start();
|
||||
virtual void stop();
|
||||
virtual bool handleMessage(const Message& cmd);
|
||||
|
|
|
@ -37,8 +37,17 @@ public:
|
|||
virtual void pull(Sample& sample) = 0;
|
||||
|
||||
/** direct feeding of sample source FIFO */
|
||||
virtual void feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples) = 0;
|
||||
void feed(SampleSourceFifo* sampleFifo, int nbSamples)
|
||||
{
|
||||
SampleVector::iterator writeAt;
|
||||
sampleFifo->getWriteIterator(writeAt);
|
||||
|
||||
for (int i = 0; i < nbSamples; i++)
|
||||
{
|
||||
pull((*writeAt));
|
||||
sampleFifo->bumpIndex(writeAt);
|
||||
}
|
||||
}
|
||||
|
||||
virtual bool handleMessage(const Message& cmd) = 0; //!< Processing of a message. Returns true if message has actually been processed
|
||||
|
||||
|
|
|
@ -102,19 +102,6 @@ void UpChannelizer::pull(Sample& sample)
|
|||
}
|
||||
}
|
||||
|
||||
void UpChannelizer::feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples)
|
||||
{
|
||||
SampleVector::iterator writeAt;
|
||||
sampleFifo->getWriteIterator(writeAt);
|
||||
|
||||
for (int i = 0; i < nbSamples; i++)
|
||||
{
|
||||
pull((*writeAt));
|
||||
sampleFifo->bumpIndex(writeAt);
|
||||
}
|
||||
}
|
||||
|
||||
void UpChannelizer::start()
|
||||
{
|
||||
if (m_sampleSource != 0)
|
||||
|
|
|
@ -64,10 +64,6 @@ public:
|
|||
virtual void stop();
|
||||
virtual void pull(Sample& sample);
|
||||
|
||||
/** direct feeding of sample source FIFO */
|
||||
virtual void feed(SampleSourceFifo* sampleFifo,
|
||||
int nbSamples);
|
||||
|
||||
virtual bool handleMessage(const Message& cmd);
|
||||
|
||||
protected:
|
||||
|
|
Ładowanie…
Reference in New Issue