[Sustain] object not working like real piano pedal

Lennard's icon

Hello,

I want to use a midi keyboard and a midi sustain pedal to play a synth. I wan't to manage the sustain inside of max, so that note on and note off messages are sent to the synth (and not the sustain pedal itself).

For that the [sustain @repeatmode 1] object is almost perfect. BUT if I play a note, activate the sustain, play that note again (retrigger it) and then release the sustain, that note is turned off. Even though I am still pressing it down on my midi keyboard. On a real piano that note would continue to sound, because I am still holding the key down. And not release/ stop sounding just because I deactivated the sustain pedal.

Any help with this would be greatly appreciated, I tried for many hours now to make that work, but I wasn't able to do it.

Greetings, Lennard

Source Audio's icon

you need repeatmode 2.

if no mode of sustain object fits your idea,

then you need to build own sustain

using coll and other things.

Lennard's icon

Thank you very much!

I didn't see repeatmode 2 in the help files (I had to scroll to the side...). By default it didn't do what I want, but by putting a sustain repeatmode 1 after it I got exactly what I wanted!