MediaElementAudioSourceNode Class
A source whose output is the audio of a media element (https://webaudio.github.io/web-audio-api/#MediaElementAudioSourceNode): the audio of the element is no longer played by the element itself. The media backend of the library does not give the decoded audio of the media resources: the output is silence.
public sealed class MediaElementAudioSourceNode : AudioNode- Inheritance
AudioNodeMediaElementAudioSourceNode
Constructors
| Name | Description |
|---|---|
| MediaElementAudioSourceNode(AudioContext, MediaElementAudioSourceOptions) | Creates a source of the audio of a media element. |
MediaElementAudioSourceNode(AudioContext, MediaElementAudioSourceOptions)
MediaStreamAudioNodes.csCreates a source of the audio of a media element.
public MediaElementAudioSourceNode(AudioContext context, MediaElementAudioSourceOptions options)Parameters
contextAudioContext- The context.
optionsMediaElementAudioSourceOptions- The options, with the media element.
Exceptions
DomException- An
InvalidStateError: the element is already the source of a node.
See also
Properties
| Name | Description |
|---|---|
| MediaElement | Gets the media element given to the constructor. |
MediaElement
MediaStreamAudioNodes.csGets the media element given to the constructor.
public HtmlMediaElement MediaElement { get; }