-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathindex.html
156 lines (141 loc) · 4.99 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Icon Machine</title>
<meta property="og:title" content="Icon Machine">
<meta property="og:url" content="https://www.brianmacintosh.com/iconmachine/">
<meta property="og:site_name" content="Games by Brian MacIntosh">
<meta property="og:type" content="website">
<meta property="og:image" content="https://brianmacintosh.com/iconmachine/og_icon.png">
<meta property="og:description" content="Generate random pixel art icons online.">
<meta name="keywords" content="random, icon, pixel art, art, game art, procedural, generator">
<meta name="description" content="Generate random pixel art icons online.">
<link rel="image_src" href="https://brianmacintosh.com/iconmachine/og_icon.png">
<link rel="canonical" href="https://www.brianmacintosh.com/iconmachine/">
<link rel="author" href="https://twitter.com/BrianAMacIntosh">
<link rel="shortcut icon" href="favicon.ico" type="image/x-icon">
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "WebApplication",
"name": "Icon Machine",
"operatingSystem": "Web Browser",
"applicationCategory": "https://schema.org/DeveloperApplication",
"offers": {
"@type": "Offer",
"price": "0",
"priceCurrency": "USD"
}
}
</script>
<style>
body{
font-family: Verdana, Geneva, Tahoma, sans-serif;
width: 100%;
height: 100%;
margin: 0;
text-align: center;
}
#homediv{
position: absolute;
right: 30px;
top: 30px;
}
#title{
display: block;
font-size: large;
font-weight: bold;
margin-top: 4em;
}
#text{
display: block;
margin: 0 10%;
}
#generatorCanvas{
display: block;
margin: 20px 0 8px 0;
}
#generatorCanvas canvas{
-ms-interpolation-mode: nearest-neighbor;
image-rendering: -webkit-optimize-contrast;
image-rendering: -webkit-crisp-edges;
image-rendering: -moz-crisp-edges;
image-rendering: -o-crisp-edges;
image-rendering: pixelated;
transform: scale(2);
}
#paramsTable{margin:0 auto;}
.paramLabel{text-align:right;}
.paramValue{text-align:left;}
#generatorSeed{
margin-top:25px;
margin-bottom:5px;
}
#generatorParams{
display: block;
margin: 20px;
}
#shareButton{
display:inline;
vertical-align:middle;
}
#ad{
display: block;
margin-top: 4em;
}
</style>
</head>
<body>
<div id="homediv"><a href="/" target="_blank"><img src="/media/title_penguin.png" height="64" alt="Penguin in a TV"></a></div>
<header role="banner">
<div id="title">Icon Machine</div>
</header>
<main role="main">
<br>
<div>
<label for="iconClass">Display Scale:</label> <select id="displayScale" onchange="RandomArt.notifyDisplayScaleChanged()">
<option value="1">100%</option>
<option value="2" selected>200%</option>
</select>
</div>
<div id="generatorCanvas"><canvas id="generator" width="32" height="32"></canvas></div>
<div id="restoreConfigPreZoomButton"><a href="javascript:RandomArt.restoreConfigPreZoom()" title="Go Back"><img id="revertButton" src="ico_expand.png" alt="Revert"></a></div>
<div id="generatorParams">
<table id="paramsTable">
<tr><td class="paramLabel"><label for="dimension">Size:</label></td><td class="paramValue"><select id="dimension" onchange="RandomArt.notifySizeChanged()">
<option value="16">16 px</option>
<option value="32" selected>32 px</option>
<!--option value="64">64 px</option-->
</select></td></tr>
<tr><td class="paramLabel"><label for="tileDimension">Qty:</label></td><td class="paramValue"><select id="tileDimension" onchange="RandomArt.notifyTileDimensionChanged()">
<option value="1" selected>1</option>
<option value="2">2x2</option>
<option value="4">4x4</option>
<option value="8">8x8</option>
</select></td></tr>
<tr><td class="paramLabel"><label for="iconClass">Mode:</label></td><td class="paramValue"><select id="iconClass" onchange="RandomArt.notifyIconClassChanged()">
<option value="potions">Potions</option>
<option value="blades">Blades</option>
<option value="spears">Spears</option>
<!--option value="any">[Any]</option-->
<option value="anyweapon" selected>[Any Weapon]</option>
</select></td></tr>
</table>
<div id="generatorSeed">
<label for="seed">Seed:</label> <input id="seed" type="text" oninput="RandomArt.notifySeedChanged()" onchange="RandomArt.notifySeedChanged()">
<div id="shareButton"><a id="shareLink" title="Shareable link to this image"><img src="ico_link.png" alt="Share"></a></div>
</div>
<button onclick="RandomArt.randomizeSeed(); return false;">Randomize</button>
</div>
<div id="text">
<p>It generates random pixel art icons for potions or bladed weapons.</p>
<p>Icons generated by this page are licensed as <a href="https://creativecommons.org/publicdomain/zero/1.0/" target="_blank" rel="noopener">CC0</a>. You can download an icon or sheet by right-clicking on it.</p>
<p><a href="https://github.com/BrianMacIntosh/icon-machine"><img src="/media/github.png" alt="Github"><br>Source</a></p>
</div>
</main>
<script src="random.js?2"></script>
<script>RandomArt.generateNewImage()</script>
</body>
</html>