diff --git a/vcg/space/box2.h b/vcg/space/box2.h index 72a7d5d8..32b5f816 100644 --- a/vcg/space/box2.h +++ b/vcg/space/box2.h @@ -328,13 +328,13 @@ Point2 ClosestPoint2Box2(const Point2 &test, Segs[0].P0() = bbox.min; Segs[0].P1() = vcg::Point2(bbox.max.X(), bbox.min.Y()); - Segs[1].P0() = Segs[0].P(1); + Segs[1].P0() = Segs[0].P1(); Segs[1].P1() = bbox.max; - Segs[2].P0() = Segs[1].P(1); + Segs[2].P0() = Segs[1].P1(); Segs[2].P1() = vcg::Point2(bbox.min.X(), bbox.max.Y()); - Segs[3].P0() = Segs[2].P(1); + Segs[3].P0() = Segs[2].P1(); Segs[3].P1() = bbox.min; Point2 closest = ClosestPoint(Segs[0], test);