Skip to content

Commit

Permalink
restrict max fc smoothing to 5*64 samples
Browse files Browse the repository at this point in the history
  • Loading branch information
derselbst committed Nov 23, 2024
1 parent 5a2c084 commit 208af45
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rvoice/fluid_iir_filter.c
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ void fluid_iir_filter_calc(fluid_iir_filter_t *iir_filter,
{
int fres_incr_count = FLUID_BUFSIZE;
fluid_real_t num_buffers = iir_filter->last_q;
fluid_clip(num_buffers, 1, 8);
fluid_clip(num_buffers, 1, 5);
// For high values of Q, the phase gets really steep. To prevent clicks when quickly modulating fres in this case, we need to smooth out "slower".
// This is done by simply using Q times FLUID_BUFSIZE samples for the interpolation to complete, capped at 8.
fres_incr_count *= num_buffers;
Expand Down

0 comments on commit 208af45

Please sign in to comment.