Fixed a bug introduced in Polygon.cpp Polygon::contains(_
This commit is contained in:
Vojtech Bubnik 2022-08-29 11:52:19 +02:00
parent 37da0956cb
commit c1807d6acd

View file

@ -96,7 +96,7 @@ bool Polygon::contains(const Point &p) const
bool result = false;
Points::const_iterator i = this->points.begin();
Points::const_iterator j = this->points.end() - 1;
for (; i != this->points.end(); j = ++ i)
for (; i != this->points.end(); j = i ++)
if (i->y() > p.y() != j->y() > p.y())
#if 1
if (Vec2d v = (*j - *i).cast<double>();