I'm making a simply camera web app with filters like Snapchat. I'd like download canvas and I'm using following code but image is mirrore because i'm using front camera. Is there a way to flip it before download? Thanks for reply
var c = document.getElementById("mycanvas");
var ctx = c.getContext("2d");
ctx.beginPath();
ctx.arc(100, 75, 50, 0, 2 * Math.PI);
ctx.stroke();
function download_image() {
var canvas = document.getElementById("jeeFaceFilterCanvas");
image = canvas.toDataURL("image/png").replace("image/png", "image/octet-stream");
var link = document.createElement('a');
link.download = "my-image.png";
link.href = image;
link.click();
}