Re: Directly setting biquad coefficients

Whoopee!!! Great idea (in meantime we didnít dare asking again :-).

On 08 Oct 2014, at 17:22, Raymond Toy <rtoy@google.com> wrote:
> Chris and I were discussing the possibility of allowing a user to set the coefficients of a biquad filter directly, as mentioned in https://github.com/WebAudio/web-audio-api/issues/323
> 
> This ability makes it possible to have a first-order filter, which isn't possible now. This also makes it easier to create higher-order filters from biquads where you've decomposed the filter into a set of biquads with the coefficients. No need to convert each biquad into a lowpass, bandpass, and highpass filter with appropriate frrequency and Q values.
> 
> We think this is a good idea, but were not sure on exactly how to expose this.
> Should we have setCoefficients(b0,b1,b2,a1,a2) create a "custom" filter type?
> This would preclude any kind of automation.
> The values of frequency, Q, gain would be undefined (in some way) for this filter type.
> Should the individual coefficients be exposed as audioparams?
> We couldn't come up with an actual use-case where any one would want, say, a linear ramp for, say, coefficient a1
> Some possibly interesting filtering affects might be possible.
> Thoughts?

I clearly would vote for the second (the audio parameters).
For many time variant filters it makes sense to update the coefficients with a more sophisticated algorithm on one rate (e.g. every few milliseconds) and add linear transitions between successive sets of coefficients in audio rate to generate smooth filters.

N.

_____________________
N o r b e r t   S c h n e l l
{ Sound Music Movement } Interaction
IRCAM Ė Centre Pompidou

Received on Wednesday, 8 October 2014 16:04:10 UTC