How can i draw a line between two particular longitude and latitude points in android?
In my application i want to draw shortest distance path between two points which is given in the database.
How can i draw a line between two particular longitude and latitude points in android?
In my application i want to draw shortest distance path between two points which is given in the database.
Hi you can use this code in your onDraw() instead of drawing line... using Projection
Projection projection = mapView.getProjection();
Paint paint = new Paint();
Point point = new Point();
projection.toPixels(gp1, point);
paint.setColor(color);
Point point2 = new Point();
projection.toPixels(gp2, point2);