WaveShaperNode Class
A node that applies a non-linear distortion curve to its input (https://webaudio.github.io/web-audio-api/#WaveShaperNode).
public sealed class WaveShaperNode : AudioNode- Inheritance
AudioNodeWaveShaperNode
Constructors
| Name | Description |
|---|---|
| WaveShaperNode(BaseAudioContext, WaveShaperOptions?) | Creates a wave shaper. |
WaveShaperNode(BaseAudioContext, WaveShaperOptions?)
WaveShaperNode.csCreates a wave shaper.
public WaveShaperNode(BaseAudioContext context, WaveShaperOptions? options = null)Parameters
contextBaseAudioContextoptionsWaveShaperOptions?
Exceptions
DomException- The curve has less than 2 values (an
InvalidStateError).
See also
Properties
| Name | Description |
|---|---|
| Curve | Gets or sets the shaping curve (a copy): the input from -1 to 1 is mapped to the values, linearly interpolated. |
| CurveArray | Gets or sets the Float32Array of the curve for the scripts: use WaveShaperNode.Curve in .NET code. |
| Oversample | Gets or sets the oversampling. |
Curve
WaveShaperNode.csGets or sets the shaping curve (a copy): the input from -1 to 1 is mapped to the values, linearly interpolated.
public IReadOnlyList<float>? Curve { get; set; }Property value
Exceptions
DomException- The curve has less than 2 values, or a curve was already set (an
InvalidStateError).
CurveArray
WaveShaperNode.csGets or sets the Float32Array of the curve for the scripts: use WaveShaperNode.Curve in .NET code.
public object? CurveArray { get; set; }Property value
Exceptions
DomException- The curve has less than 2 values, or a curve was already set (an
InvalidStateError).