mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-04 16:01:14 -05:00
Use always 16 bit DSP on Tx side
This commit is contained in:
parent
2ddcb8c358
commit
61a16eade9
@ -18,15 +18,11 @@
|
|||||||
#define INCLUDE_GPL_DSP_INTERPOLATORS_H_
|
#define INCLUDE_GPL_DSP_INTERPOLATORS_H_
|
||||||
|
|
||||||
#include "dsp/dsptypes.h"
|
#include "dsp/dsptypes.h"
|
||||||
#ifdef SDR_TX_SAMPLE_24BIT
|
|
||||||
#include "dsp/inthalfbandfilterdb.h"
|
|
||||||
#else
|
|
||||||
#ifdef USE_SSE4_1
|
#ifdef USE_SSE4_1
|
||||||
#include "dsp/inthalfbandfiltereo1.h"
|
#include "dsp/inthalfbandfiltereo1.h"
|
||||||
#else
|
#else
|
||||||
#include "dsp/inthalfbandfilterdb.h"
|
#include "dsp/inthalfbandfilterdb.h"
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
|
|
||||||
#define INTERPOLATORS_HB_FILTER_ORDER_FIRST 64
|
#define INTERPOLATORS_HB_FILTER_ORDER_FIRST 64
|
||||||
#define INTERPOLATORS_HB_FILTER_ORDER_SECOND 32
|
#define INTERPOLATORS_HB_FILTER_ORDER_SECOND 32
|
||||||
@ -118,14 +114,6 @@ public:
|
|||||||
void interpolate64_cen(SampleVector::iterator* it, T* buf, qint32 len);
|
void interpolate64_cen(SampleVector::iterator* it, T* buf, qint32 len);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
#ifdef SDR_TX_SAMPLE_24BIT
|
|
||||||
IntHalfbandFilterDB<qint64, INTERPOLATORS_HB_FILTER_ORDER_FIRST> m_interpolator2; // 1st stages
|
|
||||||
IntHalfbandFilterDB<qint64, INTERPOLATORS_HB_FILTER_ORDER_SECOND> m_interpolator4; // 2nd stages
|
|
||||||
IntHalfbandFilterDB<qint64, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator8; // 3rd stages
|
|
||||||
IntHalfbandFilterDB<qint64, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator16; // 4th stages
|
|
||||||
IntHalfbandFilterDB<qint64, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator32; // 5th stages
|
|
||||||
IntHalfbandFilterDB<qint64, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator64; // 6th stages
|
|
||||||
#else
|
|
||||||
#ifdef USE_SSE4_1
|
#ifdef USE_SSE4_1
|
||||||
IntHalfbandFilterEO1<INTERPOLATORS_HB_FILTER_ORDER_FIRST> m_interpolator2; // 1st stages
|
IntHalfbandFilterEO1<INTERPOLATORS_HB_FILTER_ORDER_FIRST> m_interpolator2; // 1st stages
|
||||||
IntHalfbandFilterEO1<INTERPOLATORS_HB_FILTER_ORDER_SECOND> m_interpolator4; // 2nd stages
|
IntHalfbandFilterEO1<INTERPOLATORS_HB_FILTER_ORDER_SECOND> m_interpolator4; // 2nd stages
|
||||||
@ -141,7 +129,6 @@ private:
|
|||||||
IntHalfbandFilterDB<qint32, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator32; // 5th stages
|
IntHalfbandFilterDB<qint32, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator32; // 5th stages
|
||||||
IntHalfbandFilterDB<qint32, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator64; // 6th stages
|
IntHalfbandFilterDB<qint32, INTERPOLATORS_HB_FILTER_ORDER_NEXT> m_interpolator64; // 6th stages
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
};
|
};
|
||||||
|
|
||||||
template<typename T, uint SdrBits, uint OutputBits>
|
template<typename T, uint SdrBits, uint OutputBits>
|
||||||
|
@ -207,26 +207,6 @@ void UpChannelizer::applyConfiguration()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef SDR_TX_SAMPLE_24BIT
|
|
||||||
UpChannelizer::FilterStage::FilterStage(Mode mode) :
|
|
||||||
m_filter(new IntHalfbandFilterDB<qint64, UPCHANNELIZER_HB_FILTER_ORDER>),
|
|
||||||
m_workFunction(0)
|
|
||||||
{
|
|
||||||
switch(mode) {
|
|
||||||
case ModeCenter:
|
|
||||||
m_workFunction = &IntHalfbandFilterDB<qint64, UPCHANNELIZER_HB_FILTER_ORDER>::workInterpolateCenter;
|
|
||||||
break;
|
|
||||||
|
|
||||||
case ModeLowerHalf:
|
|
||||||
m_workFunction = &IntHalfbandFilterDB<qint64, UPCHANNELIZER_HB_FILTER_ORDER>::workInterpolateLowerHalf;
|
|
||||||
break;
|
|
||||||
|
|
||||||
case ModeUpperHalf:
|
|
||||||
m_workFunction = &IntHalfbandFilterDB<qint64, UPCHANNELIZER_HB_FILTER_ORDER>::workInterpolateUpperHalf;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
#ifdef USE_SSE4_1
|
#ifdef USE_SSE4_1
|
||||||
UpChannelizer::FilterStage::FilterStage(Mode mode) :
|
UpChannelizer::FilterStage::FilterStage(Mode mode) :
|
||||||
m_filter(new IntHalfbandFilterEO1<UPCHANNELIZER_HB_FILTER_ORDER>),
|
m_filter(new IntHalfbandFilterEO1<UPCHANNELIZER_HB_FILTER_ORDER>),
|
||||||
@ -266,7 +246,6 @@ UpChannelizer::FilterStage::FilterStage(Mode mode) :
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
|
|
||||||
UpChannelizer::FilterStage::~FilterStage()
|
UpChannelizer::FilterStage::~FilterStage()
|
||||||
{
|
{
|
||||||
|
@ -23,15 +23,11 @@
|
|||||||
#include <QMutex>
|
#include <QMutex>
|
||||||
#include "util/export.h"
|
#include "util/export.h"
|
||||||
#include "util/message.h"
|
#include "util/message.h"
|
||||||
#ifdef SDR_TX_SAMPLE_24BIT
|
|
||||||
#include "dsp/inthalfbandfilterdb.h"
|
|
||||||
#else
|
|
||||||
#ifdef USE_SSE4_1
|
#ifdef USE_SSE4_1
|
||||||
#include "dsp/inthalfbandfiltereo1.h"
|
#include "dsp/inthalfbandfiltereo1.h"
|
||||||
#else
|
#else
|
||||||
#include "dsp/inthalfbandfilterdb.h"
|
#include "dsp/inthalfbandfilterdb.h"
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
|
|
||||||
#define UPCHANNELIZER_HB_FILTER_ORDER 96
|
#define UPCHANNELIZER_HB_FILTER_ORDER 96
|
||||||
|
|
||||||
@ -87,17 +83,12 @@ protected:
|
|||||||
ModeUpperHalf
|
ModeUpperHalf
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef SDR_TX_SAMPLE_24BIT
|
|
||||||
typedef bool (IntHalfbandFilterDB<qint64, UPCHANNELIZER_HB_FILTER_ORDER>::*WorkFunction)(Sample* sIn, Sample *sOut);
|
|
||||||
IntHalfbandFilterDB<qint64, UPCHANNELIZER_HB_FILTER_ORDER>* m_filter;
|
|
||||||
#else
|
|
||||||
#ifdef USE_SSE4_1
|
#ifdef USE_SSE4_1
|
||||||
typedef bool (IntHalfbandFilterEO1<UPCHANNELIZER_HB_FILTER_ORDER>::*WorkFunction)(Sample* sIn, Sample *sOut);
|
typedef bool (IntHalfbandFilterEO1<UPCHANNELIZER_HB_FILTER_ORDER>::*WorkFunction)(Sample* sIn, Sample *sOut);
|
||||||
IntHalfbandFilterEO1<UPCHANNELIZER_HB_FILTER_ORDER>* m_filter;
|
IntHalfbandFilterEO1<UPCHANNELIZER_HB_FILTER_ORDER>* m_filter;
|
||||||
#else
|
#else
|
||||||
typedef bool (IntHalfbandFilterDB<qint32, UPCHANNELIZER_HB_FILTER_ORDER>::*WorkFunction)(Sample* sIn, Sample *sOut);
|
typedef bool (IntHalfbandFilterDB<qint32, UPCHANNELIZER_HB_FILTER_ORDER>::*WorkFunction)(Sample* sIn, Sample *sOut);
|
||||||
IntHalfbandFilterDB<qint32, UPCHANNELIZER_HB_FILTER_ORDER>* m_filter;
|
IntHalfbandFilterDB<qint32, UPCHANNELIZER_HB_FILTER_ORDER>* m_filter;
|
||||||
#endif
|
|
||||||
#endif
|
#endif
|
||||||
WorkFunction m_workFunction;
|
WorkFunction m_workFunction;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user