BitmapDescriptor Stay organized with collections Save and categorize content based on your preferences.
Page Summary
BitmapDescriptor defines a Bitmap image used for marker icons or ground overlays.
To get a BitmapDescriptor, use the factory class BitmapDescriptorFactory.
BitmapDescriptor inherits standard methods from the java.lang.Object class.
Defines a Bitmap image. For a marker, this class can be used to set the image of the marker icon. For a ground overlay, it can be used to set the image to place on the surface of the earth. To obtain aBitmapDescriptor use the factory classBitmapDescriptorFactory.
Example of setting the icon of a markerBitmapDescriptor.
GoogleMap map = ... // get a map. // Add a marker at San Francisco with an azure colored marker. Marker marker = map.add(new MarkerOptions() .position(new LatLng(37.7750, 122.4183)) .title("San Francisco") .snippet("Population: 776733")) .icon(BitmapDescriptorFactory.defaultMarker(BitmapDescriptorFactory.HUE_AZURE));Inherited Method Summary
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-10-31 UTC.