class
SushiDSP::HalfbandDownsampler2x
2x decimator on a committed Parks-McClellan halfband.
- Declared in
include/SushiDSP/math/Oversampler.hpp
Allocation-free after construction; carries streaming state across process() calls.
Only the retained output samples are computed, and for each only the non-zero taps are touched: the centre tap and the symmetric pairs at odd offsets from it.
Public member functions
explicit HalfbandDownsampler2x(const HalfbandDesign &design=kHalfbandStage1)Parameters
designWhich committed halfband to run.
void process(const float *input, std::uint32_t frames_in, float *output)Lowpass-filters input then drops every other sample.
Parameters
inputframes_in input samples.
frames_inNumber of input frames; must be even.
outputframes_in/2 output samples; must not alias input.
void reset()Zeroes the history so the next process() starts from silence.
std::uint32_t taps() constThe full FIR length of the design in use.
Returns
Number of taps.

