diff options
author | Damien Zammit <damien@zamaudio.com> | 2020-11-23 18:05:35 +1100 |
---|---|---|
committer | Damien Zammit <damien@zamaudio.com> | 2020-11-23 18:05:35 +1100 |
commit | b4bdad4689de151e7223b75a49d450a0c865854a (patch) | |
tree | 66e81b1c3577c770d699d84b33a4cefd3b55e8dd | |
parent | 60145843a00c332409a2d844090e0a404e4ddcdf (diff) |
ZamTube: Remove gain compensation on tonestacks, unneeded nowzamtube-mosfet
-rw-r--r-- | plugins/ZamTube/ZamTubePlugin.cpp | 3 | ||||
-rw-r--r-- | plugins/ZamTube/wdfcircuits.h | 8 |
2 files changed, 4 insertions, 7 deletions
diff --git a/plugins/ZamTube/ZamTubePlugin.cpp b/plugins/ZamTube/ZamTubePlugin.cpp index 1d7c9a5..4d7c453 100644 --- a/plugins/ZamTube/ZamTubePlugin.cpp +++ b/plugins/ZamTube/ZamTubePlugin.cpp @@ -359,7 +359,6 @@ void ZamTubePlugin::deactivate() void ZamTubePlugin::run(const float** inputs, float** outputs, uint32_t frames) { const uint8_t stack = (uint8_t)tonestack > 24 ? 24 : (uint8_t)tonestack; - const float adjustdb = Tonestacks::adjustdb[stack]; float fSlow0 = float(ts[stack][R4]); float fSlow1 = float(ts[stack][R3]); @@ -413,7 +412,7 @@ void ZamTubePlugin::run(const float** inputs, float** outputs, uint32_t frames) float cut = insane ? 0. : 15.; float pregain = from_dB(tubedrive*3.6364 - cut + mastergain); - float postgain = from_dB(cut + adjustdb + 42. * (1. - log1p(tubedrive/11.))); + float postgain = from_dB(cut + 42. * (1. - log1p(tubedrive/11.))); for (uint32_t i = 0; i < frames; ++i) { diff --git a/plugins/ZamTube/wdfcircuits.h b/plugins/ZamTube/wdfcircuits.h index 517b99a..816c96d 100644 --- a/plugins/ZamTube/wdfcircuits.h +++ b/plugins/ZamTube/wdfcircuits.h @@ -99,7 +99,7 @@ public: //P1_1SetA //RkGetB //P1_2SetA - Real P1_3b3 = /*-*/P1_3Gamma1*(-Ckb); + Real P1_3b3 = P1_3Gamma1*(-Ckb); //S2_2SetA Real S2_3b3 = (P2_3b3 + P1_3b3); //S1_3GetB @@ -107,7 +107,7 @@ public: //S1_1SetA //P0_3GetB //S0_3GetB - Real Cib = Cia; + //Real Cib = Cia; //S0_1SetA //ViGetB //S0_2SetA @@ -119,11 +119,9 @@ public: //S1_2SetA Real S1_3b3 = -(P0_3b3); //P1_3GetB - //Real Ckb = Cka; //P1_1SetA //RkGetB //P1_2SetA - //Real P1_3b3 = -P1_3Gamma1*(-Ckb); //Call tube model Vg = -S1_3b3; Vk = -P1_3b3; @@ -151,7 +149,7 @@ public: Real P0_3b1 = S1_3b2 - S0_3b3 - P0_3Gamma1*(-S0_3b3); //S0_3SetA Real S0_3b1 = /*Cib*/ - S0_3Gamma1*(/*Cib*/ + ViE + P0_3b1); - Cia = S0_3b1; + //Cia = S0_3b1; //RiSetA //printf("Vk=%f Vg=%f Vpk=%f in=%f out=%f\n", Vk,Vg,S2_3b3, ViE,Roa); return -(Roa); |