kneecomp: order of gui elements in faust/faustlive
Closed this issue · 1 comments
trummerschlunk commented
Am am not seeing it... why are parameters displayed in wrong order?
sc_compressor =
(
(ms_enc,ms_enc):
(((RMS_compression_gain_N_chan_db(strength,thresh,att,rel,knee,0,link,N)),si.bus(N) )
: ro.interleave(N,2) : par(i,N,(meter : post_gain : ba.db2linear*(1-bypass)+bypass)*_))
: ms_dec)
with {
N = 2;
bypass = checkbox("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_bypass][1]kneecomp bypass"):si.smoo;
strength = vslider("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_strength][2]kneecomp strength", 0.1, 0, 1, 0.1);
thresh = target + vslider("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_threshold][unit:dB][3]kneecomp threshold",init_kneecomp_thresh,-12,6,1);
att = vslider("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_attack][unit:ms][4]kneecomp attack",40,1,100,1)*0.001;
rel = vslider("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_release][unit:ms][5]kneecomp release",200,1,1000,1)*0.001;
knee = vslider("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_knee][6]kneecomp knee",6,0,30,1);
link = vslider("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_link][7]kneecomp link", 0.6, 0, 1, 0.1);
meter = _<: _,( vbargraph("v:soundsgood/t:expert/h:[5]kneecomp/[unit:dB]",-6,0)) : attach;
// dev version of faust has this in the libs, TODO, use co.RMS_compression_gain_N_chan_db
RMS_compression_gain_N_chan_db(strength,thresh,att,rel,knee,prePost,link,1) =
RMS_compression_gain_mono_db(strength,thresh,att,rel,knee,prePost);
RMS_compression_gain_N_chan_db(strength,thresh,att,rel,knee,prePost,link,N) =
par(i,N,RMS_compression_gain_mono_db(strength,thresh,att,rel,knee,prePost))
<: (si.bus(N),(ba.parallelMin(N) <: si.bus(N))) : ro.interleave(N,2) : par(i,N,(it.interpolate_linear(link)));
RMS_compression_gain_mono_db(strength,thresh,att,rel,knee,prePost) =
RMS(rel) : ba.bypass1(prePost,si.onePoleSwitching(att,0)) : ba.linear2db : gain_computer(strength,thresh,knee) : ba.bypass1((prePost!=1),si.onePoleSwitching(0,att))
with {
gain_computer(strength,thresh,knee,level) =
select3((level>(thresh-(knee/2)))+(level>(thresh+(knee/2))),
0,
((level-thresh+(knee/2)) : pow(2)/(2*max(ma.EPSILON,knee))),
(level-thresh))
: max(0)*-strength;
RMS(time) = ba.slidingRMS(s) with {
s = ba.sec2samp(time):int:max(1);
};
};
//post_gain
post_gain =
_+
(vslider("v:soundsgood/t:expert/h:[5]kneecomp/[symbol:kneecomp_makeup][unit:dB][8]kneecomp makeup", init_kneecomp_postgain,-10,+10,0.5) :si.smoo);
};
trummerschlunk commented
[8] needs to be before [symbol:kneecomp_makeup]