public class Noise extends UGen
Modifier and Type | Class and Description |
---|---|
static class |
Noise.Tint
enumeration used to specify the tint of the noise
|
UGen.InputType, UGen.UGenInput
Modifier and Type | Field and Description |
---|---|
UGen.UGenInput |
amplitude
Patch to this to control the amplitude of the noise with another UGen.
|
UGen.UGenInput |
offset
Patch to this to offset the value of the noise by a fixed value.
|
Constructor and Description |
---|
Noise()
Constructor for white noise with an amplitude of 1.0.
|
Noise(float amplitude)
Constructor for white noise of the specified amplitude.
|
Noise(float amplitudeValue,
float offsetValue,
Noise.Tint noiseType)
Constructor for noise of a specific tint with a specified amplitude and offset.
|
Noise(float amplitudeValue,
Noise.Tint noiseType)
Constructor for noise of a specific tint with a specified amplitude.
|
Noise(Noise.Tint noiseType)
Constructor for noise of the specified tint with an amplitude of 1.0.
|
Modifier and Type | Method and Description |
---|---|
Noise.Tint |
getTint() |
protected void |
sampleRateChanged()
Override this method in your derived class to receive a notification when
the sample rate of your UGen has changed.
|
void |
setTint(Noise.Tint noiseType) |
protected void |
uGenerate(float[] channels)
Implement this method when you extend UGen.
|
addInput, getLastValues, patch, patch, patch, printInputs, removeInput, sampleRate, setAudioChannelCount, setSampleRate, tick, unpatch, unpatch
public UGen.UGenInput amplitude
public UGen.UGenInput offset
public Noise()
public Noise(float amplitude)
amplitude
- public Noise(Noise.Tint noiseType)
noiseType
- specifies the tint of the noise: WHITE, PINK, RED, BROWNpublic Noise(float amplitudeValue, Noise.Tint noiseType)
amplitudeValue
- noiseType
- specifies the tint of the noise: WHITE, PINK, RED, BROWNpublic Noise(float amplitudeValue, float offsetValue, Noise.Tint noiseType)
amplitudeValue
- offsetValue
- noiseType
- public void setTint(Noise.Tint noiseType)
public final Noise.Tint getTint()
protected void sampleRateChanged()
UGen
sampleRateChanged
in class UGen
protected void uGenerate(float[] channels)
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
.