Questions on SynthVoice/Retriger

  1. Is there any way to define that voice was retriggered (i.e. note was released) in void ProcessSamplesAccumulating()? I just would like to have a different process in such a case.

  2. Just to note also that in IPlugIntrument example it seems that the Synthvoice is not killed (at least until MAX_ENV_TIME_MS) - so it creates some additional CPU overhead when handling polyphony. If so, then how to kill Synthvoice exactly right after the end of the note release?

Thanks for any clue.

I figured out myself. Everything is clear now. The bool GetBusy() was the key. So, I can eliminate using ADSREnvelope and can implement my note handling algo instead.

1 Like

It is working perfectly. Win/Mac VST/AU e tc.Amazing work, amazing library. Thanks, Oli.

1 Like

Would you mind describing how you ended up changing the function? I’m currently getting crackling/dropped samples when new notes are triggered while other voices are still in their release stage, so I checked the forum to see whether anyone else had tackled a similar issue. The fact that I don’t hear any distortion while simply playing multiple notes at once (only when playing several in succession with long release times) makes me think that it has to do with the envelope-voice interaction, but I haven’t yet figured out how that works, and perhaps you can shed some light on the matter.