MCPcopy Create free account
hub / github.com/comaps/comaps / BelongsToRegion

Method BelongsToRegion

libs/storage/country_info_reader_light.cpp:60–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

58}
59
60bool CountryInfoReader::BelongsToRegion(m2::PointD const & pt, size_t id) const
61{
62 if (!m_countries[id].m_rect.IsPointInside(pt))
63 return false;
64
65 std::vector<m2::RegionD> regions;
66 LoadRegionsFromDisk(id, regions);
67
68 for (auto const & region : regions)
69 if (region.Contains(pt))
70 return true;
71
72 return false;
73}
74
75CountryInfoReader::Info CountryInfoReader::GetMwmInfo(m2::PointD const & pt) const
76{

Callers

nothing calls this directly

Calls 2

IsPointInsideMethod · 0.45
ContainsMethod · 0.45

Tested by

no test coverage detected