The MediaStreamTrackProcessor()
constructor creates a new MediaStreamTrackProcessor
object which consumes a MediaStreamTrack
object's source and generates a stream of media frames.
MediaStreamTrackProcessor.MediaStreamTrackProcessor()
Syntax
new MediaStreamTrackProcessor(init);
Parameters
-
options
-
An object with the following properties:
-
track
-
maxBufferSize
Optional -
An integer specifying the maximum number of media frames to be buffered.
-
Examples
In the following example a new MediaStreamTrackProcessor
is created.
const trackProcessor = new MediaStreamTrackProcessor({ track: videoTrack });
Specifications
No specification found
No specification data found for api.MediaStreamTrackProcessor.MediaStreamTrackProcessor
.
Check for problems with this page or contribute a missing spec_url
to mdn/browser-compat-data. Also make sure the specification is included in w3c/browser-specs.
Browser compatibility
Desktop | Mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | WebView Android | Chrome Android | Firefox for Android | Opera Android | Safari on IOS | Samsung Internet | |
MediaStreamTrackProcessor |
94
|
94
|
No
|
No
|
80
|
No
|
94
|
94
|
No
|
66
|
No
|
17.0
|
© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/MediaStreamTrackProcessor/MediaStreamTrackProcessor