XMLFeature::GetMercatorCenter.

This commit is contained in:
Alex Zolotarev 2016-03-04 11:07:47 +03:00 committed by Sergey Yershov
parent 6ba619d056
commit 97d1793a97
2 changed files with 6 additions and 0 deletions

View file

@ -161,6 +161,11 @@ void XMLFeature::ApplyPatch(XMLFeature const & featureWithChanges)
});
}
m2::PointD XMLFeature::GetMercatorCenter() const
{
return MercatorBounds::FromLatLon(GetLatLonFromNode(GetRootNode()));
}
ms::LatLon XMLFeature::GetCenter() const
{
return GetLatLonFromNode(GetRootNode());

View file

@ -62,6 +62,7 @@ public:
/// @returns true only if it is a way and it is closed (area).
bool IsArea() const;
m2::PointD GetMercatorCenter() const;
ms::LatLon GetCenter() const;
void SetCenter(ms::LatLon const & ll);
void SetCenter(m2::PointD const & mercatorCenter);