mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-06-27 03:29:16 +02:00
Added support for Garmin IMG maps
This commit is contained in:
@ -28,6 +28,11 @@ public:
|
||||
double left() const {return _tl.lon();}
|
||||
double right() const {return _br.lon();}
|
||||
|
||||
void setLeft(double val) {_tl.rlon() = val;}
|
||||
void setRight(double val) {_br.rlon() = val;}
|
||||
void setTop(double val) {_tl.rlat() = val;}
|
||||
void setBottom(double val) {_br.rlat() = val;}
|
||||
|
||||
RectC operator|(const RectC &r) const;
|
||||
RectC &operator|=(const RectC &r) {*this = *this | r; return *this;}
|
||||
RectC operator&(const RectC &r) const;
|
||||
@ -35,6 +40,13 @@ public:
|
||||
|
||||
RectC united(const Coordinates &c) const;
|
||||
|
||||
bool intersects(const RectC &r) const
|
||||
{return (right() >= r.left() && bottom() <= r.top() && left() <= r.right()
|
||||
&& top() >= r.bottom());}
|
||||
bool contains(const Coordinates&c) const
|
||||
{return (c.lon() >= left() && c.lon() <= right() && c.lat() <= top()
|
||||
&& c.lat() >= bottom());}
|
||||
|
||||
private:
|
||||
Coordinates _tl, _br;
|
||||
};
|
||||
|
Reference in New Issue
Block a user