Download
Demo
- Overview
- Documents
User Rating: 0.3/5 ( 1 votes)
Your Rating:
This library integrates the Google Earth API, and will render most map overlays appropriately in the 3D plugin.
Google Earth API for Google Maps v3
This library integrates the Google Earth API, and will render most map overlays appropriately.
To initialize the Earth API, just instantiate a new GoogleEarth object, passing your map to it. Here is the simplest case of a map with no overlays:
var myOptions = {
zoom: 4,
center: new google.maps.LatLng(48.25, 11.00),
mapTypeId: google.maps.MapTypeId.ROADMAP
};
var map = new google.maps.Map(document.getElementById('map'), myOptions);
var ge = new GoogleEarth(map);
The current version of this library also supports a number of different overlays and layers. If you add any of the following to your map, they will also be displayed in Earth: Marker, InfoWindow, Polyline, Polygon, Rectangle, Circle,GroundOverlay and KmlLayer.
class GoogleEarth
Constructor
| Constructor | Description |
|---|---|
| GoogleEarth(map:google.maps.Map) | A wrapped Google Earth API instance, linked to the map. |
Constant
| Constant | Description |
|---|---|
| MAP_TYPE_ID | This map type displays the 3D Earth Plugin |
Methods
| Methods | Return Value | Description |
|---|---|---|
| getInstance() | google.earth.GEPlugin | The Earth API instance |
JS Tutorial
