Browse Source

Use minimum of 1 channel for VCAs.

tags/v1.0.2
Andrew Belt 4 years ago
parent
commit
22209d1816
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/VCA.cpp

+ 2
- 2
src/VCA.cpp View File

@@ -30,7 +30,7 @@ struct VCA : Module {

void processChannel(Input &in, Param &level, Input &lin, Input &exp, Output &out) {
// Get input
int channels = in.getChannels();
int channels = std::max(in.getChannels(), 1);
simd::float_4 v[4];
for (int c = 0; c < channels; c += 4) {
v[c / 4] = simd::float_4::load(in.getVoltages(c));
@@ -153,7 +153,7 @@ struct VCA_1 : Module {
}

void process(const ProcessArgs &args) override {
int channels = inputs[IN_INPUT].getChannels();
int channels = std::max(inputs[IN_INPUT].getChannels(), 1);
float amplitudeSum = 0.f;
float level = params[LEVEL_PARAM].getValue();



Loading…
Cancel
Save