forked from organicmaps/organicmaps
[search] Do correct distance test for house results comparison.
This commit is contained in:
parent
bb784e4804
commit
366496a865
1 changed files with 5 additions and 2 deletions
|
@ -7,6 +7,8 @@
|
|||
|
||||
#include "../../platform/platform.hpp"
|
||||
|
||||
#include "../../geometry/distance_on_sphere.hpp"
|
||||
|
||||
#include "../../indexer/scales.hpp"
|
||||
#include "../../indexer/index.hpp"
|
||||
#include "../../indexer/classificator_loader.hpp"
|
||||
|
@ -369,8 +371,9 @@ UNIT_TEST(HS_MWMSearch)
|
|||
p.x = MercatorBounds::XToLon(p.x);
|
||||
p.y = MercatorBounds::YToLat(p.y);
|
||||
|
||||
double const eps = 3.0E-4;
|
||||
if (fabs(p.x - a.m_lon) < eps && fabs(p.y - a.m_lat) < eps)
|
||||
//double const eps = 3.0E-4;
|
||||
//if (fabs(p.x - a.m_lon) < eps && fabs(p.y - a.m_lat) < eps)
|
||||
if (ms::DistanceOnEarth(a.m_lat, a.m_lon, p.y, p.x) < 3.0)
|
||||
{
|
||||
++matched;
|
||||
break;
|
||||
|
|
Loading…
Add table
Reference in a new issue