diff options
author | Dmitry Kunin <dkunin@mapswith.me> | 2014-02-05 11:58:19 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 02:11:10 +0300 |
commit | 591f82b0af0a492679cd44c692133187f52d735e (patch) | |
tree | e8520fb3d5189cf81e969fd0b64cbdef6637d1a2 /drape_head/testing_engine.cpp | |
parent | e0338663bacedf8c4ee9a4918aec25db03039023 (diff) |
[codereview]
Diffstat (limited to 'drape_head/testing_engine.cpp')
-rw-r--r-- | drape_head/testing_engine.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/drape_head/testing_engine.cpp b/drape_head/testing_engine.cpp index fbc2ad8d5d..4b26366e7d 100644 --- a/drape_head/testing_engine.cpp +++ b/drape_head/testing_engine.cpp @@ -85,11 +85,18 @@ namespace df float bottom = m_viewport.GetY0(); float top = bottom + m_viewport.GetHeight(); - float resolution = 32; + const float resolution = 32; + const float stepX = right/resolution; + const float stepY = top/resolution; m2::PointF grid[32][32]; // to simpify testing for (size_t i = 1; i <= resolution; ++i) for (size_t j = 1; j <= resolution; ++j) - grid[i-1][j-1] = m2::PointF((right/resolution)*i, (top/resolution)*j); + grid[i-1][j-1] = m2::PointF(stepX*i, stepY*j); + + // grid: + // [31,31] ... [31,31] + // ... ... + // [0,0] ... [0,31] vector<m2::PointF> linePoints1; |