HTMLMediaElement: captureStream() method
Limited availability
This feature is not Baseline because it does not work in some of the most widely-used browsers.
The captureStream()
method of the HTMLMediaElement
interface returns a MediaStream
object which is streaming a real-time capture of the content being rendered in the media element.
This can be used, for example, as a source for a WebRTC