Tiles
How do I make an tiles?
What is a tiles? How do you make a tiles? This script and codes were developed by Pogany on 09 November 2022, Wednesday.
Tiles - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>tiles</title> <link rel="stylesheet" href="css/style.css">
</head>
<body> <canvas id="canvas"></canvas> <script src="js/index.js"></script>
</body>
</html>
Tiles - Script Codes CSS Codes
body { background-color: #222; overflow: hidden; margin:0; padding:0;
}
canvas { background-color: #000;
}
Tiles - Script Codes JS Codes
var canvas = document.getElementById("canvas");
var ctx = canvas.getContext("2d");
var cw = canvas.width = window.innerWidth, cx = cw / 2;
var ch = canvas.height = window.innerHeight, cy = ch / 2;
ctx.strokeStyle = "#fff";
var rad = Math.PI / 180;
var step = 30;//cw/25;
var frames = 0;
function grad(h){
for( var y = 0; y < ch;y+=step){
for( var x = 0; x < cw; x+=step){ var hyp = Math.sqrt( cw*cw + ch*ch); var xy = Math.sqrt( x*x + y*y); var hue = map(xy, 0,hyp, 180, 240) + randomIntFromInterval(-5, +5); ctx.fillStyle = "hsl("+hue+", 100%,50%)"; ctx.fillRect(x,y,step,step);
}
}
}
grad(180)
function Draw() {
requestId = window.requestAnimationFrame(Draw);
//ctx.clearRect(0,0,cw,ch); frames+=.1; grad(frames)
}
//Draw();
function map(n, a, b, _a, _b) { var d = b - a; var _d = _b - _a; var u = _d / d; return _a + n * u;
}
function randomIntFromInterval(mn, mx) { return ~~(Math.random() * (mx - mn + 1) + mn);
}
Developer | Pogany |
Username | giaco |
Uploaded | November 09, 2022 |
Rating | 3 |
Size | 2,018 Kb |
Views | 12,144 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
Basket | 2,297 Kb |
Circles | 2,621 Kb |
Swim Smooth | 2,897 Kb |
Helianthus | 1,995 Kb |
Mountains | 2,389 Kb |
Out of the blue | 2,537 Kb |
Tiles nr.2 | 2,030 Kb |
Fuzzies | 2,338 Kb |
Matrix Falling Code | 52,476 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
CSS eye follow | Pedrocampos | 2,592 Kb |
C.Rowe Button | Brownerd | 2,473 Kb |
Parallax.js | Zmeeey5 | 2,330 Kb |
Cloud upload | Jaflo | 2,774 Kb |
Webkit decolorize | Fivera | 1,675 Kb |
The Monty Hall Problem | Melatonind | 4,360 Kb |
CSS Grid Test | Ajaykarwal | 2,377 Kb |
Scroll effect with text with help from Skrollr | Luxonglassing | 2,935 Kb |
Button Option Group | Honchoman | 1,859 Kb |
Experiments with Vertical Centering | KatieK2 | 3,924 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!