Good morning, If you could give me a hand. my problem is this:
I have an app that integrates the webcam and the photographs taken with it have to be downloaded to the computer and I'm a little lost at this point ... I already have the script that takes the picture ... is the following:
function takepicture() {
canvas.width = width;
canvas.height = height;
canvas.getContext('2d').drawImage(video, 0, 0, width, height);
var data = canvas.toDataURL('image/png');
photo.setAttribute('src', data);
}
startbutton.addEventListener('click', function(ev){
takepicture();
ev.preventDefault();
}, false);
})();
I just need to be able to download it ... And thanks in advance ..