Make a mark on your Google Maps map

0

I wonder if there is any way to leave a mark on a certain part of the Google Maps map (android). I'm not saying in marker form, I'm wanting for example to leave an area next to my house with a spot of red on the map (or another color). Is it possible to do this on android? Thank you.

    
asked by anonymous 30.08.2016 / 23:20

1 answer

2

On the map you can add references with addMarker, addCircle, addPolyline and addPolygon.

In the link image was probably used addPolygon.

It also has addGroundOverlay, as well as circle to polyline and polygon the ground to zoom the rotation and slope of the map.

In the example I drew a png 256x256 star-shaped. See the result:

       @Override
       public void onMapReady(GoogleMap map) 
       {

         GroundOverlayOptions options = new GroundOverlayOptions();
         LatLng latLng = new LatLng("lat","lng"); // posição que deseja adicionar a marca

         options.position(latLng,400,400); // 400 - raio em metros
         options.image(BitmapDescriptorFactory.fromResource(R.drawable.ground));
         options.clickable(false);

         map.addGroundOverlay(options);
      }

    
31.08.2016 / 01:07