diff options
author | Paolo Angelelli <paolo.angelelli@qt.io> | 2017-08-04 13:22:43 +0200 |
---|---|---|
committer | Paolo Angelelli <paolo.angelelli@qt.io> | 2017-08-09 14:16:46 +0000 |
commit | 602cd4845dff2bbe5a8118899f1dfbcca9d614f1 (patch) | |
tree | a2e6c52c7d3982d883e6643a798b4c483c30b3d3 /src/location/maps/qgeoroute.cpp | |
parent | b6294cfca675bd5aa9a34e15c93692a0f1b8fdb2 (diff) | |
download | qtlocation-602cd4845dff2bbe5a8118899f1dfbcca9d614f1.tar.gz |
Fix visible region computation in QGeoProjectionWebMercator
Currently the visible region is calculated as the intersection between
the viewing frustum and the map plane clipped against the map extended
rectangle in mercator space (from -1 to 2 in x coords, 0 to 1 in y
coords).
The result is correct in the extended mercator space. However, this may
lead to overlapping coordinates when converted back to latitude and
longitude.
For this reason, this patch changes the clipping geometry to be the
map un-extended rectangle centered around the current map center.
The result is a geometry that never wraps around or overlaps, thus
removing the need for handling separately the case when the map
is fully visible when returning the visible region.
Task-number: QTBUG-57690
Change-Id: I8396c40a123ce94bff4388dfefbd8a694657b8bd
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Diffstat (limited to 'src/location/maps/qgeoroute.cpp')
0 files changed, 0 insertions, 0 deletions