9

I want to change the default current location marker color from blue to other. Any body help me out how to do that.

Below is the icon color which I want to change:

image is here

Jeel Vankhede
  • 11,592
  • 2
  • 28
  • 58
Deepak Rana
  • 539
  • 4
  • 18
  • 1
    Possible duplicate of [Android Maps API v2 Change MyLocation Icon](https://stackoverflow.com/questions/14826345/android-maps-api-v2-change-mylocation-icon) – Hanzala Jan 17 '19 at 07:13
  • 1
    @Hanzala this is not duplicate .. I just want to change the default icon color to use different marker – Deepak Rana Jan 17 '19 at 08:41

1 Answers1

1

EDIT:
YOU CAN'T CHANGE THE DEFAULT ONE, YOU HAVE TO MAKE YOU OWN AND HIDE THE DEFAULT

You can use your own markers by adding them to the map.

MarkerOptions markerOptions = new MarkerOptions();
markerOptions.position(currentLocationMarker.getPosition());
markerOptions.title(getString(R.string.start));
markerOptions.icon(BitmapDescriptorFactory.fromBitmap(mapPin));
originMarker = map.addMarker(markerOptions);

Additionally you can change the theme of the map using map style JSON files.

googleMap.setMapStyle(MapStyleOptions.loadRawResourceStyle(getActivity(), R.raw.map_night_style));

You can easily create you own style with google at the following link:
Style with google.

And here is the full documentation on customizing your map:
Documentation

Mark Kazakov
  • 946
  • 12
  • 17