This sketch demonstrates how to use the enableEffect(int) method of an Effectable class.
The class used here is AudioPlayer, but you can also enable effects on AudioInput,
AudioOutput, and AudioSample objects. Effects added to an Effectable are
stored in the order they are added. They are indexed starting from zero. So if you want to enable the third
effect in the chain you'd call enableEffect(2). This sketch adds four low pass filters to
the player and disables them all. You can then enable them in any order by pressing '1', '2', '3', and '4'.
If you want to hear the sound change with each enable, then enable them in order, 1 - 4.
Enabling an effect means it will be included in effect processing when the Effectable
you added it to processes a buffer of samples.
Source code: enableEffectByIndex waveform
Built with Processing