The resampler class for 16-bit impulse response resampling. More...
#include <CDSPResampler.h>
Public Member Functions | |
| CDSPResampler16IR (const double SrcSampleRate, const double DstSampleRate, const int aMaxInLen, const double ReqTransBand=2.0) | |
| Initializes the 16-bit impulse response resampler. See the r8b::CDSPResampler class for details. | |
Public Member Functions inherited from r8b::CDSPResampler | |
| CDSPResampler (const double SrcSampleRate, const double DstSampleRate, const int aMaxInLen, const double ReqTransBand=2.0, const double ReqAtten=206.91, const EDSPFilterPhaseResponse ReqPhase=fprLinearPhase) | |
| Initalizes the resampler object. | |
| virtual void | clear () |
| Clears (resets) the state of this object and returns it to the state after construction. | |
| virtual int | getInLenBeforeOutPos (const int ReqOutPos) const |
| Returns the number of input samples required to advance to the specified output sample position (so that the next process() call passes this output position). | |
| int | getInLenBeforeOutStart (const int ReqOutPos=0) |
| Returns the number of input samples required to advance to the specified output sample position (so that the next process() call passes this output position), starting at the cleared or after-construction state of this object. | |
| int | getInputRequiredForOutput (const int ReqOutSamples) const |
| Returns the number of input samples required to produce at least the specified number of output samples, starting at the cleared or after-construction state of this object. | |
| virtual int | getLatency () const |
| Return the latency, in samples, which is present in the output signal. | |
| virtual double | getLatencyFrac () const |
| Returns fractional latency, in samples, which is present in the output signal. | |
| virtual int | getMaxOutLen (const int) const |
This implementation ignores the supplied parameter and returns the maximal output buffer length that depends on the MaxInLen supplied to the constructor. | |
| template<typename Tin, typename Tout> | |
| void | oneshot (const Tin *ip, int iplen, Tout *op, int oplen) |
| Performs resampling of an input sample buffer of the specified length in the "one-shot" mode. | |
| virtual int | process (double *ip0, int l, double *&op0) |
| Performs sample rate conversion. | |
The resampler class for 16-bit impulse response resampling.
This class defines resampling parameters suitable for 16-bit impulse response resampling, using linear-phase low-pass filter. Impulse responses are non-dynamic signals, and thus need resampler with a lesser SNR. See the r8b::CDSPResampler class for details.
| r8b::CDSPResampler16IR::CDSPResampler16IR | ( | const double | SrcSampleRate, |
| const double | DstSampleRate, | ||
| const int | aMaxInLen, | ||
| const double | ReqTransBand = 2.0 ) |
Initializes the 16-bit impulse response resampler. See the r8b::CDSPResampler class for details.
| SrcSampleRate | Source signal's sample rate. |
| DstSampleRate | Destination signal's sample rate. |
| aMaxInLen | The maximal planned length of the input buffer (in samples) that will be passed to the resampler. |
| ReqTransBand | Required transition band, in percent. |