<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote">On Tue, Jul 14, 2020 at 3:16 AM <a href="mailto:MAXIPENNA@libero.it">MAXIPENNA@libero.it</a> <<a href="mailto:maxipenna@libero.it">maxipenna@libero.it</a>> wrote:<br>><br>> Imagine that you need to calculate the five coefficents of a simple biquad filter. The coefficients need to be changed when you rotate the "Freq" knob. In all the lv2 examples I've found, all the coeffs are re-calculated in the "run" method but, from what I know, it's wrong. In the run method I should execute only the code that implements the biquad cell.<br>><br>> The method slider should run in a separate thread and a signal or a variable used to notify run method to fetch the newly calculated coeffs when they're ready and start use them. In theory run thread should be able to mask the slider thread as much as he need it.<br>></div><div class="gmail_quote"><br></div><div class="gmail_quote">There is the worker extension which allows you to have a separate worker thread, so you could do some calculations there, however as Robin indicated this thread then would need to pass the new coefficients to the audio process thread and do interpolation there. So it's hard to say if you'd really have any performance gains.</div><div class="gmail_quote"><br></div><div class="gmail_quote">_Spencer<br></div></div>