I want to save canvas as local image file, I have see HTML5 Canvas to PNG File, and try:
<a id="dl" download="Canvas.png">Download Canvas</a>
<script>
function dlCanvas() {
var dt = canvas.toDataURL('image/png');
this.href = dt.replace(/^data:image\/[^;]/, 'data:application/octet-stream');
};
dl.addEventListener('click', dlCanvas, false);
</script>
but in chrome, the browser never open the file dialog and let me choose where to save, but I want to choose a directory, how should I do.