Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Simplify biquad filter API #17

Closed
justinzane opened this Issue · 1 comment

1 participant

@justinzane
Owner

Finally, it would be great if you could wrap all the biquad state in a
filter object so that modules wouldn't have to manage all that by
themselves. The object would have a simple process() function that takes
just an input and an output buffer and the requested number of frames to
process. Similarly, there would be a simple rewind() function for
resetting the filter to an earlier state.
Um, ok. I'll try to get that to work.

10 (probably a duplicate of (6)). In general, I think that any direct
reference to w0 or y0 in module-lfe-lp.c is a sign of bad API design
in biquad.h. Please refactor, so that you don't have to write this:

                hp = filter_biquad(& (u->s1hpdt[chan_idx]), *

(u->hpfs), cur_sample);
bqdtel.w0 = u->s1hpdt[chan_idx].w0; /* <--- this /
bqdtel.y0 = u->s1hpdt[chan_idx].y0; /
<--- and this */
filter_store_history(u->s1histbuf, &bqdtel);

In fact I think that you don't need u->s1hpdt and its friends at all,
you probably can just store all the w and y data in the history buffer
directly.
Tanu asked me to refactor to simplify the biquad API. I agree with both of you that it is very clumsy now.

@justinzane justinzane was assigned
@justinzane
Owner

Simplified. Better?

@justinzane justinzane closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.