1

I am working on an app using android studio where cell data is saved in a database with it's corresponding location in latitude and longitude coordinates and users can access this data when there is no service to find a way to a good to better service. The data will be drawn to a google maps activity and color coordinated to represent the color but I also want to add an arrow the points from current location to the best cell service within a radius that I will set up.

Is it possible to draw an arrow to accomplish the task of pointing to a data point that is drawn? any info that points me in the right direction or the answer will help, thank you.

EDIT The arrow design I have in mind points to the better signal but does not connect to the other location. I will figure out a more complex pointing device later in development so I am just looking for information on the possibility of a short pointer arrow that represents a "GO THAT WAY" response.

AndreiBogdan
  • 10,858
  • 13
  • 58
  • 106
DJ. Aduvanchik
  • 332
  • 5
  • 17

2 Answers2

2

You can use Ground overlays , where you can set particular image at given latlong.

LatLng NEWARK = new LatLng(40.714086, -74.228697);

GroundOverlayOptions newarkMap = new GroundOverlayOptions()
    .image(BitmapDescriptorFactory.fromResource(R.drawable.newark_nj_1922))
    .position(NEWARK, 8600f, 6500f);
map.addGroundOverlay(newarkMap);

for rotating the image you can look

https://stackoverflow.com/a/4332278/7386743

Community
  • 1
  • 1
Navneet Kumar
  • 273
  • 1
  • 11
1

Are you talking about creating line between the two points ? Could you clearify more what do you exactly need ? If it creating a line then you can use polyline

GoogleMap map;
Polyline line = map.addPolyline(new PolylineOptions()
 .add(new LatLng(51.5, -0.1), new LatLng(40.7, -74.0))
 .width(5)
 .color(Color.RED));
Navneet Kumar
  • 273
  • 1
  • 11