We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0996f29 commit ab751fbCopy full SHA for ab751fb
1 file changed
globe/index.html
@@ -129,6 +129,7 @@
129
<script type="text/javascript" src="/globe/third-party/Three/Detector.js"></script>
130
<script type="text/javascript" src="/globe/third-party/Tween.js"></script>
131
<script type="text/javascript" src="/globe/globe.js"></script>
132
+ <script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?sensor=false"></script>
133
<script type="text/javascript">
134
135
if(!Detector.webgl){
@@ -164,25 +165,16 @@
164
165
var xhr;
166
TWEEN.start();
167
-
168
- xhr = new XMLHttpRequest();
169
- xhr.open('GET', '/globe/population909500.json', true);
170
- xhr.onreadystatechange = function(e) {
171
- if (xhr.readyState === 4) {
172
- if (xhr.status === 200) {
173
- var data = JSON.parse(xhr.responseText);
174
- window.data = data;
175
- for (i=0;i<data.length;i++) {
176
- globe.addData(data[i][1], {format: 'magnitude', name: data[i][0], animated: true});
177
- }
178
- globe.createPoints();
179
- settime(globe,0)();
180
- globe.animate();
181
182
183
- };
184
- xhr.send(null);
185
+ var geocoder = new google.maps.Geocoder();
+ geocoder.geocode({'address': "Los Angeles"}, function(results, status) {
+ if (status == google.maps.GeocoderStatus.OK) {
+ globe.addData([results[0].geometry.location.lat(), results[0].geometry.location.lng(), 0.5], {format: "magnitude", name: "test", animated: true});
+ globe.createPoints();
+ settime(globe,0)();
+ globe.animate();
+ }
+ });
186
187
</script>
188
0 commit comments