Latest web development tutorials

Google Map Types

HYBRID type google maps:


Google Maps - basic map types

Google Maps API is available in the following map types:

  • MapTypeId.ROADMAP , used to display the default road map view
  • MapTypeId.SATELLITE , used to display Google Earth satellite images
  • MapTypeId.HYBRID , for simultaneously displaying the normal and satellite views
  • MapTypeId.TERRAIN , based on terrain information display the actual map.

Through being used to modify the Map map type, you can set mapTypeId properties:

var mapProp = {
center:new google.maps.LatLng(51.508742,-0.120850),
zoom:7,
mapTypeId: google.maps.MapTypeId.HYBRID
};

Or modified dynamically mapTypeId:

map.setMapTypeId(google.maps.MapTypeId.HYBRID);


Google Maps - 45 ° image

Google Maps API supports special 45 ° imagery for certain locations.

Such high-resolution images are available for each basic orientation toward the (truck) in a perspective view. For supported map types, these images also provide a higher zoom level.

Existing google.maps.MapTypeId.SATELLITE and google.maps.MapTypeId.HYBRID map types support high zoom level 45 ° perspective imagery (if available). If you zoom into a location such images, these map types will automatically alter their views in the following manner:

  • Any existing Pan control on a map will alter to have around the existing navigation controls add a compass wheel. You can change any of the 45 ° orientation of an image by the compass, it is: dragging the compass wheel, then oriented towards the nearest supported direction which contains imagery.
  • Rotate control will show a gap between the existing Pan and Zoom controls, it can be used around the image support rotation. Rotate control only allows clockwise rotation.
  • Current position as the center of the image will be replaced with 45 ° perspective satellite or hybrid imagery. By default, such views will orient towards north. If you zoom out, it will return to viewing the default satellite or hybrid imagery.
  • MapType control will enable a submenu toggle control for displaying 45 ° imagery.

Note: Narrow displaying 45 ° imagery map type will revert all changes, and re-establishing the original map types.

The following example shows the Ducal Palace in Venice, Italy, 45 ° view:

Examples

var mapProp = {
center:myCenter,
zoom:18,
mapTypeId:google.maps.MapTypeId.HYBRID
};

try it"

Tip: Google is constantly adding more cities to 45 ° imagery.For the latest information, see 45 ° imagery on Google Maps listing.


Google Maps - enable and disable 45 ° imagery - setTilt (0)

You can call through on the Map object setTilt (0) to disable 45 ° imagery. To enable 45 ° perspective imagery for supported map types, call setTilt (45).

Examples

map.setTilt(0);

try it"

Google Maps - Reference Manual

Google Maps API Reference Manual .