offsetHeight fix

This commit is contained in:
awesomeuser 2023-08-04 15:25:26 +00:00
parent ad0130e1de
commit 3d12db5096

View file

@ -134,7 +134,7 @@
function draw(e) {
var posX = e.offsetX * canvas.width / canvas.offsetWidth - 1;
var posY = e.offsetY * canvas.height / canvas.offsetWidth - 1;
var posY = e.offsetY * canvas.height / canvas.offsetHeight - 1;
ctx.putImageData(pen, posX, posY);
}