-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvisita.html
More file actions
executable file
·368 lines (273 loc) · 12.1 KB
/
visita.html
File metadata and controls
executable file
·368 lines (273 loc) · 12.1 KB
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
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" lang="en-US" xml:lang="es">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<title>..:: Ourense 3D - Visita Fotográfica ::..</title>
<link rel="stylesheet" href="css/style.css" type="text/css" media="screen" />
<link rel="stylesheet" href="css/styleTabs.css" type="text/css" media="screen" />
<link rel="stylesheet" href="css/styleScrollBarHor.css" />
<!--[if IE]><link rel="stylesheet" href="css/style.ie6.css" type="text/css" media="screen" /><![endif]-->
<!-- Problema en Internet Explorer para reconocer scripts de tipo application/javascript
Utilizar por ahora mejor text/javascript a pesar de estar ya obsoleto
-->
<script type="text/javascript" src="js/consultaXML.js"></script>
<script type="text/javascript" src="js/compressed.js"></script>
<script type="text/javascript" src="http://www.google.com/jsapi?key=ABQIAAAAC6ji2IOC6pyY4yEYZpJ41RRSxgunaLlWLKo0DeyDezlMpXYY7hQhre_shMIUm9MNLUIGRQfpFGxccQ"></script>
<script type="text/javascript">
var ge = null;
var la;
var turning;
var frameendEL;
var lat;
var long;
var head;
var t;
var rang;
var networkLink = null;
var enabled3D;
google.load("earth", "1");
function init() {
document.getElementById('locinfo').innerHTML="Conozca mejor Ourense y vuelva a enamorarse de nuestra hermosa ciudad a golpe de click";
google.earth.createInstance("map3d", initCallback, failureCallback);
}
function initCallback(object) {
turning = false;
ge = object;
//determinamos la vista inicial al cargar la página y al terminar de cargar el fichero kml
la = ge.createLookAt('');
//Ivan: para rotacion Inicial
frameendEL = false;
//Cargamos el fichero kmz con los modelos
//showKMZ();
ge.getLayerRoot().enableLayerById(ge.LAYER_BUILDINGS, true);
enabled3D = true;
ge.getWindow().setVisibility(true);
//Creando el marco de la ventana Google Earth
var frameOverlay = ge.createScreenOverlay('');
var icon = ge.createIcon('');
icon.setHref('http://localhost/Ourense3D/images/frameSup.png'); // Loads an gilded picture frame.
frameOverlay.setIcon(icon);
var screenXY = frameOverlay.getScreenXY();
screenXY.setXUnits(ge.UNITS_PIXELS);
screenXY.setYUnits(ge.UNITS_PIXELS);
screenXY.setX(0);
screenXY.setY(0);
var overlayXY = frameOverlay.getOverlayXY();
overlayXY.setXUnits(ge.UNITS_PIXELS);
overlayXY.setYUnits(ge.UNITS_PIXELS);
overlayXY.setX(-1); //Debe ser -1, porque pinta el overlay desplazado 1px a la derecha. Fallo Google
overlayXY.setY(0);
var overlaySize = frameOverlay.getSize()
overlaySize.setXUnits(ge.UNITS_FRACTION);
overlaySize.setYUnits(ge.UNITS_FRACTION);
overlaySize.setX(1);
overlaySize.setY(1);
frameOverlay.setVisibility(true);
ge.getFeatures().appendChild(frameOverlay);
//Establecemos la velocidad de las transiciones
ge.getOptions().setFlyToSpeed(.2);
//Establecemos los parámetros del vuelo inicial
lat = 42.336813043035;
long = -7.863759470448834;
head = 122.1419692168786;
t = 56.29668941482709;
rang =259.4673097908217;
//parametros de set: latitude, longitude, altitude, altitudeMode, heading, tilt, range
la.set(lat,long, 0, ge.ALTITUDE_RELATIVE_TO_GROUND, head,t,rang);
//Rotacion inicial
if (!frameendEL){
toggleFrameendEL();
}
ge.getView().setAbstractView(la);
turning = false;
}
function failureCallback(object) {
alert("Se ha producido un error. Lo sentimos.");
}
//Ivan: rotacion inicial
function toggleFrameendEL(){
if (!frameendEL){
window.google.earth.addEventListener(ge, 'frameend', zoomAround);
frameendEL = true;
}
else{
google.earth.removeEventListener(ge, 'frameend', zoomAround);
frameendEL = false;
}
}
function zoomAround(){
latemp = ge.getView().copyAsLookAt(ge.ALTITUDE_RELATIVE_TO_GROUND);
if ((latemp.getLatitude().toFixed(4) == lat.toFixed(4) && latemp.getLongitude().toFixed(4) == long.toFixed(4))|turning){
turn();
turning = true;
}
}
function turn(){
ge.getOptions().setFlyToSpeed(5);
head+=.5;
if (head > 360){
head -= 360;
}
la.setHeading(head);
la.setLatitude(lat);
la.setLongitude(long);
ge.getView().setAbstractView(la);
}
function switch3D(){
if (enabled3D)
{
ge.getLayerRoot().enableLayerById(ge.LAYER_BUILDINGS, false);
enabled3D = false;
}
else
{
ge.getLayerRoot().enableLayerById(ge.LAYER_BUILDINGS, true);
enabled3D = true;
}
}
//Función que carga un KMZ
function showKMZ(){
if(!networkLink){
//Creamos un NetworkLink con el kmz
var url = 'http://localhost/Ourense3D/models/comicModels.kmz';
networkLink = ge.createNetworkLink("");
networkLink.setFlyToView(false);
// creamos un objeto de tipo Link
var link = ge.createLink("");
link.setHref(url);
// asociamos el Link al objeto NetworkLink
networkLink.setLink(link);
// añadimos el NetworkLink al plugin
ge.getFeatures().appendChild(networkLink);
}
else
{
ge.getFeatures().removeChild(networkLink);
networkLink = null;
}
}
window.onload=function(){
showTab(0);
init();
}
</script>
<!--[if IE 6]><link rel="stylesheet" href="style.ie6.css" type="text/css" media="screen" /><![endif]-->
</head>
<body >
<div class="PageBackgroundGradient"></div>
<div class="PageBackgroundGlare">
<div class="PageBackgroundGlareImage"></div>
</div>
<div class="Main">
<div class="Sheet">
<div class="Sheet-tl"></div>
<div class="Sheet-tr"><div></div></div>
<div class="Sheet-bl"><div></div></div>
<div class="Sheet-br"><div></div></div>
<div class="Sheet-tc"><div></div></div>
<div class="Sheet-bc"><div></div></div>
<div class="Sheet-cl"><div></div></div>
<div class="Sheet-cr"><div></div></div>
<div class="Sheet-cc"></div>
<div class="Sheet-body">
<div class="Header">
<div class="Header-png-Info"></div>
<div class="Header-jpeg-Info"></div>
<div class="logo"></div>
</div>
<div class="nav">
<ul class="artmenu">
<li>
<a href="inicio.html"><span><span>Inicio</span></span></a>
</li>
<li>
<a class="active"><span><span>Visita Fotográfica</span></span></a>
</li>
<li>
<a href="rutas.html"><span><span>Visita Guiada</span></span></a>
</li>
<li>
<a href="juega.html"><span><span>Visita Interactiva</span></span></a>
</li>
</ul>
<div class="l"></div>
<div class="r">
<div></div>
</div>
</div><!--nav-->
<div class="contentLayout" style='margin-bottom: 1px;'>
<div class="Post">
<div class="Post-body">
<table align = "center">
<!--primera fila-->
<tr valign=top>
<td>
<div id='map3d_container' style='height: 380px; width: 650px;'>
<div id='map3d' style='height: 100%;'></div>
</div>
<div class="contentTab" >
<div id="wrapper">
<div id="slideleft"></div>
<div id="slidearea">
<div id="slider"></div>
</div>
<div id="slideright"></div>
</div>
</div>
<div id="pestanasScroll">
<ul id="toc">
<li id ="pesMonumen" class = "activa"><a onclick ="javascript:showTab(0);"><span><span>Monumentos</span></span></a></li>
<li id ="pesCalles" class = "noActiva"><a onclick ="javascript:showTab(1);"><span><span>Calles</span></span></a></li>
</ul>
</div>
</td>
<td >
<div class="Block">
<div class="Block-tl"></div>
<div class="Block-tr"><div></div></div>
<div class="Block-bl"><div></div></div>
<div class="Block-br"><div></div></div>
<div class="Block-tc"><div></div></div>
<div class="Block-bc"><div></div></div>
<div class="Block-cl"><div></div></div>
<div class="Block-cr"><div></div></div>
<div class="Block-cc"></div>
<div class="Block-body">
<div class="BlockHeader">
<div class="BlockHeader-text">
<b>Ourense3D <font style="color:#a58d4b">Info</font></b>
</div>
<div class="l"></div>
<div class="r"><div></div></div>
</div>
<div class="BlockContent">
<div class="BlockContent-body">
<div>
<b><p id='locinfo'></p></b>
</div>
<div id="checkbox" class="checkboxActive" onclick="switch3D()">
<div class="checkbox-text">
<b>Modelos 3D</b>
</div>
</div>
</div>
</div>
</div>
</div>
</td>
</tr>
<!--segunda fila-->
<tr>
<td>
</td>
</tr>
</table>
</div><!--Post-body-->
</div><!--Post-->
</div><!--contentLayout-->
</div><!--Sheet-body-->
</div><!--Sheet-->
</div><!--Main-->
</body>
</html>