-
Notifications
You must be signed in to change notification settings - Fork 0
/
persp.html
94 lines (91 loc) · 2.6 KB
/
persp.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
<!DOCTYPE html>
<html>
<head>
<title>Defend Earth!</title>
<style>
body {
padding: 0;
background: black;
}
#wrapper {
margin: auto;
position: relative;
width: 800px;
height: 600px;
}
#map_canvas {
position: absolute;
width: 800px;
height: 600px;
top: 0;
left: 0;
-webkit-filter: contrast(1.3) sepia(0.3) saturate(1.3) brightness(-.25);
-moz-filter: contrast(1.3) sepia(0.3) saturate(1.3) brightness(-.25);
-filter: contrast(1.3) sepia(0.3) saturate(1.3) brightness(-.25);
}
#shadow {
position: absolute;
width: 800px;
height: 600px;
-webkit-box-shadow: inset 0 0 48px 44px;
-moz-box-shadow: inset 0 0 48px 44px;
z-index: 999;
}
.gmnoprint {
display: none;
}
canvas {
position: absolute;
top: 0;
left: 0;
z-index: 99;
}
.instructions {
color: #aaa;
text-align:center;
font-family: sans-serif;
character-spacing: 1.5em;
}
.small {
font-size: .7em;
color: #444;
text-decoration: none;
}
</style>
<script src="jquery.min.js" type="text/javascript"></script>
<script src="https://maps.googleapis.com/maps/api/js?sensor=false"></script>
<script>
var map;
$(window).load(function(){
if (typeof(google) != "undefined")
var locations = [
{ center: new google.maps.LatLng(37.679201, -122.408123), label: "San Francisco"},
{ center: new google.maps.LatLng(41.81537, 12.458925), label: "Rome"},
{ center: new google.maps.LatLng(48.842019, 2.350184), label: "Paris"},
{ center: new google.maps.LatLng(43.656051, -79.38741), label: "Toronto" }
];
var mapOptions = {
zoom: 17,
center: locations[Math.round(Math.random() * (locations.length - 1))].center,
disableDefaultUI: true,
mapTypeId: google.maps.MapTypeId.SATELLITE
}
if (typeof(google) != "undefined")
map = new google.maps.Map(document.getElementById('map_canvas'), mapOptions);
$("#map_canvas").css("background-color","black");
if (map) {
center = map.getCenter();
map.panTo(new google.maps.LatLng(0,0));
}
});
</script>
<script>
</script>
</head>
<body>
<div id="wrapper">
<canvas width=800, height=600></canvas>
<div id="map_canvas"></div>
</div>
</body>
</html>