I have a simple code for processing a float buffer with a lowpass filter. Here's the function:
public static float[] lowPass(float[] buffer, float frequnecy) {
AudioFormat audioFormat = new AudioFormat(SAMPLE_RATE, 16, 1, true, false);
AudioEvent audioEvent = new AudioEvent(audioFormat, 1024);
audioEvent.setFloatBuffer(buffer);
LowPassFS lowPassFilter = new LowPassFS(frequnecy, DSP.SAMPLE_RATE);
lowPassFilter.process(audioEvent);
return audioEvent.getFloatBuffer();
}
The result is that the buffer isn't processed at all and returned as is. I can't find a related working example anywhere tough.
Thanks in advance