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