Created
September 16, 2022 08:57
-
-
Save balaam/884bab1383f92d8c0010101b8f6579dc to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script> | |
function isBitOn(number, index) { | |
return Boolean(number & (1 << index)); | |
} | |
window.onload = function() { | |
var canvas = document.getElementById('canvas'); | |
var ctx = canvas.getContext('2d'); | |
ctx.fillStyle = 'green'; | |
ctx.fillRect(20, 10, 150, 100); | |
} | |
</script> | |
</head> | |
<body> | |
<p>When the Apple II came out, a new mode had been added for 280×192 high-resolution graphics. 280*2 = 560, 192*2 = 384.</p> | |
<canvas id="canvas" width="560" height="384" style="border:1px solid #000000;"> | |
Your browser does not support the HTML canvas tag. | |
</canvas> | |
</body> | |
</html> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment