ADSR example

Hi,

I’m trying to figure out how to do a midi CC ADSR generator.
I read everything I could find about it, i.e posts over here, GigPerformerScriptingDraftV0_51,
Index to all GPScript built-in functions as of 12:30PM on February 15, 2019, etc.

I couldn’t find a simple example (it may pretty well be not that simple at all though…)
at a starting point for an ADSR generator script.
While searching for a solution, I also tried out to implement the Ramp generator, but with pretty mitigate success.
That said, what I’m really looking for is an ADSR starting point script.

Any help would be greatly appreciated.

Best,

N

What do you want to have?
A fade in or fade out of a volume widget?

Hi and thank you for the reply.

What I’m trying to achieve is making an ADSR, that every time a note is played, modulate e.g. CC11, just like a synth enveloppe.
With attack, sustain, and release time.
Level point would dictate the modulation (CC value) amount.

Hope all this make sense.

N

edit: Any example using ADSR that would modulate, e.g. a Widget, would be an extraordinary starting point.

If you want full flexibility about curves and sending midi messages you should take a look at this:
https://www.cableguys.com/midishaper.html

Yeah, the ADSR and other function generators are experimental and while they do work, turns out that that midishaper really does the job properly so I even use that plugin now.

Thank you for remembering me about this one.
I tried it a while ago with Logic and the IAC awkward set-up discourage me to go for it.
Still v’got this “Audio Unit midi effect” reflex, so to speak, so I didn’t look back to it till now.
With the option to use it within GP, I just downloaded the demo and it seems really promising so far.

That said, if someone at some point is disposed to post a script using the ADSR generator, I’d be really graceful.

Thanks again pianopaul!

I wrote this a long time ago to test the ADSR stuff — no idea if it still works but feel free to try it (note - unsupported, sorry)

ADSRTest.gig (33.0 KB)

Hi dhj and thank you very much, I’ll defenitely have a look at it.

You beat me up, I was answering pianopaul.

Best to you all!

Edit: Just tried the script and it seems to do exactly what I was looking for.
I’ll need some times to figure that out and learn from it.
I’m no way to the same level that you guys are.

You really’v made my day!!!

Hi,

Its going well so far with the script.
I was able to modulate plugin’s parameters as expected.
Here’s the thing I wasn’t able to accomplish though.
Send the value generated by the script (which I was able to send to the plugin’s parameter using the mapping), to MIDI CC.
I.e., I need to send the value (script generated) to, e.g., Channel 1, CC number 2, and the value : ( x).
Hope this makes sense.
I’ll continue to search, but at this point I couldn’t find/figure how to do this!

Best,

N

edit: I decided to go with the Cableguys’s MidiShaper + Gig Performer script solution.
What I’v learned while digging the ADSR script option will be of great use to get exactly what I’m looking for.

Thanks again for the help!

N