Yes, that's right. This is because Envelope internally multiplies its shape with it's input. To get the behaviour you expect you'd write; Step unity => Envelope e; 1 => unity.next; This is a pattern I use fairly often. "unity" stands for "unity gain". Once you have a Step of that name you can re-use it elsewhere in your code. I find that quite handy. It's been discussed that perhaps this should be the default behaviour for Envelopes (including ADSR) that don't get a input, I'd be in favour of that and I seem to remember Perry also felt that way.
Okay, so in order to use an Envelope by itself (which is necessary in this case, as it is otherwise the first item in the chain), we need to give it an input to multiply, which is the purpose of the Step ugen. Is that correct?
What you are doing is wave-shaping the enveloped signal and instead you we'd like to wave-shape the envelope, then apply it to the signal. In this case we need a additional vca (Voltage Controlled Amplifier)
So; Step unity => Envelope e => Gen5 curve => Gain vca; //waveshaped envelope as a control voltage Noise my_signal => vca => dac; //signal to be enveloped 1 => unity.next; //unity gain to make the envelope behave 3 => vca.op; //set the vca to multiply
//set up your Gen5 here, your envelope, write music, etc. Aside from the trick with the Step it's all quite standard and straightforward stuff that you'd see in any kind of modular synth, but I can understand that this is a bit tricky if see it for the first time. It should be easier with a updated Envelope and ADSR, I think.
Ah, okay, I got close to this solution but I didn't know how to multiply signals. I hadn't seen 'op' in the documentation until you mentioned it and I went searching for it... I think the subject of connecting multiple chains using Gain in this way is something that the manual could elaborate upon.
I hope that helps and I hope there aren't too many bugs in it; I didn't try to run any of this ;-)
I'll let you know how it goes. I'm on lunch break at work right now, but I'll try it out when I get home in a few hours. -Alex