-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
155 lines (140 loc) · 6.06 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
<!DOCTYPE html>
<html lang="pt-br" itemscope itemtype="https://schema.org/MediaObject">
<head>
<!-- Google Tag Manager -->
<script>(function (w, d, s, l, i) {
w[l] = w[l] || []; w[l].push({
'gtm.start':
new Date().getTime(), event: 'gtm.js'
}); var f = d.getElementsByTagName(s)[0],
j = d.createElement(s), dl = l != 'dataLayer' ? '&l=' + l : ''; j.async = true; j.src =
'https://www.googletagmanager.com/gtm.js?id=' + i + dl; f.parentNode.insertBefore(j, f);
})(window, document, 'script', 'dataLayer', 'GTM-W2Z3NC9');</script>
<!-- End Google Tag Manager -->
<!-- ***CAMPOS EDIÇÃO OBRIGATÓRIA-->
<title>New Town-Tour Decorado 3Q</title>
<!-- Ex.: Edifício ....-->
<meta property="og:title" content="New Town-Tour Decorado 3Q">
<!-- Ex.: Edifício ....-->
<meta itemprop="name" content="New Town-Tour Decorado 3Q">
<meta name="description" content="Panorama do projeto XXX contendo radar, mapa, e X pontos.">
<meta property="og:description" content="Panorama do projeto XXX contendo radar, mapa, e X pontos.">
<meta itemprop="description" content="Panorama do projeto XXX contendo radar, mapa, e X pontos.">
<meta property="og:url" content="http://pipe3d.com.br/tour360/.........">
<!-- **COMPLETAR***-->
<meta property="og:image" content="PREVIEW IMAGE URL">
<!-- ***1200x630***-->
<meta itemprop="image" content="http://www.example.com/image.jpg">
<!-- ***ITENS COMUNS A TODOS PANORAMAS-->
<meta property="fb:admins" content="100000252753668">
<meta property="og:site_name" content="Pipe Studio">
<meta property="og:type" content="article">
<link rel="shortcut icon" href="../../favicon.ico">
<meta charset="utf-8">
<meta name="viewport" content="target-densitydpi=device-dpi, width=device-width, initial-scale=1.0, minimum-scale=1.0,
maximum-scale=1.0, minimal-ui">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<meta http-equiv="x-ua-compatible" content="IE=edge ">
<meta name="author" content="Pipe Studio">
<meta property="article:author" content="https://www.facebook.com/PipeStudio">
<!--CSS -->
<link href="https://fonts.googleapis.com/css?family=Roboto:regular,bold,italic,thin,light,bolditalic,black,medium&lang=en"
rel="stylesheet">
<style>
@-ms-viewport {
width: device-width;
}
@media only screen and (min-device-width:800px) {
html {
overflow: hidden;
}
}
html {
height: 100%;
}
body {
height: 100%;
overflow: hidden;
margin: 0;
padding: 0;
font-family: Roboto, Helvetica, sans-serif;
font-size: 16px;
color: #FFFFFF;
background-color: #000000;
}
</style>
</head>
<body>
<!-- Google Tag Manager (noscript) -->
<noscript>
<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-W2Z3NC9" height="0" width="0" style="display:none;visibility:hidden"></iframe>
</noscript>
<!-- End Google Tag Manager (noscript) -->
<script src="tour.js"></script>
<script src="//cdn.jsdelivr.net/pouchdb/5.4.5/pouchdb.min.js"></script>
<div id="pano" style="width:100%;height:100%;">
<noscript>
<table style="width:100%;height:100%;">
<tr style="vertical-align:middle;">
<td>
<div style="text-align:center;">ERROR:
<br/>
<br/>Javascript not activated
<br/>
<br/>
</div>
</td>
</tr>
</table>
</noscript>
<script>
var db = new PouchDB('scenes');
embedpano({ swf: "tour.swf",
xml: "tour.xml",
target: "pano",
html5: "prefer",
initvars: { design: "flat" },
passQueryParameters: true,
consolelog:true
});
//load pano on browser backbutton
window.onpopstate = function (event) {
var scene = event.state.scene;
var vars = "view.hlookat=" + event.state.view.hlookat;
vars += "&view.vlookat="+ event.state.view.vlookat;
vars += "&view.fov="+ event.state.view.fov;
krpano().call("loadscene(" + scene + "," + vars + ", MERGE, BLEND(1));");
};
function krpano() {
return document.getElementById("krpanoSWFObject");
}
//called by scene loading
function krp_pushState(scene, spot) {
history.pushState({ scene: scene, refspot:spot }, scene, location.origin + "/?ambiente=" + scene);
}
function krp_replaceState(scene, view) {
history.replaceState({ scene: scene, view:view },
scene,
location.origin + "/?ambiente=" + scene);
}
function saveToDB(scene) {
db.put({ _id: scene, visited: true }).then(function (doc) {
console.log(doc);
}).catch(function (err) {
console.log("Espaço já visitado...")
});
}
//persistence of visited record
db.allDocs({ include_docs: true }).then(function (result) {
return Promise.all(result.rows.map(function (row) {
if (row.doc.visited) {
krpano().call("layer[spot-" + row.doc._id + "].loadstyle(mapspot-visited);");
}
}));
})
</script>
</div>
</body>
</html>