BitmapDescriptor

  • 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.

public final classBitmapDescriptor extendsObject

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

From class java.lang.Object
Object
clone()
boolean
equals(Object arg0)
void
finalize()
finalClass<?>
getClass()
int
hashCode()
final void
notify()
final void
notifyAll()
String
toString()
final void
wait(long arg0, int arg1)
final void
wait(long arg0)
final void
wait()

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.