VCVRack / AudibleInstruments

VCV Rack plugin based on Mutable Instruments Eurorack modules
https://vcvrack.com/AudibleInstruments.html
Other
387 stars 84 forks source link

Tides HIGH/LOW output gates are wrong #74

Open AndrewBelt opened 5 years ago

AndrewBelt commented 5 years ago

From dmdoull43@gmail.com

Hi, I wanted to bring a bug to your attention. The high and low tide outputs of the Tidal Modulator plugin don't work the way they're supposed to. The high output should output a positive voltage when the attack phase is done, the low output should output a positive voltage when the entire cycle is done, and both should reset when the envelope starts to cycle again. Currently, the high output is producing a signal during the entire attack phase, and the low output consistently outputs a positive voltage no matter what.

alanholding commented 1 year ago

This can be fixed by changing the following two lines (from line 160) in src/Tides.cpp: https://github.com/VCVRack/AudibleInstruments/blob/a1cd335ec6ac44e8be55891854015bf0763f8552/src/Tides.cpp#L160

From:

outputs[HIGH_OUTPUT].setVoltage(sample.flags & tides::FLAG_END_OF_ATTACK ? 0.0 : 5.0);
outputs[LOW_OUTPUT].setVoltage(sample.flags & tides::FLAG_END_OF_RELEASE ? 0.0 : 5.0);

To:

outputs[HIGH_OUTPUT].setVoltage(sample.flags & tides::FLAG_END_OF_ATTACK ? 5.0 : 0.0);
outputs[LOW_OUTPUT].setVoltage(sample.flags & tides::FLAG_END_OF_RELEASE ? 5.0 : 0.0);