Skip to content

Commit

Permalink
Add limiter to Ladspa plugin, fix LV2 MultiBandDistortion, increase v…
Browse files Browse the repository at this point in the history
…ersion number
  • Loading branch information
brummer10 committed Dec 25, 2020
1 parent 9e465d8 commit a14b455
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 13 deletions.
22 changes: 22 additions & 0 deletions trunk/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,25 @@
guitarix2 (0.42.1) unstable; urgency=low

* Make new Output Limiter less conservative
* Increase range for Volume controls on the Power Amp plugin
* Fix MultiBandDistortion introduce sonic noise
* Add Limiter to the Ladspa plugin
* add configure option to build and link libgxw(mm) staticaly

-- brummer <[email protected]> Wed, 25 Dec 2020 05:40:42 +0200

guitarix2 (0.42.0) unstable; urgency=low

* Introduce reworked tube simulation by Damien Zammit from ZamAudio
* Reworked French translation by Olivier Humbert
* Add DC-Blocker on the Input
* Add Output Limiter
* Add Volume controls for the Power Amp plugin
* Fix version checks for needed packages
* Fix several small Bugs and hopefully don't introduce to much new ones

-- brummer <[email protected]> Wed, 20 Dec 2020 07:40:42 +0200

guitarix2 (0.41.0) unstable; urgency=low

* Add Slovak translation by Jozef Riha
Expand Down
16 changes: 10 additions & 6 deletions trunk/src/LV2/faust-generated/mbd.cc
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,14 @@ class Dsp: public PluginLV2 {
int iVec0[2];
double fConst0;
double fConst1;
double fConst2;
double fConst3;
FAUSTFLOAT fHslider0;
FAUSTFLOAT *fHslider0_;
double fRec4[2];
FAUSTFLOAT fHslider1;
FAUSTFLOAT *fHslider1_;
double fRec5[2];
double fConst2;
FAUSTFLOAT fHslider2;
FAUSTFLOAT *fHslider2_;
double fRec11[2];
Expand All @@ -33,6 +34,7 @@ class Dsp: public PluginLV2 {
FAUSTFLOAT *fHslider5_;
double fRec6[3];
double fVec2[2];
double fConst4;
double fRec3[2];
double fRec0[2];
int iRec1[2];
Expand Down Expand Up @@ -228,6 +230,8 @@ inline void Dsp::init(uint32_t sample_rate)
fConst0 = std::min<double>(192000.0, std::max<double>(1.0, double(fSampleRate)));
fConst1 = (1.0 / fConst0);
fConst2 = (3.1415926535897931 / fConst0);
fConst3 = (1.0 / (fConst2 + 1.0));
fConst4 = (1.0 - fConst2);
clear_state_f();
}

Expand Down Expand Up @@ -348,7 +352,7 @@ void always_inline Dsp::compute(int count, FAUSTFLOAT *input0, FAUSTFLOAT *outpu
double fTemp5 = std::max<double>(-1.0, std::min<double>(1.0, (fRec4[0] + (std::pow(10.0, (2.0 * fRec5[0])) * (fRec6[2] + (fSlow36 * (fTemp4 + (fSlow38 * fRec6[0]))))))));
double fTemp6 = (fTemp5 * (1.0 - (0.33333333333333331 * mydsp_faustpower2_f(fTemp5))));
fVec2[0] = fTemp6;
fRec3[0] = (((0.995 * fRec3[1]) + fTemp6) - fVec2[1]);
fRec3[0] = (fConst3 * ((fTemp6 - fVec2[1]) + (fConst4 * fRec3[1])));
double fTemp7 = std::max<double>(fConst1, std::fabs(fRec3[0]));
fRec0[0] = (iTemp0 ? std::max<double>(fRec0[1], fTemp7) : fTemp7);
iRec1[0] = (iTemp0 ? (iRec1[1] + 1) : 1);
Expand All @@ -371,7 +375,7 @@ void always_inline Dsp::compute(int count, FAUSTFLOAT *input0, FAUSTFLOAT *outpu
double fTemp13 = std::max<double>(-1.0, std::min<double>(1.0, (fRec16[0] + (std::pow(10.0, (2.0 * fRec17[0])) * (fRec18[2] + (fSlow36 * (fTemp12 + (fSlow38 * fRec18[0]))))))));
double fTemp14 = (fTemp13 * (1.0 - (0.33333333333333331 * mydsp_faustpower2_f(fTemp13))));
fVec4[0] = fTemp14;
fRec15[0] = (((0.995 * fRec15[1]) + fTemp14) - fVec4[1]);
fRec15[0] = (fConst3 * ((fTemp14 - fVec4[1]) + (fConst4 * fRec15[1])));
double fTemp15 = std::max<double>(fConst1, std::fabs(fRec15[0]));
fRec12[0] = (iTemp8 ? std::max<double>(fRec12[1], fTemp15) : fTemp15);
iRec13[0] = (iTemp8 ? (iRec13[1] + 1) : 1);
Expand All @@ -392,7 +396,7 @@ void always_inline Dsp::compute(int count, FAUSTFLOAT *input0, FAUSTFLOAT *outpu
double fTemp20 = std::max<double>(-1.0, std::min<double>(1.0, (fRec28[0] + (std::pow(10.0, (2.0 * fRec29[0])) * (fRec30[2] + (fSlow36 * (fTemp19 + (fSlow38 * fRec30[0]))))))));
double fTemp21 = (fTemp20 * (1.0 - (0.33333333333333331 * mydsp_faustpower2_f(fTemp20))));
fVec6[0] = fTemp21;
fRec27[0] = (((0.995 * fRec27[1]) + fTemp21) - fVec6[1]);
fRec27[0] = (fConst3 * ((fTemp21 - fVec6[1]) + (fConst4 * fRec27[1])));
double fTemp22 = std::max<double>(fConst1, std::fabs(fRec27[0]));
fRec24[0] = (iTemp16 ? std::max<double>(fRec24[1], fTemp22) : fTemp22);
iRec25[0] = (iTemp16 ? (iRec25[1] + 1) : 1);
Expand All @@ -411,7 +415,7 @@ void always_inline Dsp::compute(int count, FAUSTFLOAT *input0, FAUSTFLOAT *outpu
double fTemp26 = std::max<double>(-1.0, std::min<double>(1.0, (fRec39[0] + (fSlow61 * (std::pow(10.0, (2.0 * fRec40[0])) * (((fSlow40 * fRec41[0]) + (fSlow67 * fRec41[1])) + (fSlow40 * fRec41[2])))))));
double fTemp27 = (fTemp26 * (1.0 - (0.33333333333333331 * mydsp_faustpower2_f(fTemp26))));
fVec8[0] = fTemp27;
fRec38[0] = (((0.995 * fRec38[1]) + fTemp27) - fVec8[1]);
fRec38[0] = (fConst3 * ((fTemp27 - fVec8[1]) + (fConst4 * fRec38[1])));
double fTemp28 = std::max<double>(fConst1, std::fabs(fRec38[0]));
fRec35[0] = (iTemp23 ? std::max<double>(fRec35[1], fTemp28) : fTemp28);
iRec36[0] = (iTemp23 ? (iRec36[1] + 1) : 1);
Expand All @@ -425,7 +429,7 @@ void always_inline Dsp::compute(int count, FAUSTFLOAT *input0, FAUSTFLOAT *outpu
double fTemp30 = std::max<double>(-1.0, std::min<double>(1.0, (fRec49[0] + (fSlow61 * (std::pow(10.0, (2.0 * fRec50[0])) * (fRec51[2] + (fRec51[0] + (2.0 * fRec51[1]))))))));
double fTemp31 = (fTemp30 * (1.0 - (0.33333333333333331 * mydsp_faustpower2_f(fTemp30))));
fVec9[0] = fTemp31;
fRec48[0] = (((0.995 * fRec48[1]) + fTemp31) - fVec9[1]);
fRec48[0] = (fConst3 * ((fTemp31 - fVec9[1]) + (fConst4 * fRec48[1])));
double fTemp32 = std::max<double>(fConst1, std::fabs(fRec48[0]));
fRec45[0] = (iTemp29 ? std::max<double>(fRec45[1], fTemp32) : fTemp32);
iRec46[0] = (iTemp29 ? (iRec46[1] + 1) : 1);
Expand Down
10 changes: 5 additions & 5 deletions trunk/src/LV2/faust/mbd.dsp
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ envelop = abs : max ~ (1.0/ma.SR) : rd.maxn(4096) ;
//envelop = abs : max ~ (1.0/ma.SR) : mean(4096); // : max(ba.db2linear(-70)) : ba.linear2db;

process = _: +(anti_denormal_ac): geq: ( dist5s , dist4s , dist3s, dist2s, dist1s) :> *(gain1) with {
dist1s = ef.cubicnl_nodc(drive1,offset1) : vmeter1;
dist2s = ef.cubicnl_nodc(drive2,offset2) : vmeter2;
dist3s = ef.cubicnl_nodc(drive3,offset3) : vmeter3;
dist4s = ef.cubicnl_nodc(drive4,offset4) : vmeter4;
dist5s = ef.cubicnl_nodc(drive5,offset5) : vmeter5;
dist1s = ef.cubicnl(drive1,offset1) : fi.dcblockerat(1.0) : vmeter1;
dist2s = ef.cubicnl(drive2,offset2) : fi.dcblockerat(1.0) : vmeter2;
dist3s = ef.cubicnl(drive3,offset3) : fi.dcblockerat(1.0) : vmeter3;
dist4s = ef.cubicnl(drive4,offset4) : fi.dcblockerat(1.0) : vmeter4;
dist5s = ef.cubicnl(drive5,offset5) : fi.dcblockerat(1.0) : vmeter5;

};
3 changes: 2 additions & 1 deletion trunk/src/ladspa/ladspa_guitarix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1559,6 +1559,7 @@ void StereoEngine::load_static_plugins() {

// rack stereo modules inserted here

pl.add(hardlim::plugin(), PLUGIN_POS_END, PGN_MODE_NORMAL);
pl.add(gx_outputlevel_ladspa::plugin(), PLUGIN_POS_END);

// * fx amp output *
Expand All @@ -1575,7 +1576,7 @@ void StereoEngine::load_static_plugins() {
pl.add(gx_effects::tonecontroll::plugin(), PLUGIN_POS_RACK, PGN_GUI);
pl.add(gx_effects::digital_delay_st::plugin(),PLUGIN_POS_RACK, PGN_GUI);
pl.add(&stereo_convolver.plugin, PLUGIN_POS_RACK, PGN_GUI);
pl.add(&record_st.plugin, PLUGIN_POS_RACK, PGN_GUI);
pl.add(&record_st.plugin, PLUGIN_POS_RACK, PGN_GUI);
pl.add(gx_effects::stereoverb::plugin(), PLUGIN_POS_RACK, PGN_GUI);
pl.add(pluginlib::zita_rev1::plugin(), PLUGIN_POS_RACK);
pl.add(pluginlib::vibe::plugin_stereo(), PLUGIN_POS_RACK);
Expand Down
2 changes: 1 addition & 1 deletion trunk/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ srcdir = '.'
blddir = 'build'

# used by waf dist and waf build
VERSION='0.42.0'
VERSION='0.42.1'
APPNAME='guitarix'

Options.OptionsContext.gxload = \
Expand Down

0 comments on commit a14b455

Please sign in to comment.