Hi, Not quite - you can’t iterate linearly through the biquad’s coefficients. Instead you have to iterate through the frequency and repeatedly calculate the coefficients (a1,2,3 and b1,2,3, depending). this is normally not ~too~ expensive an operation, although that’s all relative.
Ariadne On Apr 27, 2023 at 2:57 PM -0700, Yisheng Jiang <[email protected]>, wrote: > It took a couple days for your suggestion to sink it (possibly) > > > On Apr 25, 2023, at 9:19 PM, Ariadne Lewis-Towbes <[email protected]> wrote: > > > > Hi, > > > > You won't be able to fade between two filtered blocks of complex > > (non-sinusoidal) input to the same effect as modulating an arbitrary single > > filter's frequency. That said, when modulating an IIR filter such as a > > biquad (as shown in your second email's link), you should not need to > > compute the z-transform. You may simply modulate the biquad's parameters > > repeatedly, > > By this you mean compute biquad parameters for start and ending freq, then > incrementing the a0, a1 etc? > > > and unless you're doing something unusual with respect to calculating those > > parameters, the cost will be relatively low. > > > > Best, > > Ariadne Lewis-Towbes > > > > On 2023-04-25 20:37, Yisheng Jiang wrote: > > > I’m trying to render a note that feed into a IIR filter (2-3 poles) > > > whose cutoff frequency following an envelope generator, and it’s not > > > possible for me to compute the z-transform parameters every rendering > > > block.. > > > Is it approximately the same to generate two pcm streams with the > > > starting and ending cutoff frequencies, then cross fade them to make > > > the resultant sound?
