nitlanguage
/
nit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f0b0863
)
lib/geometry: do not sort points as it invalidates the shape of the polygon
author
Alexis Laferrière
<alexis.laf@xymus.net>
Mon, 22 Feb 2016 17:39:03 +0000
(12:39 -0500)
committer
Alexis Laferrière
<alexis.laf@xymus.net>
Tue, 23 Feb 2016 17:25:28 +0000
(12:25 -0500)
Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>
lib/geometry/polygon.nit
patch
|
blob
|
history
diff --git
a/lib/geometry/polygon.nit
b/lib/geometry/polygon.nit
index
039fb94
..
94ad1c9
100644
(file)
--- a/
lib/geometry/polygon.nit
+++ b/
lib/geometry/polygon.nit
@@
-444,7
+444,6
@@
end
# Useful for converting a concave polygon into multiple convex ones
fun triangulate(pts: Array[Point[Float]], results: Array[ConvexPolygon]) do
var poly = new Polygon(pts)
- poly.sort_ccw
pts = poly.points
recursive_triangulate(pts, results)
end