Changeset 4622 in josm


Ignore:
Timestamp:
Nov 30, 2011 12:07:53 AM (18 months ago)
Author:
Don-vip
Message:

Method to get the center of a BBox

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/BBox.java

    r4420 r4622  
    175175        return new LatLon(ymin, xmax); 
    176176    } 
     177     
     178    public LatLon getCenter() { 
     179        return new LatLon(ymin + (ymax-ymin)/2.0, xmin + (xmax-xmin)/2.0); 
     180    } 
    177181 
    178182    @Override 
Note: See TracChangeset for help on using the changeset viewer.