public class EnvelopeFollower extends UGen
UGen.InputType, UGen.UGenInput
Modifier and Type | Field and Description |
---|---|
UGen.UGenInput |
audio
Where incoming audio is patched.
|
Constructor and Description |
---|
EnvelopeFollower(float attackInSeconds,
float releaseInSeconds,
int bufferSize)
Construct an EnvelopeFollower.
|
Modifier and Type | Method and Description |
---|---|
protected void |
sampleRateChanged()
Override this method in your derived class to receive a notification when
the sample rate of your UGen has changed.
|
protected void |
uGenerate(float[] out)
Implement this method when you extend UGen.
|
addAudio, addControl, addControl, addInput, channelCount, channelCountChanged, getLastValues, patch, patch, patch, printInputs, removeInput, sampleRate, setChannelCount, setSampleRate, tick, unpatch, unpatch
public UGen.UGenInput audio
public EnvelopeFollower(float attackInSeconds, float releaseInSeconds, int bufferSize)
attackInSeconds
- float: how many seconds the follower should take to ramp up to a higher valuereleaseInSeconds
- float: how many seconds the follower should take to ramp down to a lower valuebufferSize
- int: how many samples should be analyzed at once. smaller buffers will make
the follower more responsive.protected void sampleRateChanged()
UGen
sampleRateChanged
in class UGen
protected void uGenerate(float[] out)
UGen
getLastValues
method of your audio UGenInput to
retrieve the audio you want to modify, which you will then modify however
you need to, assigning the result to the values in channels
.