Hi Frank,
I think that your main cpu issue is related to the fact that you don't need
to recalculate the coefficients on every sample. You can set a
variable/flag that can tell you when a change of the parameters is needed
and then use this to trigger the computation.
In addition, you can set this on a window/frame-based system. At the
beginning of each frame, you can check if a change is needed, and based on
that compute and update the parameters.

In the past, I implemented audio classes based on the base class shown in
http://www.redwoodaudio.net/Tutorials/juce_for_vst_development__intro6.html at
point 3 (end of the page). Maybe you can try to have a look at it.

Hope this helps,
Davide

On Sun, 12 Jan 2020 at 07:07, Frank Sheeran <fshee...@gmail.com> wrote:

> I have a couple audio programming books (Zolzer DAFX and Pirkle Designing
> Audio Effect Plugins in C++).  All the filters they describe were easy
> enough to program.
>
> However, they don't discuss having the frequency and resonance (or
> whatever inputs a given filter has--parametric EQ etc.) CHANGE.
>
> I am doing the expensive thing of recalculating all the coefficients every
> sample, but that uses a lot of CPU.
>
> My questions are:
>
> 1. Is there a cheaper way to do this?  For instance can one pre-calculate
> a big matrix of filter coefficients, say 128 cutoffs (about enough for each
> semitone of human hearing) and maybe 10 resonances, and simply
> interpolating between them?  Does that even work?
>
> 2. when filter coefficients change, are the t-1 and t-2 values in the
> pipeline still good to use?  I am using them and it SEEMS fine but now and
> then the filters in rare cases go to infinity (maybe fast changes with high
> resonance?) and I wonder if this is the cause.
>
> 3. Would you guess that most commercial software is using SIMD or GPU for
> this nowadays?  Can anyone confirm at least some implementations use SIMD
> or GPU?
>
> Frank
>
> _______________________________________________
> dupswapdrop: music-dsp mailing list
> music-dsp@music.columbia.edu
> https://lists.columbia.edu/mailman/listinfo/music-dsp
_______________________________________________
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Reply via email to