├── readme.md ├── 3-createImageBitmap.html ├── firstDraft.html ├── 1-canvas.html ├── pushFramesAttempt.html ├── 6-writableCreateImageBitmap.html ├── 5-readable.html ├── 2-OffscreenCanvas.html └── 4-ImageCapture.html /readme.md: -------------------------------------------------------------------------------- 1 | Exploration of the various ways one can capture and save a still image from a webcam on the Web with JavaScript. 2 | This includes: 3 | 4 | * `canvas.toBlob()` 5 | * `OffscreenCanvas` 6 | * `createImageBitmap` 7 | * `ImageCapture` 8 | * `MediaStreamTrackProcessor` with `ReadableStreams` 9 | 10 | See the post on webrtcHacks for full details: https://webrtchacks.com/still-image-from-webcam-stream-approaches/ 11 | -------------------------------------------------------------------------------- /3-createImageBitmap.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 |17 | Images captured: 0 18 |
19 |13 | Images captured: 0 14 |
15 |17 | Images captured: 0 18 |
19 |13 | Images captured: 0 14 |
15 |13 | Images captured: 0 14 |
15 |19 | Images captured: 0 20 |
21 |19 | Images captured: 0 20 |
21 |Camera Settings
19 | 20 |Camera capabilities
21 | 22 |25 | Images captured: 0 26 |
27 |