-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
232 lines (215 loc) · 6.82 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
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Mendel Station model</title>
<meta
name="viewport"
content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0"
/>
<link rel="stylesheet" type="text/css" href="./Qgis2threejs.css" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Titillium+Web:ital,wght@0,400;0,600;0,700;1,400&display=swap"
rel="stylesheet"
/>
<script src="./threejs/three.min.js"></script>
<script src="./threejs/OrbitControls.js"></script>
<script src="./threejs/OutlineEffect.js"></script>
<script src="./proj4js/proj4.js"></script>
<script src="./Qgis2threejs.js"></script>
<script src="./threejs/loaders/GLTFLoader.js"></script>
<script src="overview_map.js"></script>
</head>
<body>
<div id="view">
<div id="labels"></div>
<div id="northarrow"></div>
<div id="navigation"></div>
</div>
<!-- popup -->
<div id="popup">
<div id="closebtn">×</div>
<div id="popupbar"></div>
<div id="popupbody">
<div id="popupcontent"></div>
<!-- query result -->
<div id="queryresult">
<table id="qr_layername_table">
<caption>
Layer name
</caption>
<tr>
<td id="qr_layername"></td>
</tr>
</table>
<!-- <table id="qr_coords_table">
<caption>Clicked coordinates</caption>
<tr><td id="qr_coords"></td></tr>
</table> -->
<!-- camera actions -->
<!-- <div class="action-btn action-zoom" onclick="app.cameraAction.zoomIn(); app.closePopup();">Zoom in here</div>
<div class="action-btn action-move" onclick="app.cameraAction.move(); app.closePopup();">Move here</div>
<div class="action-btn action-orbit" onclick="app.cameraAction.orbit(); app.closePopup();">Orbit around here</div> -->
<div id="action-btn-flex">
<div
class="action-btn action-zoom"
onclick="app.cameraAction.zoomIn(); "
>
Zoom in here
</div>
<div
class="action-btn action-move"
onclick="app.cameraAction.move(); "
>
Move here
</div>
<div
class="action-btn action-orbit"
onclick="app.cameraAction.orbit(); "
>
Orbit around here
</div>
</div>
<!-- attributes -->
<table id="qr_attrs_table">
<caption>
Attributes
</caption>
</table>
</div>
<!-- page info -->
<div id="pageinfo">
<h1>Current View URL</h1>
<div><input id="urlbox" type="text" /></div>
<h1>Usage</h1>
<table id="usage">
<tr>
<td colspan="2" class="star">Mouse</td>
</tr>
<tr>
<td>Left button + Move</td>
<td>Orbit</td>
</tr>
<tr>
<td>Mouse Wheel</td>
<td>Zoom</td>
</tr>
<tr>
<td>Right button + Move</td>
<td>Pan</td>
</tr>
<tr>
<td colspan="2" class="star">Keys</td>
</tr>
<tr>
<td>Arrow keys</td>
<td>Move Horizontally</td>
</tr>
<tr>
<td>Shift + Arrow keys</td>
<td>Orbit</td>
</tr>
<tr>
<td>Ctrl + Arrow keys</td>
<td>Rotate</td>
</tr>
<tr>
<td>Shift + Ctrl + Up / Down</td>
<td>Zoom In / Out</td>
</tr>
<tr>
<td>L</td>
<td>Toggle Label Visibility</td>
</tr>
<tr>
<td>R</td>
<td>Start / Stop Orbit Animation</td>
</tr>
<tr>
<td>W</td>
<td>Wireframe Mode</td>
</tr>
<tr>
<td>Shift + R</td>
<td>Reset Camera Position</td>
</tr>
<tr>
<td>Shift + S</td>
<td>Save Image</td>
</tr>
</table>
<h1>About</h1>
<div id="about">
This page was made with
<a href="https://www.qgis.org/" target="_blank">QGIS</a> and
<a href="https://github.com/minorua/Qgis2threejs" target="_blank"
>Qgis2threejs</a
>
plugin (version 2.6).
<div>
Powered by
<a href="https://threejs.org/" target="_blank">three.js</a>
<span id="lib_proj4js">
and
<a href="https://trac.osgeo.org/proj4js/" target="_blank"
>Proj4js</a
></span
>.
</div>
</div>
</div>
</div>
</div>
<!-- progress bar -->
<div id="progress"><div id="bar"></div></div>
<!-- header and footer -->
<div id="header">POLAR STATION OF G. J. MENDEL</div>
<div id="overview">
<div id="toggle_overview" onclick="">Overview map</div>
<img id="overview_map" src="mendel_global.svg" alt="inset_map" />
</div>
<div id="footer">
Horák J., Hološ D. (2022): Polar station of G. J. Mendel, Masaryk university, Brno <br />
EPSG: 32721; Source: Masaryk university, Primini P. (2019): Turbine, CC BY
4.0, shorturl.at/dfqAR
</div>
<span id="infobtn"><img src="./Qgis2threejs.png" /></span>
<script>
Q3D.Config.allVisible = true;
Q3D.Config.coord.latlon = true;
Q3D.Config.viewpoint = {
lookAt: {
x: -0.4835881503883996,
y: 3.844703533317586,
z: 7.810962717104624e-18,
},
pos: {
x: -33.19175510804489,
y: 24.44359841556663,
z: 14.526291701056852,
},
};
Q3D.Config.northArrow.visible = true;
Q3D.Config.northArrow.color = 0x2c93f4;
if (typeof proj4 === "undefined")
document.getElementById("lib_proj4js").style.display = "none";
var container = document.getElementById("view"),
app = Q3D.application;
app.init(container); // initialize viewer
// load the scene
app.loadSceneFile(
"./data/index/scene.json",
function (scene) {
// scene file has been loaded
app.start();
},
function (scene) {
// all relevant files have been loaded
}
);
document.getElementById("infobtn").onclick = app.showInfo;
</script>
</body>
</html>