We will learn how to capture a webcam stream in a <video>
tag with WebRTC and, if you are still there, draw images from this stream with the <canvas>
tag.
Catpure the webcam stream:
<video>
tag.<video>
tag in autoplay.<video>
tag with the captured webcam stream.<video>
tag width and height to 320x240.[OPTIONAL] Take screenshots from your webcam stream:
<button>
. When a user clicks on it, it should take a screenshot of the webcam stream:
<canvas>
context to draw an image from the <video>
.Navigator.getUserMedia()
API (since Chrome 21, Opera 18, and Firefox 17)Less than 2 hour
Less than 100
In the documentation, look for: