From c0f3faf0dfcb0f4cdb257324b118fa5a121773b3 Mon Sep 17 00:00:00 2001 From: mjwybrow Date: Thu, 9 Aug 2007 04:10:02 +0000 Subject: 2006-08-09 Michael Wybrow * src/libavoid/shape.cpp, src/libavoid/router.cpp, src/libavoid/README, src/libavoid/router.h, src/libavoid/geometry.cpp: Some minor upstream changes to the libavoid library. It now matches Inkscape and uses the correct winding direction. * src/conn-avoid-ref.cpp: Remove a 'TODO' and hack adjusting winding directions before passing object convex hulls to libavoid. (bzr r3431) --- src/libavoid/shape.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/libavoid/shape.cpp') diff --git a/src/libavoid/shape.cpp b/src/libavoid/shape.cpp index 2b241b728..c0ff2f6e8 100644 --- a/src/libavoid/shape.cpp +++ b/src/libavoid/shape.cpp @@ -206,10 +206,10 @@ void ShapeRef::boundingBox(BBox& bbox) { const Point& p = _poly.ps[i]; - a.x = (p.x < a.x) ? p.x : a.x; - a.y = (p.y < a.y) ? p.y : a.y; - b.x = (p.x > b.x) ? p.x : b.x; - b.y = (p.y > b.y) ? p.y : b.y; + a.x = std::min(p.x, a.x); + a.y = std::min(p.y, a.y); + b.x = std::max(p.x, b.x); + b.y = std::max(p.y, b.y); } } -- cgit v1.2.3