CanvasCaptureMediaStreamTrack
The CanvasCaptureMediaStreamTrack
interface of the Media Capture and Streams API represents the video track contained in a MediaStream being generated from a canvas following a call to HTMLCanvasElement.captureStream().
Properties
The canvas
read-only property of the CanvasCaptureMediaStreamTrack interface returns the HTMLCanvasElement from which frames are being captured.
The contentHint
property of the MediaStreamTrack interface is a string that hints at the type of content the track contains.
The readyState
read-only property of the MediaStreamTrack interface returns an enumerated value giving the status of the track.
Functions
The applyConstraints()
method of the MediaStreamTrack interface applies a set of constraints to the track; these constraints let the website or app establish ideal values and acceptable ranges of values for the constrainable properties of the track, such as frame rate, dimensions, echo cancellation, and so forth.
The applyConstraints()
method of the MediaStreamTrack interface applies a set of constraints to the track; these constraints let the website or app establish ideal values and acceptable ranges of values for the constrainable properties of the track, such as frame rate, dimensions, echo cancellation, and so forth.
The clone()
method of the MediaStreamTrack interface creates a duplicate of the MediaStreamTrack
.
The getCapabilities()
method of the MediaStreamTrack interface returns an object detailing the accepted values or value range for each constrainable property of the associated MediaStreamTrack
, based upon the platform and user agent.
The getConstraints()
method of the MediaStreamTrack interface returns a MediaTrackConstraints object containing the set of constraints most recently established for the track using a prior call to MediaStreamTrack.applyConstraints.
The getSettings()
method of the MediaStreamTrack interface returns a MediaTrackSettings object containing the current values of each of the constrainable properties for the current MediaStreamTrack
.
The requestFrame()
method of the CanvasCaptureMediaStreamTrack interface requests that a frame be captured from the canvas and sent to the stream.