- Timestamp:
- 2018-12-03T20:43:27+01:00 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/layer/imagery/TileCoordinateConverter.java
r14273 r14505 22 22 import org.openstreetmap.josm.gui.MapView; 23 23 import org.openstreetmap.josm.gui.MapViewState.MapViewPoint; 24 import org.openstreetmap.josm.tools.JosmRuntimeException; 25 import org.openstreetmap.josm.tools.bugreport.BugReport; 24 26 25 27 /** … … 80 82 */ 81 83 public Point2D getPixelForTile(int x, int y, int zoom) { 82 ICoordinate coord = tileSource.tileXYToLatLon(x, y, zoom); 83 return pos(coord).getInView(); 84 try { 85 ICoordinate coord = tileSource.tileXYToLatLon(x, y, zoom); 86 if (Double.isNaN(coord.getLat()) || Double.isNaN(coord.getLon())) { 87 throw new JosmRuntimeException("tileXYToLatLon returned " + coord); 88 } 89 return pos(coord).getInView(); 90 } catch (RuntimeException e) { 91 throw BugReport.intercept(e).put("tileSource", tileSource).put("x", x).put("y", y).put("zoom", zoom); 92 } 84 93 } 85 94
Note:
See TracChangeset
for help on using the changeset viewer.