Automattic / Automattic/node-canvas
Add `captureStream()` method
- Dominant language
- JavaScript
- Stars
- 10.7k
- Forks
- 1.2k
- Avg merge
- 4d 8h
- Merged PRs (30d)
- 1
Description
Add missing [captureStream](https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/captureStream) Canvas method. It returns a `MediaStream` object, where on each canvas change a new frame is being added with the actual canvas contest. This is similar to using `node-webrtc` [RTCVideoSource](https://github.com/node-webrtc/node-webrtc/blob/develop/docs/nonstandard-apis.md#rtcvideosource) class and calling to its `onFrame()` method, so probably some code could be reused between both projects. A polyfill can also be created to add that feature, but it would need first to have merged my changes to [notify paint operations](https://github.com/Automattic/node-canvas/pull/1543).
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.