What's wrong with this ? (very simple help)

chapelier fou's icon
Max Patch
Copy patch and select New From Clipboard in Max.

Hey,
i am currently trying, as a practice, to create several drum sounds abstractions. Here is a kick as a start. I want to add a quick fade out but it produces a click instead. I guess something is wrong with my understanding of line~, or with events order. (i never really worked with msp)
if someone would mind taking a quick look, i'd appreciate !

brendan mccloskey's icon
Max Patch
Copy patch and select New From Clipboard in Max.

Hi
your click resulted from the instantaneous leap to 1. So, I changed the message to (1. 5. 0. $1), and also the [prepend set] to allow variation of this value. I like the way you're generating the kick pitch envelope, using curve~ and cycle~ :)

Brendan

chapelier fou's icon

Thanks. i don't really get it.
My wish is to apply the fade out after a certain time, which explains the delay i was using.
Also could you explain what's the meaning of 1. 5. 0. $1 in the line~ ?

chapelier fou's icon

ok i get it, very fast fade in (5ms) and then goes to 0 in the defined time lapse.
I still find it weird and this doesn't fit with the idea of delaying the fade out...

brendan mccloskey's icon

Hi
you can see in my suggested solution that there is no need for a [delay] object; the event order is:

1. open the amplitude envelope
2. bang the kick sound
3. release time changed on next tick.

Max Patch
Copy patch and select New From Clipboard in Max.

If you want a variation on that algorithm - for example disconnecting the pitch release from the amplitude release - then try this:

I couldn't resist adding a beater-head click and the usual resonant filter and mild clipping :)

Brendan

chapelier fou's icon

Thank you ! it's sounds quite cool.
But don't get me wrong, your amplitude envelope is during the whole sound, not only in a decay phase. Im not sure it's noticeable, but my goal was to make a fade out only in the end of the kick. I'll sort it out.