-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
165 lines (161 loc) · 7.69 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
157
158
159
160
161
162
163
164
165
<!DOCTYPE html>
<html lang="en" data-bs-theme="light">
<head>
<title>Mandelbrot</title>
<meta charset="UTF-8"/>
<meta name="description"
content="Mobile-friendely online Mandelbrot viewer with full-screen mode, pretty deep zoom and permalinks to bookmark or share."/>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="./style.css"/>
<link rel="icon" type="image/x-icon" href="favicon.ico">
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-QTDVGKLBCH"></script>
<!-- prettier-ignore -->
<script>
if (window.location.hostname !== 'localhost') {
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
gtag('config', 'G-QTDVGKLBCH', {
'send_page_view': false // Disable automatic page view tracking
});
}
</script>
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet"
integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
</head>
<body id="app">
<div id="main">
<div id="descripion" hidden>Mobile-friendely online Mandelbrot viewer with full-screen mode, pretty deep zoom and permalinks to bookmark or share.</div>
<div id="mandelbrot">
<canvas id="mandelbrot-canvas"></canvas>
<canvas id="progress-canvas" width="20" height="20"></canvas>
<button id="menu-toggle"></button>
<textarea id="debug" readonly hidden></textarea>
<label for="debug" hidden>Debug</label>
<canvas id="palette-canvas" hidden></canvas>
</div>
<div id="settings">
<div class="container container-sm">
<div class="mb-2 mt-3 row">
<label for="max-iterations" class="col-form-label col col-sm-6">Max iterations</label>
<div class="col col-sm-6">
<input id="max-iterations" type="number" class="form-control form-control-sm" value="1000"
step="100" title="+/-"/>
</div>
</div>
<div class="mb-2 g-1 row">
<div class="col col-sm-6 form-check form-switch" data-bs-toggle="tooltip" data-bs-placement="left" title="Smooth coloring">
<input id="smooth" class="form-check-input" type="checkbox" role="switch"/>
<label for="smooth" class="form-check-label">Smooth</label>
</div>
<div class="col col-sm-6 form-check form-switch" data-bs-toggle="tooltip" data-bs-placement="left" title="Use physical pixels if different from display-pixels">
<input id="fullres" class="form-check-input" type="checkbox" role="switch"/>
<label for="fullres" class="form-check-labels">Hi DPI</label>
</div>
</div>
<div class="mb-2 g-1 row">
<div class="col col-sm-6 form-check form-switch" data-bs-toggle="tooltip" data-bs-placement="left" title="Use WebGPU, experimental">
<input id="gpu" class="form-check-input" type="checkbox" role="switch"/>
<label for="gpu" class="form-check-labels">GPU (exp.)</label>
</div>
</div>
<div class="mb-2 g-1 row">
<div class="col col-sm-6">
<button class="btn btn-success form-control form-control-sm" id="fullscreen" title="f">Fullscreen
</button>
</div>
<div class="col col-sm-6">
<button class="btn btn-success form-control form-control-sm" id="reset" title="backspace">Reset
</button>
</div>
</div>
<div class="mb-2 g-1 row">
<div class="col col-sm-6">
<div class="dropdown">
<button id="palette-dropdown"
class="btn btn-success form-control form-control-sm dropdown-toggle" type="button"
data-bs-toggle="dropdown" aria-expanded="false">
Palette
</button>
<ul id="palette-menu" class="dropdown-menu">
<!-- filled by javascript -->
</ul>
</div>
</div>
<div class="col col-sm-6">
<button id="lucky-button" class="btn btn-success form-control form-control-sm" type="button">
I feel lucky
</button>
</div>
</div>
<div class="mb-2 g-1 row">
<div class="col col-sm-6">
<label id="palette-density-label" for="palette-density" class="form-label">Palette density</label>
<input id="palette-density" type="range" class="form-range" min="-25" max="25" step="1"
value="1"/>
</div>
<div class="col col-sm-6">
<label id="palette-rotate-label" for="palette-rotate" class="form-label">Palette rotation</label>
<input id="palette-rotate" type="range" class="form-range" min="-180" max="180" step="1"
value="0"/>
</div>
</div>
<div class="row collapse-ruler">
<div class="col">
<hr class="hr-advanced"/>
</div>
<button type="button" class="col-auto" data-bs-toggle="collapse"
data-bs-target="#infocollapse">Info
</button>
</div>
<div id="infocollapse" class="collapse">
<div>
<div class="mb-0 row">
<div class="col col-lg-3">
<label>Zoom</label>
</div>
<div class="col col-lg-3">
<span id="zoomValue"></span>
</div>
</div>
<div class="mb-0 row">
<div class="col col-lg-3">
<label>Size</label>
</div>
<div class="col col-lg-3">
<span id="sizeValue"></span>
</div>
</div>
<div class="mb-0 row">
<div class="col col-lg-3">
<label>Render time</label>
</div>
<div class="col col-lg-3">
<span id="renderTimeValue"></span>
</div>
</div>
<hr/>
</div>
</div>
<div id="footer" class="row">
<footer>
<a href="https://github.com/bertbaron/mandelbrot" target="_blank">
Sources
</a> |
<a href="https://github.com/bertbaron/mandelbrot/issues" target="_blank">
Issue Tracker
</a>
</footer>
</div>
</div>
</div>
<script type="module" src="./index.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js"
integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL"
crossorigin="anonymous"></script>
</div>
</body>
</html>