SUMOReal myXmin
The boundaries.
void growWidth(SUMOReal by)
Increases the width of the boundary (x-axis)
SUMOReal getHeight() const
Returns the height of the boundary (y-axis)
bool overlapsWith(const AbstractPoly &poly, SUMOReal offset=0) const
Returns whether the boundary overlaps with the given polygon.
bool crosses(const Position &p1, const Position &p2) const
Returns whether the boundary crosses the given line.
SUMOReal ymin() const
Returns minimum y-coordinate.
SUMOReal ymax() const
Returns maximum y-coordinate.
SUMOReal getWidth() const
Returns the width of the boudary (x-axis)
friend std::ostream & operator<<(std::ostream &os, const Boundary &b)
Output operator.
A class that stores a 2D geometrical boundary.
SUMOReal xmin() const
Returns minimum x-coordinate.
SUMOReal zmax() const
Returns maximum z-coordinate.
A point in 2D or 3D with translation and scaling methods.
bool myWasInitialised
Information whether the boundary was initialised.
void reset()
Resets the boundary.
Boundary & grow(SUMOReal by)
extends the boundary by the given amount
SUMOReal xmax() const
Returns maximum x-coordinate.
void add(SUMOReal x, SUMOReal y, SUMOReal z=0)
Makes the boundary include the given coordinate.
void flipY()
flips ymin and ymax
bool partialWithin(const AbstractPoly &poly, SUMOReal offset=0) const
Returns whether the boundary is partially within the given polygon.
bool around(const Position &p, SUMOReal offset=0) const
Returns whether the boundary contains the given coordinate.
SUMOReal zmin() const
Returns minimum z-coordinate.
Position getCenter() const
Returns the center of the boundary.
void growHeight(SUMOReal by)
Increases the height of the boundary (y-axis)
void moveby(SUMOReal x, SUMOReal y, SUMOReal z=0)
Moves the boundary by the given amount.
Boundary()
Constructor - the boundary is unset.