Issue #720: Rework zero-amp termination - now only in release. Skip …#750
Conversation
…scs where amp[0] == 0. Change last_amp.
🎛️ AMYboard HW CIDispatched this PR's |
|
I tested this build against the previous version for the number of simultaneous Juno 1 voices that can be rendered on an RP2350 (4), and it's surely no worse than it was before. |
🎛️ HW CI (physical bench)Built from this AMY PR, pinned into the tulipcc AMYboard (USB-MIDI + AMY Tulip (TULIP4_R11; serial-REPL audio + WiFi screenshot): ✅ PASS — flashed this PR’s firmware; all checks matched the references. ⬇️ Artifacts: recordings · screenshot · serial logs · run logs Self-hosted bench. Audio spectral-compared to |
…oscs where amp[0] == 0. Change last_amp.
Issue #720 responded to a couple of instances where voices with very slow attacks were never being started because of some logic that rapidly terminates new oscs that don't appear to be emitting sound, in order to avoid wasted computation on Juno patches. Instead, we now skip rendering oscs whose
amp[CONST]==0(we already skipped them if theirmsynth.ampandmsynth.last_ampwere zero, but this is more aggressive and avoids runninghold_and_modify).In testing this, I noticed that some AM envelopes were very noisy because we had
msynth.last_amplogic that failed to linearly interpolate rising AM envelopes. I forget why I put this in, I think it was to do with voice-stealing clicks, but anyway I simplified it and most tests were unchanged. I listened to all the changed tests (with the newmake playfailed) and they all sounded OK.