Skip to main content

Module resampler

Module resampler 

Source
Expand description

Default polyphase resampler (f32 core, exact integer timing). Default polyphase FIR resampler (f32 core, exact integer timing).

The filter is the classic Kaiser-windowed polyphase FIR (256 phases × 24 taps). The read position is tracked on an integer grid of input_rate * output_rate ticks per second, so repeated 20 ms frames keep a constant, exact output count (8 kHz → 48 kHz is always 960 samples, never 959/961). The Q15 fixed-point core with the same timing lives in crate::resampler_fixed for targets without an FPU.

Structs§

BoxedResampler
Self-contained Resampler that owns its coefficient buffer (std only).
Resampler

Constants§

COEFFS_LEN
Required length of the caller-provided coefficient buffer (NUM_PHASES * TAPS_PER_PHASE).
NUM_PHASES
Number of polyphase filter phases.
TAPS_PER_PHASE
Number of filter taps per phase.

Functions§

resample
One-shot resampling convenience helper (allocates).