Trying to overlay Google maps in an Android program. Inside my labeling method, I have two ways to add a pin. One of them works, and the other does not. Unfortunately, the one that doesn't work is also the only one that has the option to add a shadow! Any help?
@Override
public void draw(android.graphics.Canvas canvas, MapView mapView,
boolean shadow) {
Point po = mapView.getProjection().toPixels(mapView.getMapCenter(),
null);
drawAt(canvas, mapView.getResources().getDrawable(R.drawable.map_marker_v),
po.x, po.y, false);
canvas.drawBitmap(BitmapFactory.decodeResource(mapView.getResources(),
R.drawable.map_marker_v), po.x, po.y, null);
}
Edit: fixed type
source
share