| 1 | //-----------------------------------------------------cxx . . $ `<file>/audio/system_compressor.cpp`/ |
| 2 | // |
| 3 | // Code generated with Faust 0.9.55 (http://faust.grame.fr) |
| 4 | //----------------------------------------------------- |
| 5 | #ifndef FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! |
| 6 | #define FAUSTFLOAT float |
| 7 | #endif |
| 8 | |
| 9 | typedef long double quadcxx . . $ quad#; |
| 10 | /* link with : "" */ |
| 11 | #include "typepunning.h"cxx . . $ `<file>/audio/typepunning.h`/ |
| 12 | #include <math.h> |
| 13 | |
| 14 | #ifndef FAUSTCLASS |
| 15 | #define FAUSTCLASScxx . . $ `audio/system_compressor.cpp:15:9`! Faust_system_compressor |
| 16 | #endif |
| 17 | |
| 18 | class Faust_system_compressorcxx . . $ Faust_system_compressor# : public dspcxx . . $ dsp# { |
| 19 | private: |
| 20 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fcheckbox0cxx . . $ Faust_system_compressor#fcheckbox0.; |
| 21 | int iConst0cxx . . $ Faust_system_compressor#iConst0.; |
| 22 | float fConst1cxx . . $ Faust_system_compressor#fConst1.; |
| 23 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fslider0cxx . . $ Faust_system_compressor#fslider0.; |
| 24 | float fRec2_permcxx . . $ Faust_system_compressor#fRec2_perm.[4]; |
| 25 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fslider1cxx . . $ Faust_system_compressor#fslider1.; |
| 26 | float fRec1_permcxx . . $ Faust_system_compressor#fRec1_perm.[4]; |
| 27 | float fConst2cxx . . $ Faust_system_compressor#fConst2.; |
| 28 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fslider2cxx . . $ Faust_system_compressor#fslider2.; |
| 29 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fbargraph0cxx . . $ Faust_system_compressor#fbargraph0.; |
| 30 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fslider3cxx . . $ Faust_system_compressor#fslider3.; |
| 31 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fbargraph1cxx . . $ Faust_system_compressor#fbargraph1.; |
| 32 | float fRec0_permcxx . . $ Faust_system_compressor#fRec0_perm.[4]; |
| 33 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`! fslider4cxx . . $ Faust_system_compressor#fslider4.; |
| 34 | public: |
| 35 | static void metadatacxx . . $ Faust_system_compressor#metadata(57a28a66035fade8).(Metacxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#* m) { |
| 36 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("filter.lib/name", "Faust Filter Library"); |
| 37 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("filter.lib/author", "Julius O. Smith (jos at ccrma.stanford.edu)"); |
| 38 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("filter.lib/copyright", "Julius O. Smith III"); |
| 39 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("filter.lib/version", "1.29"); |
| 40 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("filter.lib/license", "STK-4.3"); |
| 41 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("filter.lib/reference", "https://ccrma.stanford.edu/~jos/filters/"); |
| 42 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("music.lib/name", "Music Library"); |
| 43 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("music.lib/author", "GRAME"); |
| 44 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("music.lib/copyright", "GRAME"); |
| 45 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("music.lib/version", "1.0"); |
| 46 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("music.lib/license", "LGPL with exception"); |
| 47 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("math.lib/name", "Math Library"); |
| 48 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("math.lib/author", "GRAME"); |
| 49 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("math.lib/copyright", "GRAME"); |
| 50 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("math.lib/version", "1.0"); |
| 51 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("math.lib/license", "LGPL with exception"); |
| 52 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("effect.lib/name", "Faust Audio Effect Library"); |
| 53 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("effect.lib/author", "Julius O. Smith (jos at ccrma.stanford.edu)"); |
| 54 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("effect.lib/copyright", "Julius O. Smith III"); |
| 55 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("effect.lib/version", "1.33"); |
| 56 | m->declarecxx . . $ `$anonymous_namespace_audio/system_compressor_wrapper.cpp`/Meta#declare(2fa786934fe80e24).("effect.lib/license", "STK-4.3"); |
| 57 | } |
| 58 | |
| 59 | virtual int getNumInputscxx . . $ Faust_system_compressor#getNumInputs(b126dc7c1de90089).() { return 2; } |
| 60 | virtual int getNumOutputscxx . . $ Faust_system_compressor#getNumOutputs(b126dc7c1de90089).() { return 2; } |
| 61 | static void classInitcxx . . $ Faust_system_compressor#classInit(d4f767463ce0a6b3).(int samplingFreq) { |
| 62 | } |
| 63 | virtual void instanceInitcxx . . $ Faust_system_compressor#instanceInit(d4f767463ce0a6b3).(int samplingFreq) { |
| 64 | fSamplingFreqcxx . . $ dsp#fSamplingFreq. = samplingFreq; |
| 65 | fcheckbox0cxx . . $ Faust_system_compressor#fcheckbox0. = 0.0; |
| 66 | iConst0cxx . . $ Faust_system_compressor#iConst0. = mincxx . . $ min(9b79fb6aee4c0440).(192000, maxcxx . . $ max(9b79fb6aee4c0440).(1, fSamplingFreqcxx . . $ dsp#fSamplingFreq.)); |
| 67 | fConst1cxx . . $ Faust_system_compressor#fConst1. = (1.0f / float(iConst0cxx . . $ Faust_system_compressor#iConst0.)); |
| 68 | fslider0cxx . . $ Faust_system_compressor#fslider0. = 100.237f; |
| 69 | for (int i=0; i<4; i++) fRec2_permcxx . . $ Faust_system_compressor#fRec2_perm.[i]=0; |
| 70 | fslider1cxx . . $ Faust_system_compressor#fslider1. = 50.148f; |
| 71 | for (int i=0; i<4; i++) fRec1_permcxx . . $ Faust_system_compressor#fRec1_perm.[i]=0; |
| 72 | fConst2cxx . . $ Faust_system_compressor#fConst2. = (2.0f / float(iConst0cxx . . $ Faust_system_compressor#iConst0.)); |
| 73 | fslider2cxx . . $ Faust_system_compressor#fslider2. = -2e+01f; |
| 74 | fslider3cxx . . $ Faust_system_compressor#fslider3. = 2.0f; |
| 75 | for (int i=0; i<4; i++) fRec0_permcxx . . $ Faust_system_compressor#fRec0_perm.[i]=0; |
| 76 | fslider4cxx . . $ Faust_system_compressor#fslider4. = 0.0f; |
| 77 | } |
| 78 | virtual void initcxx . . $ Faust_system_compressor#init(d4f767463ce0a6b3).(int samplingFreq) { |
| 79 | classInitcxx . . $ Faust_system_compressor#classInit(d4f767463ce0a6b3).(samplingFreq); |
| 80 | instanceInitcxx . . $ Faust_system_compressor#instanceInit(d4f767463ce0a6b3).(samplingFreq); |
| 81 | } |
| 82 | virtual void buildUserInterfacecxx . . $ Faust_system_compressor#buildUserInterface(c644848e20fbf927).(UIcxx . . $ UI#* interface) { |
| 83 | interface->openVerticalBoxcxx . . $ UI#openVerticalBox(85c52e162fed56f9).("standalone_compressor"); |
| 84 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider3cxx . . $ Faust_system_compressor#fslider3., "0", ""); |
| 85 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider3cxx . . $ Faust_system_compressor#fslider3., "style", "slider"); |
| 86 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider3cxx . . $ Faust_system_compressor#fslider3., "tooltip", "A compression Ratio of N means that for each N dB increase in input signal level above Threshold, the output level goes up 1 dB"); |
| 87 | interface->addHorizontalSlidercxx . . $ UI#addHorizontalSlider(dd97e545ed932d9f).("Ratio", &fslider3cxx . . $ Faust_system_compressor#fslider3., 2.0f, 1.0f, 2e+01f, 0.1f); |
| 88 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider2cxx . . $ Faust_system_compressor#fslider2., "1", ""); |
| 89 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider2cxx . . $ Faust_system_compressor#fslider2., "style", "slider"); |
| 90 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider2cxx . . $ Faust_system_compressor#fslider2., "tooltip", "When the signal level exceeds the Threshold (in dB), its level is compressed according to the Ratio"); |
| 91 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider2cxx . . $ Faust_system_compressor#fslider2., "unit", "dB"); |
| 92 | interface->addHorizontalSlidercxx . . $ UI#addHorizontalSlider(dd97e545ed932d9f).("Threshold", &fslider2cxx . . $ Faust_system_compressor#fslider2., -2e+01f, -2e+01f, 2e+01f, 0.1f); |
| 93 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider1cxx . . $ Faust_system_compressor#fslider1., "2", ""); |
| 94 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider1cxx . . $ Faust_system_compressor#fslider1., "style", "slider"); |
| 95 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider1cxx . . $ Faust_system_compressor#fslider1., "tooltip", "Time constant in ms (1/e smoothing time) for the compression gain to approach (exponentially) a new lower target level (the compression `kicking in')"); |
| 96 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider1cxx . . $ Faust_system_compressor#fslider1., "unit", "ms"); |
| 97 | interface->addHorizontalSlidercxx . . $ UI#addHorizontalSlider(dd97e545ed932d9f).("Attack", &fslider1cxx . . $ Faust_system_compressor#fslider1., 50.148f, 0.0f, 5e+02f, 0.1f); |
| 98 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider0cxx . . $ Faust_system_compressor#fslider0., "3", ""); |
| 99 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider0cxx . . $ Faust_system_compressor#fslider0., "style", "slider"); |
| 100 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider0cxx . . $ Faust_system_compressor#fslider0., "tooltip", "Time constant in ms (1/e smoothing time) for the compression gain to approach (exponentially) a new higher target level (the compression 'releasing')"); |
| 101 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider0cxx . . $ Faust_system_compressor#fslider0., "unit", "ms"); |
| 102 | interface->addHorizontalSlidercxx . . $ UI#addHorizontalSlider(dd97e545ed932d9f).("Release", &fslider0cxx . . $ Faust_system_compressor#fslider0., 100.237f, 0.0f, 1e+03f, 0.1f); |
| 103 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider4cxx . . $ Faust_system_compressor#fslider4., "5", ""); |
| 104 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider4cxx . . $ Faust_system_compressor#fslider4., "tooltip", "The compressed-signal output level is increased by this amount (in dB) to make up for the level lost due to compression"); |
| 105 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fslider4cxx . . $ Faust_system_compressor#fslider4., "unit", "dB"); |
| 106 | interface->addHorizontalSlidercxx . . $ UI#addHorizontalSlider(dd97e545ed932d9f).("Output Gain", &fslider4cxx . . $ Faust_system_compressor#fslider4., 0.0f, -4e+01f, 4e+01f, 0.1f); |
| 107 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fcheckbox0cxx . . $ Faust_system_compressor#fcheckbox0., "6", ""); |
| 108 | interface->addCheckButtoncxx . . $ UI#addCheckButton(d2efea74a95ba4f0).("bypass", &fcheckbox0cxx . . $ Faust_system_compressor#fcheckbox0.); |
| 109 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fbargraph0cxx . . $ Faust_system_compressor#fbargraph0., "0", ""); |
| 110 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fbargraph0cxx . . $ Faust_system_compressor#fbargraph0., "7", ""); |
| 111 | interface->addHorizontalBargraphcxx . . $ UI#addHorizontalBargraph(9c4395346a0a905e).("Gakk", &fbargraph0cxx . . $ Faust_system_compressor#fbargraph0., -5e+01f, 1e+01f); |
| 112 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fbargraph1cxx . . $ Faust_system_compressor#fbargraph1., "1", ""); |
| 113 | interface->declarecxx . . $ UI#declare(295f22ccbfb41ed).(&fbargraph1cxx . . $ Faust_system_compressor#fbargraph1., "7", ""); |
| 114 | interface->addHorizontalBargraphcxx . . $ UI#addHorizontalBargraph(9c4395346a0a905e).("Gakk", &fbargraph1cxx . . $ Faust_system_compressor#fbargraph1., -5e+01f, 1e+01f); |
| 115 | interface->closeBoxcxx . . $ UI#closeBox(49f6e7a06ebc5aa8).(); |
| 116 | } |
| 117 | virtual void computecxx . . $ Faust_system_compressor#compute(4254ec6c518224ca). (int fullcount, FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!** input, FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!** output) { |
| 118 | float fZec0[32]; |
| 119 | float fZec1[32]; |
| 120 | float fZec2[32]; |
| 121 | float fRec2_tmp[32+4]; |
| 122 | float fRec1_tmp[32+4]; |
| 123 | float fZec3[32]; |
| 124 | float fZec4[32]; |
| 125 | float fRec0_tmp[32+4]; |
| 126 | float fZec5[32]; |
| 127 | int iSlow0 = int(fcheckbox0cxx . . $ Faust_system_compressor#fcheckbox0.); |
| 128 | float fSlow1 = expf((0 - (fConst1cxx . . $ Faust_system_compressor#fConst1. / maxcxx . . $ max(d59a45cd3bfd2eda).(fConst1cxx . . $ Faust_system_compressor#fConst1., (0.001f * fslider0cxx . . $ Faust_system_compressor#fslider0.))))); |
| 129 | float fSlow2 = (1.0f - fSlow1); |
| 130 | float* fRec2 = &fRec2_tmp[4]; |
| 131 | float fSlow3 = maxcxx . . $ max(d59a45cd3bfd2eda).(fConst1cxx . . $ Faust_system_compressor#fConst1., (0.001f * fslider1cxx . . $ Faust_system_compressor#fslider1.)); |
| 132 | float fSlow4 = expf((0 - (fConst1cxx . . $ Faust_system_compressor#fConst1. / fSlow3))); |
| 133 | float fSlow5 = (1.0f - fSlow4); |
| 134 | float* fRec1 = &fRec1_tmp[4]; |
| 135 | float fSlow6 = expf((0 - (fConst2cxx . . $ Faust_system_compressor#fConst2. / fSlow3))); |
| 136 | float fSlow7 = fslider2cxx . . $ Faust_system_compressor#fslider2.; |
| 137 | float fSlow8 = ((1.0f / float(fslider3cxx . . $ Faust_system_compressor#fslider3.)) - 1.0f); |
| 138 | float fSlow9 = (1.0f - fSlow6); |
| 139 | float* fRec0 = &fRec0_tmp[4]; |
| 140 | float fSlow10 = powf(10,(0.05f * fslider4cxx . . $ Faust_system_compressor#fslider4.)); |
| 141 | int index; |
| 142 | for (index = 0; index <= fullcount - 32; index += 32) { |
| 143 | // compute by blocks of 32 samples |
| 144 | const int count = 32; |
| 145 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* input0 = &input[0][index]; |
| 146 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* input1 = &input[1][index]; |
| 147 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* output0 = &output[0][index]; |
| 148 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* output1 = &output[1][index]; |
| 149 | // SECTION : 1 |
| 150 | // LOOP 0x1e40000 |
| 151 | // exec code |
| 152 | for (int i=0; i<count; i++) { |
| 153 | fZec0[i] = ((iSlow0)?0:(float)input0[i]); |
| 154 | } |
| 155 | |
| 156 | // LOOP 0x1e410e0 |
| 157 | // exec code |
| 158 | for (int i=0; i<count; i++) { |
| 159 | fZec1[i] = ((iSlow0)?0:(float)input1[i]); |
| 160 | } |
| 161 | |
| 162 | // SECTION : 2 |
| 163 | // LOOP 0x1e3ff20 |
| 164 | // exec code |
| 165 | for (int i=0; i<count; i++) { |
| 166 | fZec2[i] = fabsf((fabsf(fZec1[i]) + fabsf(fZec0[i]))); |
| 167 | } |
| 168 | |
| 169 | // SECTION : 3 |
| 170 | // LOOP 0x1e3fbb0 |
| 171 | // pre processing |
| 172 | for (int i=0; i<4; i++) fRec2_tmp[i]=fRec2_permcxx . . $ Faust_system_compressor#fRec2_perm.[i]; |
| 173 | // exec code |
| 174 | for (int i=0; i<count; i++) { |
| 175 | fRec2[i] = ((fSlow2 * fZec2[i]) + (fSlow1 * maxcxx . . $ max(d59a45cd3bfd2eda).(fZec2[i], fRec2[i-1]))); |
| 176 | } |
| 177 | // post processing |
| 178 | for (int i=0; i<4; i++) fRec2_permcxx . . $ Faust_system_compressor#fRec2_perm.[i]=fRec2_tmp[count+i]; |
| 179 | |
| 180 | // SECTION : 4 |
| 181 | // LOOP 0x1e3f6d0 |
| 182 | // pre processing |
| 183 | for (int i=0; i<4; i++) fRec1_tmp[i]=fRec1_permcxx . . $ Faust_system_compressor#fRec1_perm.[i]; |
| 184 | // exec code |
| 185 | for (int i=0; i<count; i++) { |
| 186 | fRec1[i] = ((fSlow5 * fRec2[i]) + (fSlow4 * fRec1[i-1])); |
| 187 | } |
| 188 | // post processing |
| 189 | for (int i=0; i<4; i++) fRec1_permcxx . . $ Faust_system_compressor#fRec1_perm.[i]=fRec1_tmp[count+i]; |
| 190 | |
| 191 | // SECTION : 5 |
| 192 | // LOOP 0x1e46fd0 |
| 193 | // exec code |
| 194 | for (int i=0; i<count; i++) { |
| 195 | fZec3[i] = (8.685889638065037f * ((8.262958288192749e-08f * float(pun_float_to_intcxx . . $ pun_float_to_int(1bb0578f3efdc255).(fRec1[i]))) - 87.989971088f)); |
| 196 | } |
| 197 | |
| 198 | // SECTION : 6 |
| 199 | // LOOP 0x1e46a90 |
| 200 | // exec code |
| 201 | for (int i=0; i<count; i++) { |
| 202 | fbargraph0cxx . . $ Faust_system_compressor#fbargraph0. = fZec3[i]; |
| 203 | fZec4[i] = (fSlow8 * maxcxx . . $ max(d59a45cd3bfd2eda).((fZec3[i] - fSlow7), 0.0f)); |
| 204 | } |
| 205 | |
| 206 | // SECTION : 7 |
| 207 | // LOOP 0x1e3f2d0 |
| 208 | // pre processing |
| 209 | for (int i=0; i<4; i++) fRec0_tmp[i]=fRec0_permcxx . . $ Faust_system_compressor#fRec0_perm.[i]; |
| 210 | // exec code |
| 211 | for (int i=0; i<count; i++) { |
| 212 | fbargraph1cxx . . $ Faust_system_compressor#fbargraph1. = fZec4[i]; |
| 213 | fRec0[i] = ((fSlow9 * fZec4[i]) + (fSlow6 * fRec0[i-1])); |
| 214 | } |
| 215 | // post processing |
| 216 | for (int i=0; i<4; i++) fRec0_permcxx . . $ Faust_system_compressor#fRec0_perm.[i]=fRec0_tmp[count+i]; |
| 217 | |
| 218 | // SECTION : 8 |
| 219 | // LOOP 0x1e4b140 |
| 220 | // exec code |
| 221 | for (int i=0; i<count; i++) { |
| 222 | fZec5[i] = pun_int_to_floatcxx . . $ pun_int_to_float(5cde91ea12d43f46).((8388608 * (126.94269504f + maxcxx . . $ max(d59a45cd3bfd2eda).(-126.0f, (0.16609640464202244f * fRec0[i]))))); |
| 223 | } |
| 224 | |
| 225 | // SECTION : 9 |
| 226 | // LOOP 0x1e3f0a0 |
| 227 | // exec code |
| 228 | for (int i=0; i<count; i++) { |
| 229 | output0[i] = (FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!)((iSlow0)?(float)input0[i]:(fSlow10 * (fZec0[i] * fZec5[i]))); |
| 230 | } |
| 231 | |
| 232 | // LOOP 0x1e4d0e0 |
| 233 | // exec code |
| 234 | for (int i=0; i<count; i++) { |
| 235 | output1[i] = (FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!)((iSlow0)?(float)input1[i]:(fSlow10 * (fZec1[i] * fZec5[i]))); |
| 236 | } |
| 237 | |
| 238 | } |
| 239 | if (index < fullcount) { |
| 240 | // compute the remaining samples if any |
| 241 | int count = fullcount-index; |
| 242 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* input0 = &input[0][index]; |
| 243 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* input1 = &input[1][index]; |
| 244 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* output0 = &output[0][index]; |
| 245 | FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!* output1 = &output[1][index]; |
| 246 | // SECTION : 1 |
| 247 | // LOOP 0x1e40000 |
| 248 | // exec code |
| 249 | for (int i=0; i<count; i++) { |
| 250 | fZec0[i] = ((iSlow0)?0:(float)input0[i]); |
| 251 | } |
| 252 | |
| 253 | // LOOP 0x1e410e0 |
| 254 | // exec code |
| 255 | for (int i=0; i<count; i++) { |
| 256 | fZec1[i] = ((iSlow0)?0:(float)input1[i]); |
| 257 | } |
| 258 | |
| 259 | // SECTION : 2 |
| 260 | // LOOP 0x1e3ff20 |
| 261 | // exec code |
| 262 | for (int i=0; i<count; i++) { |
| 263 | fZec2[i] = fabsf((fabsf(fZec1[i]) + fabsf(fZec0[i]))); |
| 264 | } |
| 265 | |
| 266 | // SECTION : 3 |
| 267 | // LOOP 0x1e3fbb0 |
| 268 | // pre processing |
| 269 | for (int i=0; i<4; i++) fRec2_tmp[i]=fRec2_permcxx . . $ Faust_system_compressor#fRec2_perm.[i]; |
| 270 | // exec code |
| 271 | for (int i=0; i<count; i++) { |
| 272 | fRec2[i] = ((fSlow2 * fZec2[i]) + (fSlow1 * maxcxx . . $ max(d59a45cd3bfd2eda).(fZec2[i], fRec2[i-1]))); |
| 273 | } |
| 274 | // post processing |
| 275 | for (int i=0; i<4; i++) fRec2_permcxx . . $ Faust_system_compressor#fRec2_perm.[i]=fRec2_tmp[count+i]; |
| 276 | |
| 277 | // SECTION : 4 |
| 278 | // LOOP 0x1e3f6d0 |
| 279 | // pre processing |
| 280 | for (int i=0; i<4; i++) fRec1_tmp[i]=fRec1_permcxx . . $ Faust_system_compressor#fRec1_perm.[i]; |
| 281 | // exec code |
| 282 | for (int i=0; i<count; i++) { |
| 283 | fRec1[i] = ((fSlow5 * fRec2[i]) + (fSlow4 * fRec1[i-1])); |
| 284 | } |
| 285 | // post processing |
| 286 | for (int i=0; i<4; i++) fRec1_permcxx . . $ Faust_system_compressor#fRec1_perm.[i]=fRec1_tmp[count+i]; |
| 287 | |
| 288 | // SECTION : 5 |
| 289 | // LOOP 0x1e46fd0 |
| 290 | // exec code |
| 291 | for (int i=0; i<count; i++) { |
| 292 | fZec3[i] = (8.685889638065037f * ((8.262958288192749e-08f * float(pun_float_to_intcxx . . $ pun_float_to_int(1bb0578f3efdc255).(fRec1[i]))) - 87.989971088f)); |
| 293 | } |
| 294 | |
| 295 | // SECTION : 6 |
| 296 | // LOOP 0x1e46a90 |
| 297 | // exec code |
| 298 | for (int i=0; i<count; i++) { |
| 299 | fbargraph0cxx . . $ Faust_system_compressor#fbargraph0. = fZec3[i]; |
| 300 | fZec4[i] = (fSlow8 * maxcxx . . $ max(d59a45cd3bfd2eda).((fZec3[i] - fSlow7), 0.0f)); |
| 301 | } |
| 302 | |
| 303 | // SECTION : 7 |
| 304 | // LOOP 0x1e3f2d0 |
| 305 | // pre processing |
| 306 | for (int i=0; i<4; i++) fRec0_tmp[i]=fRec0_permcxx . . $ Faust_system_compressor#fRec0_perm.[i]; |
| 307 | // exec code |
| 308 | for (int i=0; i<count; i++) { |
| 309 | fbargraph1cxx . . $ Faust_system_compressor#fbargraph1. = fZec4[i]; |
| 310 | fRec0[i] = ((fSlow9 * fZec4[i]) + (fSlow6 * fRec0[i-1])); |
| 311 | } |
| 312 | // post processing |
| 313 | for (int i=0; i<4; i++) fRec0_permcxx . . $ Faust_system_compressor#fRec0_perm.[i]=fRec0_tmp[count+i]; |
| 314 | |
| 315 | // SECTION : 8 |
| 316 | // LOOP 0x1e4b140 |
| 317 | // exec code |
| 318 | for (int i=0; i<count; i++) { |
| 319 | fZec5[i] = pun_int_to_floatcxx . . $ pun_int_to_float(5cde91ea12d43f46).((8388608 * (126.94269504f + maxcxx . . $ max(d59a45cd3bfd2eda).(-126.0f, (0.16609640464202244f * fRec0[i]))))); |
| 320 | } |
| 321 | |
| 322 | // SECTION : 9 |
| 323 | // LOOP 0x1e3f0a0 |
| 324 | // exec code |
| 325 | for (int i=0; i<count; i++) { |
| 326 | output0[i] = (FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!)((iSlow0)?(float)input0[i]:(fSlow10 * (fZec0[i] * fZec5[i]))); |
| 327 | } |
| 328 | |
| 329 | // LOOP 0x1e4d0e0 |
| 330 | // exec code |
| 331 | for (int i=0; i<count; i++) { |
| 332 | output1[i] = (FAUSTFLOATcxx . . $ `audio/faudiostream/architecture/faust/gui/UI.h:5:9`!)((iSlow0)?(float)input1[i]:(fSlow10 * (fZec1[i] * fZec5[i]))); |
| 333 | } |
| 334 | |
| 335 | } |
| 336 | } |
| 337 | }; |
| 338 | |
| 339 |