mirror of
https://github.com/tumic0/GPXSee.git
synced 2024-11-24 11:45:53 +01:00
Only shift the top left corner
This commit is contained in:
parent
b65682a828
commit
cdd5c47da3
@ -408,17 +408,12 @@ RectC MapData::bounds() const
|
||||
{
|
||||
/* Align the map bounds with the OSM tiles to prevent area overlap artifacts
|
||||
at least when using EPSG:3857 projection. */
|
||||
|
||||
int zoom = _subFiles.last().base;
|
||||
|
||||
QPoint tl(OSM::mercator2tile(OSM::ll2m(_bounds.topLeft()), zoom));
|
||||
QPoint br(OSM::mercator2tile(OSM::ll2m(_bounds.bottomRight()), zoom));
|
||||
Coordinates ctl(OSM::tile2ll(tl, zoom));
|
||||
ctl.rlat() = -ctl.lat();
|
||||
Coordinates cbr(OSM::tile2ll(br, zoom));
|
||||
cbr.rlat() = -cbr.lat();
|
||||
|
||||
return RectC(ctl, cbr);
|
||||
return RectC(ctl, _bounds.bottomRight());
|
||||
}
|
||||
|
||||
void MapData::load()
|
||||
|
Loading…
Reference in New Issue
Block a user