SDRAngel
4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
|
#include <interpolator.h>
Public Member Functions | |
Interpolator () | |
~Interpolator () | |
void | create (int phaseSteps, double sampleRate, double cutoff, double nbTapsPerPhase=4.5) |
void | free () |
bool | decimate (Real *distance, const Complex &next, Complex *result) |
bool | interpolate (Real *distance, const Complex &next, Complex *result) |
bool | resample (Real *distance, const Complex &next, bool *consumed, Complex *result) |
Private Member Functions | |
void | createTaps (int nTaps, double sampleRate, double cutoff, std::vector< Real > *taps) |
void | advanceFilter (const Complex &next) |
void | advanceFilter () |
void | doInterpolate (int phase, Complex *result) |
Static Private Member Functions | |
static void | createPolyphaseLowPass (std::vector< Real > &taps, int phaseSteps, double gain, double sampleRateHz, double cutoffFreqHz, double transitionWidthHz, double oobAttenuationdB) |
static void | createPolyphaseLowPass (std::vector< Real > &taps, int phaseSteps, double gain, double sampleRateHz, double cutoffFreqHz, double nbTapsPerPhase) |
Private Attributes | |
float * | m_taps |
float * | m_alignedTaps |
float * | m_taps2 |
float * | m_alignedTaps2 |
std::vector< Complex > | m_samples |
int | m_ptr |
int | m_phaseSteps |
int | m_nTaps |
Definition at line 28 of file interpolator.h.
Interpolator::Interpolator | ( | ) |
Definition at line 70 of file interpolator.cpp.
Interpolator::~Interpolator | ( | ) |
Definition at line 81 of file interpolator.cpp.
References free().
|
inlineprivate |
Definition at line 121 of file interpolator.h.
|
inlineprivate |
Definition at line 132 of file interpolator.h.
void Interpolator::create | ( | int | phaseSteps, |
double | sampleRate, | ||
double | cutoff, | ||
double | nbTapsPerPhase = 4.5 |
||
) |
Definition at line 86 of file interpolator.cpp.
References createPolyphaseLowPass(), free(), i, m_alignedTaps, m_alignedTaps2, m_nTaps, m_phaseSteps, m_ptr, m_samples, m_taps, and m_taps2.
Referenced by WFMDemod::applyAudioSampleRate(), AMDemod::applyAudioSampleRate(), NFMDemod::applyAudioSampleRate(), BFMDemod::applyAudioSampleRate(), WFMMod::applyAudioSampleRate(), AMMod::applyAudioSampleRate(), NFMMod::applyAudioSampleRate(), SSBDemod::applyAudioSampleRate(), SSBMod::applyAudioSampleRate(), ChannelAnalyzer::applyChannelSettings(), WFMDemod::applyChannelSettings(), AMDemod::applyChannelSettings(), UDPSink::applyChannelSettings(), UDPSource::applyChannelSettings(), NFMDemod::applyChannelSettings(), DSDDemod::applyChannelSettings(), BFMDemod::applyChannelSettings(), WFMMod::applyChannelSettings(), AMMod::applyChannelSettings(), NFMMod::applyChannelSettings(), SSBDemod::applyChannelSettings(), FreeDVMod::applyChannelSettings(), SSBMod::applyChannelSettings(), FreeDVDemod::applyChannelSettings(), ATVMod::applyChannelSettings(), AMMod::applyFeedbackAudioSampleRate(), NFMMod::applyFeedbackAudioSampleRate(), SSBMod::applyFeedbackAudioSampleRate(), FreeDVMod::applyFreeDVMode(), FreeDVDemod::applyFreeDVMode(), ChannelAnalyzer::applySettings(), WFMDemod::applySettings(), AMDemod::applySettings(), UDPSink::applySettings(), UDPSource::applySettings(), NFMDemod::applySettings(), DSDDemod::applySettings(), BFMDemod::applySettings(), WFMMod::applySettings(), AMMod::applySettings(), NFMMod::applySettings(), SSBDemod::applySettings(), SSBMod::applySettings(), ATVDemod::applySettings(), ATVMod::applySettings(), LoRaDemod::handleMessage(), LoRaDemod::LoRaDemod(), FreqTracker::setInterpolator(), and UDPSink::UDPSink().
|
staticprivate |
Definition at line 7 of file interpolator.cpp.
Referenced by create().
|
staticprivate |
Definition at line 21 of file interpolator.cpp.
References cos(), i, M_PI, leansdr::max(), and sin().
|
private |
Definition at line 38 of file interpolator.h.
References floor().
Referenced by LoRaDemod::feed(), WFMDemod::feed(), AMDemod::feed(), DSDDemod::feed(), UDPSink::feed(), SSBDemod::feed(), NFMDemod::feed(), FreqTracker::feed(), BFMDemod::feed(), FreeDVDemod::feed(), ChannelAnalyzer::feed(), ATVDemod::feed(), UDPSource::pull(), AMMod::pull(), NFMMod::pull(), SSBMod::pull(), FreeDVMod::pull(), ATVMod::pull(), AMMod::pushFeedback(), NFMMod::pushFeedback(), and SSBMod::pushFeedback().
|
inlineprivate |
Definition at line 144 of file interpolator.h.
References i.
void Interpolator::free | ( | ) |
Definition at line 164 of file interpolator.cpp.
References m_alignedTaps, m_alignedTaps2, m_taps, and m_taps2.
Referenced by create(), and ~Interpolator().
Definition at line 53 of file interpolator.h.
References floor().
Referenced by AMDemod::feed(), SSBDemod::feed(), NFMDemod::feed(), FreqTracker::feed(), FreeDVDemod::feed(), UDPSource::pull(), AMMod::pull(), WFMMod::pull(), NFMMod::pull(), SSBMod::pull(), FreeDVMod::pull(), ATVMod::pull(), AMMod::pushFeedback(), NFMMod::pushFeedback(), and SSBMod::pushFeedback().
|
inline |
Definition at line 71 of file interpolator.h.
References floor().
|
private |
Definition at line 94 of file interpolator.h.
|
private |
Definition at line 96 of file interpolator.h.
|
private |
Definition at line 100 of file interpolator.h.
Referenced by create().
|
private |
Definition at line 99 of file interpolator.h.
Referenced by create().
|
private |
Definition at line 98 of file interpolator.h.
Referenced by create().
|
private |
Definition at line 97 of file interpolator.h.
Referenced by create().
|
private |
Definition at line 93 of file interpolator.h.
|
private |
Definition at line 95 of file interpolator.h.