summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSung-Taek Hong <sth253.hong@samsung.com>2015-05-01 14:34:11 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2015-05-01 14:34:11 +0900
commit02044396ec93932251ed6c6fc574f7a4d8e1d929 (patch)
tree9eae63ec8efc121fce966e9d0763141a0767648d
parentd32bb3b69a0e6b22fa3784e72258163c051e3375 (diff)
map: fix scale calculation error
Summary: As the map shows the nearer to the equator, the scale of the map should be smaller. In elm_map, the opposite happens because meters per pixel was miscalculated. Thus, calculation is corrected http://wiki.openstreetmap.org/wiki/Slippy_map_tilenames#Resolution_and_Scale @fix Reviewers: seoz, woohyun, Hermet Differential Revision: https://phab.enlightenment.org/D2426
-rw-r--r--src/lib/elm_map.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/elm_map.c b/src/lib/elm_map.c
index ea574e981..8e47a9289 100644
--- a/src/lib/elm_map.c
+++ b/src/lib/elm_map.c
@@ -260,7 +260,7 @@ _scale_cb(const Evas_Object *obj EINA_UNUSED,
260 (zoom >= (int)(sizeof(_osm_scale_meter) / sizeof(_osm_scale_meter[0]))) 260 (zoom >= (int)(sizeof(_osm_scale_meter) / sizeof(_osm_scale_meter[0])))
261 ) 261 )
262 return 0; 262 return 0;
263 return _osm_scale_meter[zoom] / cos(lat * ELM_PI / 180.0); 263 return _osm_scale_meter[zoom] * cos(lat * ELM_PI / 180.0);
264} 264}
265 265
266const Source_Tile src_tiles[] = 266const Source_Tile src_tiles[] =