diff options
| author | mjwybrow <mjwybrow@users.sourceforge.net> | 2007-08-09 04:10:02 +0000 |
|---|---|---|
| committer | mjwybrow <mjwybrow@users.sourceforge.net> | 2007-08-09 04:10:02 +0000 |
| commit | c0f3faf0dfcb0f4cdb257324b118fa5a121773b3 (patch) | |
| tree | a11d4b4197e094a41458aec891a5bbc006181927 /src/libavoid/shape.cpp | |
| parent | copyedit, warning suppression (diff) | |
| download | inkscape-c0f3faf0dfcb0f4cdb257324b118fa5a121773b3.tar.gz inkscape-c0f3faf0dfcb0f4cdb257324b118fa5a121773b3.zip | |
2006-08-09 Michael Wybrow <mjwybrow@users.sourceforge.net>
* 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)
Diffstat (limited to 'src/libavoid/shape.cpp')
| -rw-r--r-- | src/libavoid/shape.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
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); } } |
