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
AudioNode WaveShaperNode

Constructors

NameDescription
WaveShaperNode(BaseAudioContext, WaveShaperOptions?)Creates a wave shaper.

WaveShaperNode(BaseAudioContext, WaveShaperOptions?)

WaveShaperNode.cs

Creates a wave shaper.

public WaveShaperNode(BaseAudioContext context, WaveShaperOptions? options = null)

Parameters

context BaseAudioContext
options WaveShaperOptions?

Exceptions

DomException
The curve has less than 2 values (an InvalidStateError).

See also

Properties

NameDescription
CurveGets or sets the shaping curve (a copy): the input from -1 to 1 is mapped to the values, linearly interpolated.
CurveArrayGets or sets the Float32Array of the curve for the scripts: use WaveShaperNode.Curve in .NET code.
OversampleGets or sets the oversampling.

Gets 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

IReadOnlyList<float>?

Exceptions

DomException
The curve has less than 2 values, or a curve was already set (an InvalidStateError).

Gets or sets the Float32Array of the curve for the scripts: use WaveShaperNode.Curve in .NET code.

public object? CurveArray { get; set; }

Property value

object?

Exceptions

DomException
The curve has less than 2 values, or a curve was already set (an InvalidStateError).

See also

Gets or sets the oversampling.

public OverSampleType Oversample { get; set; }