We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b6c2eaf commit 8b9ac36Copy full SHA for 8b9ac36
main.js
@@ -46,6 +46,15 @@ const rotate =()=>{
46
window.onload = () => {
47
canvas =document.getElementById('canvas1');
48
ctx = canvas.getContext('2d');
49
+ devicePixelRatio = window.devicePixelRatio || 1;
50
+
51
+ canvas.width = window.innerWidth * devicePixelRatio;
52
+ canvas.height = window.innerHeight * devicePixelRatio;
53
54
+ canvas.style.width = window.innerWidth + "px";
55
+ canvas.style.height = window.innerHeight + "px";
56
57
+ ctx.scale(devicePixelRatio, devicePixelRatio);
58
59
60
resetParamValues();
0 commit comments