In my android app, I am displaying a Google map for diff locations for which I have their lat & long. But now I am required to get diagonal co-ordinates i.e. ne_lat,ne_long,sw_lat and sw_long and display the v开发者_Python百科iew on map based on this. How to achieve this ? Please help.
GoogleMap map = // get reference to google map instance
if(map != null){
LatLngBounds visibleBounds = map.getProjection().getVisibleRegion().latLngBounds;
Log.i("SW", visibleBounds.southwest.toString());
Log.i("NE", visibleBounds.northeast.toString());
}
Hope that helps
精彩评论