Commit 71656d27aa98c50cc614e6d18a821431a15cf0e5

Authored by Paul Wallace
1 parent ee7452e859
Exists in master

Add heat map layer over google amps

Showing 1 changed file with 531 additions and 8 deletions Inline Diff

views/pages/landing.ejs View file @ 71656d2
<!DOCTYPE html> 1 1 <!DOCTYPE html>
<html lang="en"> 2 2 <html lang="en">
<head> 3 3 <head>
<% include ../partials/header %> 4 4 <% include ../partials/header %>
5 <!-- <script type="text/javascript"
6 src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDAXDHeZXEv4H4ZnThVDxpyAuxVpzOcj_U&libraries=visualization">
7 </script> -->
8
</head> 5 9 </head>
6 10
7 11
<body> 8 12 <body>
<div class="container"> 9 13 <div class="container">
10 14
<!-- My LOCATION --> 11 15 <!-- My LOCATION -->
<div> 12 16 <div>
<input type="text" class="form-control text-field" id="from" name="fromText" placeholder="MY LOCATION"> 13 17 <input type="text" class="form-control text-field" id="from" name="fromText" placeholder="MY LOCATION">
</div> 14 18 </div>
<!-- Destination --> 15 19 <!-- Destination -->
<div> 16 20 <div>
<input type="text" class="form-control text-field" id="to" name="toText" placeholder="Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna..."> 17 21 <input type="text" class="form-control text-field" id="to" name="toText" placeholder="Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna...">
</div> 18 22 </div>
19 23
<!-- Buttons and status information on top of the map. --> 20 24 <!-- Buttons and status information on top of the map. -->
<div class="container" id="map-top"> 21 25 <div class="container" id="map-top">
<div class="row"> 22 26 <div class="row">
<!-- Status --> 23 27 <!-- Status -->
<div class="col-xs-6"> 24 28 <div class="col-xs-6">
<!-- Title: Current Route --> 25 29 <!-- Title: Current Route -->
<div> 26 30 <div>
Current Route: 27 31 Current Route:
</div> 28 32 </div>
<!-- Icons + Status --> 29 33 <!-- Icons + Status -->
<div class="row status"> 30 34 <div class="row status">
<!-- Safety Rating --> 31 35 <!-- Safety Rating -->
<div class="col-xs-6"> 32 36 <div class="col-xs-6">
80% Safe 33 37 80% Safe
</div> 34 38 </div>
<!-- Travel Duration --> 35 39 <!-- Travel Duration -->
<div class="col-xs-6"> 36 40 <div class="col-xs-6">
10 Mins 37 41 10 Mins
</div> 38 42 </div>
</div> 39 43 </div>
</div> 40 44 </div>
<!-- Alt Routes --> 41 45 <!-- Alt Routes -->
<div class="col-xs-6"> 42 46 <div class="col-xs-6">
<button type="button" class="btn btn-default btn-block" id="alt-routes" onclick="todo()">Alternate Routes</button> 43 47 <button type="button" class="btn btn-default btn-block" id="alt-routes" onclick="todo()">Alternate Routes</button>
</div> 44 48 </div>
</div> 45 49 </div>
</div> 46 50 </div>
47 51
<!-- Div container for map. --> 48 52 <!-- Div container for map. -->
<div id="map"></div> 49 53 <div id="map"></div>
50 54
55 <!-- Add in stuff for the heat map -->
56
57
58
<!-- Javascript for the map. --> 51 59 <!-- Javascript for the map. -->
<script> 52 60 <script>
61 // Heatmap data: 500 Points
62
63
64
65 var map, heatmap;
function initMap() { 53 66 function initMap() {
// Used by the Google Maps Direction API. 54 67 // Used by the Google Maps Direction API.
var directionsService = new google.maps.DirectionsService; 55 68 var directionsService = new google.maps.DirectionsService;
var directionsDisplay = new google.maps.DirectionsRenderer; 56 69 var directionsDisplay = new google.maps.DirectionsRenderer;
// Setting default map location. 57 70 // Setting default map location.
var map = document.getElementById("map"); 58 71
var options = { 59 72 map = new google.maps.Map(document.getElementById('map'), {
center: new google.maps.LatLng(32.8804526, -117.2376329), 60 73 zoom: 13,
zoom: 17 61 74 center: {lat: 37.775, lng: -122.434}
} 62 75 });
map = new google.maps.Map(map, options); 63 76
77 heatmap = new google.maps.visualization.HeatmapLayer({
78 data: getPoints(),
79 map: map
80 });
directionsDisplay.setMap(map); 64 81 directionsDisplay.setMap(map);
65 82
// Keeping the map center when the browser is resized. 66 83 // Keeping the map center when the browser is resized.
function resizing() { 67 84 function resizing() {
var center = map.getCenter(); 68 85 var center = map.getCenter();
google.maps.event.trigger(map, "resize"); 69 86 google.maps.event.trigger(map, "resize");
map.setCenter(center); 70 87 map.setCenter(center);
} 71 88 }
72 89
google.maps.event.addDomListener(window, "resize", resizing); 73 90 google.maps.event.addDomListener(window, "resize", resizing);
74 91
// Showing route. 75 92 // // Showing route.
displayRoute(directionsService, directionsDisplay); 76 93 displayRoute(directionsService, directionsDisplay);
} 77 94 }
78 95
function displayRoute(directionsService, directionsDisplay) { 79 96 function displayRoute(directionsService, directionsDisplay) {
// Textfields that show from and to. 80 97 // Textfields that show from and to.
document.getElementsByName("fromText")[0].placeholder=localStorage.getItem("from"); 81 98 document.getElementsByName("fromText")[0].placeholder=localStorage.getItem("from");
document.getElementsByName("toText")[0].placeholder=localStorage.getItem("to"); 82 99 document.getElementsByName("toText")[0].placeholder=localStorage.getItem("to");
83 100
var request = { 84 101 var request = {
origin: localStorage.getItem("from"), 85 102 origin: localStorage.getItem("from"),
destination: localStorage.getItem("to"), 86 103 destination: localStorage.getItem("to"),
travelMode: localStorage.getItem("mode") 87 104 travelMode: localStorage.getItem("mode")
}; 88 105 };
89 106
directionsService.route(request, function(response, status) { 90 107 directionsService.route(request, function(response, status) {
if (status === "OK") { 91 108 if (status === "OK") {
directionsDisplay.setDirections(response); 92 109 directionsDisplay.setDirections(response);
} 93 110 }
else { 94 111 else {
window.alert("Directions request failed due to " + status); 95 112 window.alert("Directions request failed due to " + status);
} 96 113 }
}); 97 114 });
} 98 115 }
116
117 function getPoints() {
118 return [
119 new google.maps.LatLng(37.782551, -122.445368),
120 new google.maps.LatLng(37.782745, -122.444586),
121 new google.maps.LatLng(37.782842, -122.443688),
122 new google.maps.LatLng(37.782919, -122.442815),
123 new google.maps.LatLng(37.782992, -122.442112),
124 new google.maps.LatLng(37.783100, -122.441461),
125 new google.maps.LatLng(37.783206, -122.440829),
126 new google.maps.LatLng(37.783273, -122.440324),
127 new google.maps.LatLng(37.783316, -122.440023),
128 new google.maps.LatLng(37.783357, -122.439794),
129 new google.maps.LatLng(37.783371, -122.439687),
130 new google.maps.LatLng(37.783368, -122.439666),
131 new google.maps.LatLng(37.783383, -122.439594),
132 new google.maps.LatLng(37.783508, -122.439525),
133 new google.maps.LatLng(37.783842, -122.439591),
134 new google.maps.LatLng(37.784147, -122.439668),
135 new google.maps.LatLng(37.784206, -122.439686),
136 new google.maps.LatLng(37.784386, -122.439790),
137 new google.maps.LatLng(37.784701, -122.439902),
138 new google.maps.LatLng(37.784965, -122.439938),
139 new google.maps.LatLng(37.785010, -122.439947),
140 new google.maps.LatLng(37.785360, -122.439952),
141 new google.maps.LatLng(37.785715, -122.440030),
142 new google.maps.LatLng(37.786117, -122.440119),
143 new google.maps.LatLng(37.786564, -122.440209),
144 new google.maps.LatLng(37.786905, -122.440270),
145 new google.maps.LatLng(37.786956, -122.440279),
146 new google.maps.LatLng(37.800224, -122.433520),
147 new google.maps.LatLng(37.800155, -122.434101),
148 new google.maps.LatLng(37.800160, -122.434430),
149 new google.maps.LatLng(37.800378, -122.434527),
150 new google.maps.LatLng(37.800738, -122.434598),
151 new google.maps.LatLng(37.800938, -122.434650),
152 new google.maps.LatLng(37.801024, -122.434889),
153 new google.maps.LatLng(37.800955, -122.435392),
154 new google.maps.LatLng(37.800886, -122.435959),
155 new google.maps.LatLng(37.800811, -122.436275),
156 new google.maps.LatLng(37.800788, -122.436299),
157 new google.maps.LatLng(37.800719, -122.436302),
158 new google.maps.LatLng(37.800702, -122.436298),
159 new google.maps.LatLng(37.800661, -122.436273),
160 new google.maps.LatLng(37.800395, -122.436172),
161 new google.maps.LatLng(37.800228, -122.436116),
162 new google.maps.LatLng(37.800169, -122.436130),
163 new google.maps.LatLng(37.800066, -122.436167),
164 new google.maps.LatLng(37.784345, -122.422922),
165 new google.maps.LatLng(37.784389, -122.422926),
166 new google.maps.LatLng(37.784437, -122.422924),
167 new google.maps.LatLng(37.784746, -122.422818),
168 new google.maps.LatLng(37.785436, -122.422959),
169 new google.maps.LatLng(37.786120, -122.423112),
170 new google.maps.LatLng(37.786433, -122.423029),
171 new google.maps.LatLng(37.786631, -122.421213),
172 new google.maps.LatLng(37.786660, -122.421033),
173 new google.maps.LatLng(37.786801, -122.420141),
174 new google.maps.LatLng(37.786823, -122.420034),
175 new google.maps.LatLng(37.786831, -122.419916),
176 new google.maps.LatLng(37.787034, -122.418208),
177 new google.maps.LatLng(37.787056, -122.418034),
178 new google.maps.LatLng(37.787169, -122.417145),
179 new google.maps.LatLng(37.787217, -122.416715),
180 new google.maps.LatLng(37.786144, -122.416403),
181 new google.maps.LatLng(37.785292, -122.416257),
182 new google.maps.LatLng(37.780666, -122.390374),
183 new google.maps.LatLng(37.780501, -122.391281),
184 new google.maps.LatLng(37.780148, -122.392052),
185 new google.maps.LatLng(37.780173, -122.391148),
186 new google.maps.LatLng(37.780693, -122.390592),
187 new google.maps.LatLng(37.781261, -122.391142),
188 new google.maps.LatLng(37.781808, -122.391730),
189 new google.maps.LatLng(37.782340, -122.392341),
190 new google.maps.LatLng(37.782812, -122.393022),
191 new google.maps.LatLng(37.783300, -122.393672),
192 new google.maps.LatLng(37.783809, -122.394275),
193 new google.maps.LatLng(37.784246, -122.394979),
194 new google.maps.LatLng(37.784791, -122.395958),
195 new google.maps.LatLng(37.785675, -122.396746),
196 new google.maps.LatLng(37.786262, -122.395780),
197 new google.maps.LatLng(37.786776, -122.395093),
198 new google.maps.LatLng(37.787282, -122.394426),
199 new google.maps.LatLng(37.787783, -122.393767),
200 new google.maps.LatLng(37.788343, -122.393184),
201 new google.maps.LatLng(37.788895, -122.392506),
202 new google.maps.LatLng(37.789371, -122.391701),
203 new google.maps.LatLng(37.789722, -122.390952),
204 new google.maps.LatLng(37.790315, -122.390305),
205 new google.maps.LatLng(37.790738, -122.389616),
206 new google.maps.LatLng(37.779448, -122.438702),
207 new google.maps.LatLng(37.779023, -122.438585),
208 new google.maps.LatLng(37.778542, -122.438492),
209 new google.maps.LatLng(37.778100, -122.438411),
210 new google.maps.LatLng(37.777986, -122.438376),
211 new google.maps.LatLng(37.777680, -122.438313),
212 new google.maps.LatLng(37.777316, -122.438273),
213 new google.maps.LatLng(37.777135, -122.438254),
214 new google.maps.LatLng(37.776987, -122.438303),
215 new google.maps.LatLng(37.776946, -122.438404),
216 new google.maps.LatLng(37.776944, -122.438467),
217 new google.maps.LatLng(37.776892, -122.438459),
218 new google.maps.LatLng(37.776842, -122.438442),
219 new google.maps.LatLng(37.776822, -122.438391),
220 new google.maps.LatLng(37.776814, -122.438412),
221 new google.maps.LatLng(37.776787, -122.438628),
222 new google.maps.LatLng(37.776729, -122.438650),
223 new google.maps.LatLng(37.776759, -122.438677),
224 new google.maps.LatLng(37.776772, -122.438498),
225 new google.maps.LatLng(37.776787, -122.438389),
226 new google.maps.LatLng(37.776848, -122.438283),
227 new google.maps.LatLng(37.776870, -122.438239),
228 new google.maps.LatLng(37.777015, -122.438198),
229 new google.maps.LatLng(37.777333, -122.438256),
230 new google.maps.LatLng(37.777595, -122.438308),
231 new google.maps.LatLng(37.777797, -122.438344),
232 new google.maps.LatLng(37.778160, -122.438442),
233 new google.maps.LatLng(37.778414, -122.438508),
234 new google.maps.LatLng(37.778445, -122.438516),
235 new google.maps.LatLng(37.778503, -122.438529),
236 new google.maps.LatLng(37.778607, -122.438549),
237 new google.maps.LatLng(37.778670, -122.438644),
238 new google.maps.LatLng(37.778847, -122.438706),
239 new google.maps.LatLng(37.779240, -122.438744),
240 new google.maps.LatLng(37.779738, -122.438822),
241 new google.maps.LatLng(37.780201, -122.438882),
242 new google.maps.LatLng(37.780400, -122.438905),
243 new google.maps.LatLng(37.780501, -122.438921),
244 new google.maps.LatLng(37.780892, -122.438986),
245 new google.maps.LatLng(37.781446, -122.439087),
246 new google.maps.LatLng(37.781985, -122.439199),
247 new google.maps.LatLng(37.782239, -122.439249),
248 new google.maps.LatLng(37.782286, -122.439266),
249 new google.maps.LatLng(37.797847, -122.429388),
250 new google.maps.LatLng(37.797874, -122.429180),
251 new google.maps.LatLng(37.797885, -122.429069),
252 new google.maps.LatLng(37.797887, -122.429050),
253 new google.maps.LatLng(37.797933, -122.428954),
254 new google.maps.LatLng(37.798242, -122.428990),
255 new google.maps.LatLng(37.798617, -122.429075),
256 new google.maps.LatLng(37.798719, -122.429092),
257 new google.maps.LatLng(37.798944, -122.429145),
258 new google.maps.LatLng(37.799320, -122.429251),
259 new google.maps.LatLng(37.799590, -122.429309),
260 new google.maps.LatLng(37.799677, -122.429324),
261 new google.maps.LatLng(37.799966, -122.429360),
262 new google.maps.LatLng(37.800288, -122.429430),
263 new google.maps.LatLng(37.800443, -122.429461),
264 new google.maps.LatLng(37.800465, -122.429474),
265 new google.maps.LatLng(37.800644, -122.429540),
266 new google.maps.LatLng(37.800948, -122.429620),
267 new google.maps.LatLng(37.801242, -122.429685),
268 new google.maps.LatLng(37.801375, -122.429702),
269 new google.maps.LatLng(37.801400, -122.429703),
270 new google.maps.LatLng(37.801453, -122.429707),
271 new google.maps.LatLng(37.801473, -122.429709),
272 new google.maps.LatLng(37.801532, -122.429707),
273 new google.maps.LatLng(37.801852, -122.429729),
274 new google.maps.LatLng(37.802173, -122.429789),
275 new google.maps.LatLng(37.802459, -122.429847),
276 new google.maps.LatLng(37.802554, -122.429825),
277 new google.maps.LatLng(37.802647, -122.429549),
278 new google.maps.LatLng(37.802693, -122.429179),
279 new google.maps.LatLng(37.802729, -122.428751),
280 new google.maps.LatLng(37.766104, -122.409291),
281 new google.maps.LatLng(37.766103, -122.409268),
282 new google.maps.LatLng(37.766138, -122.409229),
283 new google.maps.LatLng(37.766183, -122.409231),
284 new google.maps.LatLng(37.766153, -122.409276),
285 new google.maps.LatLng(37.766005, -122.409365),
286 new google.maps.LatLng(37.765897, -122.409570),
287 new google.maps.LatLng(37.765767, -122.409739),
288 new google.maps.LatLng(37.765693, -122.410389),
289 new google.maps.LatLng(37.765615, -122.411201),
290 new google.maps.LatLng(37.765533, -122.412121),
291 new google.maps.LatLng(37.765467, -122.412939),
292 new google.maps.LatLng(37.765444, -122.414821),
293 new google.maps.LatLng(37.765444, -122.414964),
294 new google.maps.LatLng(37.765318, -122.415424),
295 new google.maps.LatLng(37.763961, -122.415296),
296 new google.maps.LatLng(37.763115, -122.415196),
297 new google.maps.LatLng(37.762967, -122.415183),
298 new google.maps.LatLng(37.762278, -122.415127),
299 new google.maps.LatLng(37.761675, -122.415055),
300 new google.maps.LatLng(37.760932, -122.414988),
301 new google.maps.LatLng(37.759337, -122.414862),
302 new google.maps.LatLng(37.773187, -122.421922),
303 new google.maps.LatLng(37.773043, -122.422118),
304 new google.maps.LatLng(37.773007, -122.422165),
305 new google.maps.LatLng(37.772979, -122.422219),
306 new google.maps.LatLng(37.772865, -122.422394),
307 new google.maps.LatLng(37.772779, -122.422503),
308 new google.maps.LatLng(37.772676, -122.422701),
309 new google.maps.LatLng(37.772606, -122.422806),
310 new google.maps.LatLng(37.772566, -122.422840),
311 new google.maps.LatLng(37.772508, -122.422852),
312 new google.maps.LatLng(37.772387, -122.423011),
313 new google.maps.LatLng(37.772099, -122.423328),
314 new google.maps.LatLng(37.771704, -122.423783),
315 new google.maps.LatLng(37.771481, -122.424081),
316 new google.maps.LatLng(37.771400, -122.424179),
317 new google.maps.LatLng(37.771352, -122.424220),
318 new google.maps.LatLng(37.771248, -122.424327),
319 new google.maps.LatLng(37.770904, -122.424781),
320 new google.maps.LatLng(37.770520, -122.425283),
321 new google.maps.LatLng(37.770337, -122.425553),
322 new google.maps.LatLng(37.770128, -122.425832),
323 new google.maps.LatLng(37.769756, -122.426331),
324 new google.maps.LatLng(37.769300, -122.426902),
325 new google.maps.LatLng(37.769132, -122.427065),
326 new google.maps.LatLng(37.769092, -122.427103),
327 new google.maps.LatLng(37.768979, -122.427172),
328 new google.maps.LatLng(37.768595, -122.427634),
329 new google.maps.LatLng(37.768372, -122.427913),
330 new google.maps.LatLng(37.768337, -122.427961),
331 new google.maps.LatLng(37.768244, -122.428138),
332 new google.maps.LatLng(37.767942, -122.428581),
333 new google.maps.LatLng(37.767482, -122.429094),
334 new google.maps.LatLng(37.767031, -122.429606),
335 new google.maps.LatLng(37.766732, -122.429986),
336 new google.maps.LatLng(37.766680, -122.430058),
337 new google.maps.LatLng(37.766633, -122.430109),
338 new google.maps.LatLng(37.766580, -122.430211),
339 new google.maps.LatLng(37.766367, -122.430594),
340 new google.maps.LatLng(37.765910, -122.431137),
341 new google.maps.LatLng(37.765353, -122.431806),
342 new google.maps.LatLng(37.764962, -122.432298),
343 new google.maps.LatLng(37.764868, -122.432486),
344 new google.maps.LatLng(37.764518, -122.432913),
345 new google.maps.LatLng(37.763435, -122.434173),
346 new google.maps.LatLng(37.762847, -122.434953),
347 new google.maps.LatLng(37.762291, -122.435935),
348 new google.maps.LatLng(37.762224, -122.436074),
349 new google.maps.LatLng(37.761957, -122.436892),
350 new google.maps.LatLng(37.761652, -122.438886),
351 new google.maps.LatLng(37.761284, -122.439955),
352 new google.maps.LatLng(37.761210, -122.440068),
353 new google.maps.LatLng(37.761064, -122.440720),
354 new google.maps.LatLng(37.761040, -122.441411),
355 new google.maps.LatLng(37.761048, -122.442324),
356 new google.maps.LatLng(37.760851, -122.443118),
357 new google.maps.LatLng(37.759977, -122.444591),
358 new google.maps.LatLng(37.759913, -122.444698),
359 new google.maps.LatLng(37.759623, -122.445065),
360 new google.maps.LatLng(37.758902, -122.445158),
361 new google.maps.LatLng(37.758428, -122.444570),
362 new google.maps.LatLng(37.757687, -122.443340),
363 new google.maps.LatLng(37.757583, -122.443240),
364 new google.maps.LatLng(37.757019, -122.442787),
365 new google.maps.LatLng(37.756603, -122.442322),
366 new google.maps.LatLng(37.756380, -122.441602),
367 new google.maps.LatLng(37.755790, -122.441382),
368 new google.maps.LatLng(37.754493, -122.442133),
369 new google.maps.LatLng(37.754361, -122.442206),
370 new google.maps.LatLng(37.753719, -122.442650),
371 new google.maps.LatLng(37.753096, -122.442915),
372 new google.maps.LatLng(37.751617, -122.443211),
373 new google.maps.LatLng(37.751496, -122.443246),
374 new google.maps.LatLng(37.750733, -122.443428),
375 new google.maps.LatLng(37.750126, -122.443536),
376 new google.maps.LatLng(37.750103, -122.443784),
377 new google.maps.LatLng(37.750390, -122.444010),
378 new google.maps.LatLng(37.750448, -122.444013),
379 new google.maps.LatLng(37.750536, -122.444040),
380 new google.maps.LatLng(37.750493, -122.444141),
381 new google.maps.LatLng(37.790859, -122.402808),
382 new google.maps.LatLng(37.790864, -122.402768),
383 new google.maps.LatLng(37.790995, -122.402539),
384 new google.maps.LatLng(37.791148, -122.402172),
385 new google.maps.LatLng(37.791385, -122.401312),
386 new google.maps.LatLng(37.791405, -122.400776),
387 new google.maps.LatLng(37.791288, -122.400528),
388 new google.maps.LatLng(37.791113, -122.400441),
389 new google.maps.LatLng(37.791027, -122.400395),
390 new google.maps.LatLng(37.791094, -122.400311),
391 new google.maps.LatLng(37.791211, -122.400183),
392 new google.maps.LatLng(37.791060, -122.399334),
393 new google.maps.LatLng(37.790538, -122.398718),
394 new google.maps.LatLng(37.790095, -122.398086),
395 new google.maps.LatLng(37.789644, -122.397360),
396 new google.maps.LatLng(37.789254, -122.396844),
397 new google.maps.LatLng(37.788855, -122.396397),
398 new google.maps.LatLng(37.788483, -122.395963),
399 new google.maps.LatLng(37.788015, -122.395365),
400 new google.maps.LatLng(37.787558, -122.394735),
401 new google.maps.LatLng(37.787472, -122.394323),
402 new google.maps.LatLng(37.787630, -122.394025),
403 new google.maps.LatLng(37.787767, -122.393987),
404 new google.maps.LatLng(37.787486, -122.394452),
405 new google.maps.LatLng(37.786977, -122.395043),
406 new google.maps.LatLng(37.786583, -122.395552),
407 new google.maps.LatLng(37.786540, -122.395610),
408 new google.maps.LatLng(37.786516, -122.395659),
409 new google.maps.LatLng(37.786378, -122.395707),
410 new google.maps.LatLng(37.786044, -122.395362),
411 new google.maps.LatLng(37.785598, -122.394715),
412 new google.maps.LatLng(37.785321, -122.394361),
413 new google.maps.LatLng(37.785207, -122.394236),
414 new google.maps.LatLng(37.785751, -122.394062),
415 new google.maps.LatLng(37.785996, -122.393881),
416 new google.maps.LatLng(37.786092, -122.393830),
417 new google.maps.LatLng(37.785998, -122.393899),
418 new google.maps.LatLng(37.785114, -122.394365),
419 new google.maps.LatLng(37.785022, -122.394441),
420 new google.maps.LatLng(37.784823, -122.394635),
421 new google.maps.LatLng(37.784719, -122.394629),
422 new google.maps.LatLng(37.785069, -122.394176),
423 new google.maps.LatLng(37.785500, -122.393650),
424 new google.maps.LatLng(37.785770, -122.393291),
425 new google.maps.LatLng(37.785839, -122.393159),
426 new google.maps.LatLng(37.782651, -122.400628),
427 new google.maps.LatLng(37.782616, -122.400599),
428 new google.maps.LatLng(37.782702, -122.400470),
429 new google.maps.LatLng(37.782915, -122.400192),
430 new google.maps.LatLng(37.783137, -122.399887),
431 new google.maps.LatLng(37.783414, -122.399519),
432 new google.maps.LatLng(37.783629, -122.399237),
433 new google.maps.LatLng(37.783688, -122.399157),
434 new google.maps.LatLng(37.783716, -122.399106),
435 new google.maps.LatLng(37.783798, -122.399072),
436 new google.maps.LatLng(37.783997, -122.399186),
437 new google.maps.LatLng(37.784271, -122.399538),
438 new google.maps.LatLng(37.784577, -122.399948),
439 new google.maps.LatLng(37.784828, -122.400260),
440 new google.maps.LatLng(37.784999, -122.400477),
441 new google.maps.LatLng(37.785113, -122.400651),
442 new google.maps.LatLng(37.785155, -122.400703),
443 new google.maps.LatLng(37.785192, -122.400749),
444 new google.maps.LatLng(37.785278, -122.400839),
445 new google.maps.LatLng(37.785387, -122.400857),
446 new google.maps.LatLng(37.785478, -122.400890),
447 new google.maps.LatLng(37.785526, -122.401022),
448 new google.maps.LatLng(37.785598, -122.401148),
449 new google.maps.LatLng(37.785631, -122.401202),
450 new google.maps.LatLng(37.785660, -122.401267),
451 new google.maps.LatLng(37.803986, -122.426035),
452 new google.maps.LatLng(37.804102, -122.425089),
453 new google.maps.LatLng(37.804211, -122.424156),
454 new google.maps.LatLng(37.803861, -122.423385),
455 new google.maps.LatLng(37.803151, -122.423214),
456 new google.maps.LatLng(37.802439, -122.423077),
457 new google.maps.LatLng(37.801740, -122.422905),
458 new google.maps.LatLng(37.801069, -122.422785),
459 new google.maps.LatLng(37.800345, -122.422649),
460 new google.maps.LatLng(37.799633, -122.422603),
461 new google.maps.LatLng(37.799750, -122.421700),
462 new google.maps.LatLng(37.799885, -122.420854),
463 new google.maps.LatLng(37.799209, -122.420607),
464 new google.maps.LatLng(37.795656, -122.400395),
465 new google.maps.LatLng(37.795203, -122.400304),
466 new google.maps.LatLng(37.778738, -122.415584),
467 new google.maps.LatLng(37.778812, -122.415189),
468 new google.maps.LatLng(37.778824, -122.415092),
469 new google.maps.LatLng(37.778833, -122.414932),
470 new google.maps.LatLng(37.778834, -122.414898),
471 new google.maps.LatLng(37.778740, -122.414757),
472 new google.maps.LatLng(37.778501, -122.414433),
473 new google.maps.LatLng(37.778182, -122.414026),
474 new google.maps.LatLng(37.777851, -122.413623),
475 new google.maps.LatLng(37.777486, -122.413166),
476 new google.maps.LatLng(37.777109, -122.412674),
477 new google.maps.LatLng(37.776743, -122.412186),
478 new google.maps.LatLng(37.776440, -122.411800),
479 new google.maps.LatLng(37.776295, -122.411614),
480 new google.maps.LatLng(37.776158, -122.411440),
481 new google.maps.LatLng(37.775806, -122.410997),
482 new google.maps.LatLng(37.775422, -122.410484),
483 new google.maps.LatLng(37.775126, -122.410087),
484 new google.maps.LatLng(37.775012, -122.409854),
485 new google.maps.LatLng(37.775164, -122.409573),
486 new google.maps.LatLng(37.775498, -122.409180),
487 new google.maps.LatLng(37.775868, -122.408730),
488 new google.maps.LatLng(37.776256, -122.408240),
489 new google.maps.LatLng(37.776519, -122.407928),
490 new google.maps.LatLng(37.776539, -122.407904),
491 new google.maps.LatLng(37.776595, -122.407854),
492 new google.maps.LatLng(37.776853, -122.407547),
493 new google.maps.LatLng(37.777234, -122.407087),
494 new google.maps.LatLng(37.777644, -122.406558),
495 new google.maps.LatLng(37.778066, -122.406017),
496 new google.maps.LatLng(37.778468, -122.405499),
497 new google.maps.LatLng(37.778866, -122.404995),
498 new google.maps.LatLng(37.779295, -122.404455),
499 new google.maps.LatLng(37.779695, -122.403950),
500 new google.maps.LatLng(37.779982, -122.403584),
501 new google.maps.LatLng(37.780295, -122.403223),
502 new google.maps.LatLng(37.780664, -122.402766),
503 new google.maps.LatLng(37.781043, -122.402288),
504 new google.maps.LatLng(37.781399, -122.401823),
505 new google.maps.LatLng(37.781727, -122.401407),
506 new google.maps.LatLng(37.781853, -122.401247),
507 new google.maps.LatLng(37.781894, -122.401195),
508 new google.maps.LatLng(37.782076, -122.400977),
509 new google.maps.LatLng(37.782338, -122.400603),
510 new google.maps.LatLng(37.782666, -122.400133),
511 new google.maps.LatLng(37.783048, -122.399634),
512 new google.maps.LatLng(37.783450, -122.399198),
513 new google.maps.LatLng(37.783791, -122.398998),
514 new google.maps.LatLng(37.784177, -122.398959),
515 new google.maps.LatLng(37.784388, -122.398971),
516 new google.maps.LatLng(37.784404, -122.399128),
517 new google.maps.LatLng(37.784586, -122.399524),
518 new google.maps.LatLng(37.784835, -122.399927),
519 new google.maps.LatLng(37.785116, -122.400307),
520 new google.maps.LatLng(37.785282, -122.400539),
521 new google.maps.LatLng(37.785346, -122.400692),
522 new google.maps.LatLng(37.765769, -122.407201),
523 new google.maps.LatLng(37.765790, -122.407414),
524 new google.maps.LatLng(37.765802, -122.407755),
525 new google.maps.LatLng(37.765791, -122.408219),
526 new google.maps.LatLng(37.765763, -122.408759),
527 new google.maps.LatLng(37.765726, -122.409348),
528 new google.maps.LatLng(37.765716, -122.409882),
529 new google.maps.LatLng(37.765708, -122.410202),
530 new google.maps.LatLng(37.765705, -122.410253),
531 new google.maps.LatLng(37.765707, -122.410369),
532 new google.maps.LatLng(37.765692, -122.410720),
533 new google.maps.LatLng(37.765699, -122.411215),
534 new google.maps.LatLng(37.765687, -122.411789),
535 new google.maps.LatLng(37.765666, -122.412373),
536 new google.maps.LatLng(37.765598, -122.412883),
537 new google.maps.LatLng(37.765543, -122.413039),
538 new google.maps.LatLng(37.765532, -122.413125),
539 new google.maps.LatLng(37.765500, -122.413553),
540 new google.maps.LatLng(37.765448, -122.414053),
541 new google.maps.LatLng(37.765388, -122.414645),
542 new google.maps.LatLng(37.765323, -122.415250),
543 new google.maps.LatLng(37.765303, -122.415847),
544 new google.maps.LatLng(37.765251, -122.416439),
545 new google.maps.LatLng(37.765204, -122.417020),
546 new google.maps.LatLng(37.765172, -122.417556),
547 new google.maps.LatLng(37.765164, -122.418075),
548 new google.maps.LatLng(37.765153, -122.418618),
549 new google.maps.LatLng(37.765136, -122.419112),
550 new google.maps.LatLng(37.765129, -122.419378),
551 new google.maps.LatLng(37.765119, -122.419481),
552 new google.maps.LatLng(37.765100, -122.419852),
553 new google.maps.LatLng(37.765083, -122.420349),
554 new google.maps.LatLng(37.765045, -122.420930),
555 new google.maps.LatLng(37.764992, -122.421481),
556 new google.maps.LatLng(37.764980, -122.421695),
557 new google.maps.LatLng(37.764993, -122.421843),
558 new google.maps.LatLng(37.764986, -122.422255),
559 new google.maps.LatLng(37.764975, -122.422823),
560 new google.maps.LatLng(37.764939, -122.423411),
561 new google.maps.LatLng(37.764902, -122.424014),
562 new google.maps.LatLng(37.764853, -122.424576),
563 new google.maps.LatLng(37.764826, -122.424922),
564 new google.maps.LatLng(37.764796, -122.425375),
565 new google.maps.LatLng(37.764782, -122.425869),
566 new google.maps.LatLng(37.764768, -122.426089),
567 new google.maps.LatLng(37.764766, -122.426117),
568 new google.maps.LatLng(37.764723, -122.426276),
569 new google.maps.LatLng(37.764681, -122.426649),
570 new google.maps.LatLng(37.782012, -122.404200),
571 new google.maps.LatLng(37.781574, -122.404911),
572 new google.maps.LatLng(37.781055, -122.405597),
573 new google.maps.LatLng(37.780479, -122.406341),
574 new google.maps.LatLng(37.779996, -122.406939),
575 new google.maps.LatLng(37.779459, -122.407613),
576 new google.maps.LatLng(37.778953, -122.408228),
577 new google.maps.LatLng(37.778409, -122.408839),
578 new google.maps.LatLng(37.777842, -122.409501),
579 new google.maps.LatLng(37.777334, -122.410181),
580 new google.maps.LatLng(37.776809, -122.410836),
581 new google.maps.LatLng(37.776240, -122.411514),
582 new google.maps.LatLng(37.775725, -122.412145),
583 new google.maps.LatLng(37.775190, -122.412805),
584 new google.maps.LatLng(37.774672, -122.413464),
585 new google.maps.LatLng(37.774084, -122.414186),
586 new google.maps.LatLng(37.773533, -122.413636),
587 new google.maps.LatLng(37.773021, -122.413009),
588 new google.maps.LatLng(37.772501, -122.412371),
589 new google.maps.LatLng(37.771964, -122.411681),
590 new google.maps.LatLng(37.771479, -122.411078),
591 new google.maps.LatLng(37.770992, -122.410477),
592 new google.maps.LatLng(37.770467, -122.409801),
593 new google.maps.LatLng(37.770090, -122.408904),
594 new google.maps.LatLng(37.769657, -122.408103),
595 new google.maps.LatLng(37.769132, -122.407276),
596 new google.maps.LatLng(37.768564, -122.406469),
597 new google.maps.LatLng(37.767980, -122.405745),
598 new google.maps.LatLng(37.767380, -122.405299),
599 new google.maps.LatLng(37.766604, -122.405297),
600 new google.maps.LatLng(37.765838, -122.405200),
601 new google.maps.LatLng(37.765139, -122.405139),
602 new google.maps.LatLng(37.764457, -122.405094),
603 new google.maps.LatLng(37.763716, -122.405142),
604 new google.maps.LatLng(37.762932, -122.405398),
605 new google.maps.LatLng(37.762126, -122.405813),
606 new google.maps.LatLng(37.761344, -122.406215),
607 new google.maps.LatLng(37.760556, -122.406495),
608 new google.maps.LatLng(37.759732, -122.406484),
609 new google.maps.LatLng(37.758910, -122.406228),
610 new google.maps.LatLng(37.758182, -122.405695),
611 new google.maps.LatLng(37.757676, -122.405118),
612 new google.maps.LatLng(37.757039, -122.404346),
613 new google.maps.LatLng(37.756335, -122.403719),
614 new google.maps.LatLng(37.755503, -122.403406),
615 new google.maps.LatLng(37.754665, -122.403242),
616 new google.maps.LatLng(37.753837, -122.403172),
617 new google.maps.LatLng(37.752986, -122.403112),
618 new google.maps.LatLng(37.751266, -122.403355)
619 ];
620 }
</script> 99 621 </script>
100 622
<!-- Calling google maps API using the function defined above. --> 101 623 <!-- Calling google maps API using the function defined above. -->
<script async defer 102 624 <script async defer
src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDAXDHeZXEv4H4ZnThVDxpyAuxVpzOcj_U&callback=initMap"> 103 625 src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDAXDHeZXEv4H4ZnThVDxpyAuxVpzOcj_U&callback=initMap&libraries=visualization">
</script> 104 626 </script>
627
105 628
<!-- Buttons at the bottom of the map --> 106 629 <!-- Buttons at the bottom of the map -->
<div class="container"> 107 630 <div class="container">
<div class="row"> 108 631 <div class="row">
<!-- Status --> 109 632 <!-- Status -->
<div class="col-xs-4"> 110 633 <div class="col-xs-4">
<!-- Title: Current Area --> 111 634 <!-- Title: Current Area -->
<div> 112 635 <div>
Current Area: 113 636 Current Area:
</div> 114 637 </div>
<!-- Icons + Status --> 115 638 <!-- Icons + Status -->
<div> 116 639 <div>
80% Safe 117 640 80% Safe
</div> 118 641 </div>
</div> 119 642 </div>
<!-- Emergency --> 120 643 <!-- Emergency -->
<div class="col-xs-4"> 121 644 <div class="col-xs-4">
<button type="button" class="btn btn-danger btn-block" onclick="todo()">Emergency</button> 122 645 <button type="button" class="btn btn-danger btn-block" onclick="todo()">Emergency</button>
</div> 123 646 </div>
<!-- Open Map --> 124 647 <!-- Open Map -->
<div class="col-xs-4"> 125 648 <div class="col-xs-4">
<button type="button" class="btn btn-default btn-block" onclick="todo()">Open in Map</button> 126 649 <button type="button" class="btn btn-default btn-block" onclick="todo()">Open in Map</button>
</div> 127 650 </div>
</div> 128 651 </div>
</div> 129 652 </div>
130 653
</div> 131 654 </div>