Function synfx_dsp::process_1pole_highpass
source · [−]Expand description
Process a very simple one pole 6dB high pass filter. Useful in various applications.
input- Input samplefreq- Frequency between 1.0 and 22000.0Hzisrate- 1.0 / sampleratez- The first internal buffer of the filter.y- The second internal buffer of the filter.
use synfx_dsp::*;
let samples = vec![0.0; 44100];
let mut z = 0.0;
let mut y = 0.0;
let mut freq = 1000.0;
for s in samples.iter() {
let s_out =
process_1pole_highpass(*s, freq, 1.0 / 44100.0, &mut z, &mut y);
// ... do something with the result here.
}