Skip to content

Demo

In the demo below, pointerdown or keydown events triggers and holds the envelope. On the left side you see a typical binary on / off response, on the right you see a gradual effect of the envelope.

Releasing the pointer or key calls the envelope’s release function.

This next example is the same, but now retrigger is disabled, so pressing again while it’s decaying will continue the envelope at that level, rather than resetting to zero (default behaviour).