-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathindex.html
155 lines (131 loc) · 4.44 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
<!-- (c)
Julius Peinelt
Anna Neovesky - Digitale Akademie, Akademie der Wissenschaften und der Literatur | Mainz - Anna.Neovesky@adwmainz.de -->
<!-- Container for panorama viewer; loads Libraries & code -->
<!DOCTYPE html>
<html lang="en">
<head>
<title>Virtual Tour</title>
<meta charset="utf-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1, minimum-scale=1.0, maximum-scale=1.0">
<link rel="stylesheet" href="style.css">
<script src="extLib/three.js"></script>
<!-- Application code-->
<script src="src/panorama.js"></script>
<script src="src/location.js"></script>
<script src="src/hotspot.js"></script>
<script src="src/transition.js"></script>
<!-- Libraries -->
<script src="src/lib/threex_fullscreen.js"></script>
<script src="src/lib/detector.js"></script>
<script src="src/lib/location_loader.js"></script>
<script src="src/lib/copy_shader.js"></script>
<script src="src/lib/effect_composer.js"></script>
<script src="src/lib/render_pass.js"></script>
<script src="src/lib/shader_pass.js"></script>
<script src="src/lib/mask_pass.js"></script>
<script src="src/lib/blur_shader.js"></script>
<!-- Initializes panoramic viewer-->
<script type="text/javascript">
window.onload = function () {
var isMobile = {
Android: function () {
return navigator.userAgent.match(/Android/i);
},
BlackBerry: function () {
return navigator.userAgent.match(/BlackBerry/i);
},
iOS: function () {
return navigator.userAgent.match(/iPhone|iPad|iPod/i);
},
Opera: function () {
return navigator.userAgent.match(/Opera Mini/i);
},
Windows: function () {
return navigator.userAgent.match(/IEMobile/i) || navigator.userAgent.match(/WPDesktop/i);
},
any: function () {
return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Opera() || isMobile.Windows());
}
};
<!-- Uses HQ images in desktop versions and lower quality if mobile -->
if (isMobile.any()) {
startPanorama('resources/json/sample.json', "mobile");
} else {
startPanorama('resources/json/sample.json', "hq");
}
}
</script>
</head>
<body>
<!-- Container for panorama-->
<div id="panorama">
<!-- Map image -->
<figure id="map">
<img id="mapImage" src="" alt="Map"/>
</figure>
<!-- Full screen -->
<figure id="fullscreen">
<img src="resources/icons/gui_fullscreen_icon.png" alt="Enter / Leave Fullscreen Mode"/>
</figure>
<!-- Scene switch: enables to create a tour with two connected spaces; remove comments to enable scene switch -->
<!--
<p id="sceneSwitch">
Switch Scene
</p> -->
<!-- Tool Tip; loaded from JSON -->
<p id="toolTip"></p>
<!-- Information pop-up -->
<article id="infoView">
<figure id="infoCloseButton">
<img src="resources/icons/close.png" alt="Close information pop-up"
title="Close information pop-up">
</figure>
<!-- Title; loaded from JSON-->
<h1 id="infoTitle">
</h1>
<!-- Image and image caption; loaded from JSON -->
<figure id="infoImageBox">
<img src="" alt="Image" id="infoImage"/>
<figcaption id="infoCaption">
</figcaption>
</figure>
<!-- Audio file; loaded from JSON -->
<div id="audioPlayer">
<audio id="audioControls" controls>
<source src="" type="audio/ogg" preload="auto" id="audioSourceOgg">
<source src="" type="audio/mpeg" preload="auto" id="audioSourceMp3">
</audio>
</div>
<!-- Textual information; loaded from JSON -->
<p id="infoContent">
</p>
</article>
</div>
<!-- Navigation bar and buttons -->
<div id="navigationButtonsContainer">
<figure id="nav">
<img src="resources/icons/navigation.png"/>
</figure>
<figure class="panoNavButton" id="upNavButton" src="resources/icons/navigation.png" alt="Navigation element">
<img src="resources/icons/gui_panup_icon.png" alt="Up"/>
</figure>
<figure class="panoNavButton" id="downNavButton">
<img src="resources/icons/gui_pandown_icon.png" alt="Down"/>
</figure>
<figure class="panoNavButton" id="leftNavButton">
<img src="resources/icons/gui_panleft_icon.png" alt="Left"/>
</figure>
<figure class="panoNavButton" id="rightNavButton">
<img src="resources/icons/gui_panright_icon.png" alt="Right"/>
</figure>
<figure class="panoNavButton" id="zoomInButton">
<img src="resources/icons/gui_zoomin_icon.png" alt="Zoom in"/>
</figure>
<figure class="panoNavButton" id="zoomOutButton">
<img src="resources/icons/gui_zoomout_icon.png" alt="Zoom out"/>
</figure>
</div>
</body>
</html>