Fixed processing of regions in offset()

This commit is contained in:
Revar Desmera 2019-07-17 16:33:08 -07:00
parent 6ce93f75e0
commit cf15742a3b

View file

@ -976,10 +976,10 @@ function offset(
rgn = exclusive_or([for (p = path) [p]]), rgn = exclusive_or([for (p = path) [p]]),
pathlist = sort(idx=0,[ pathlist = sort(idx=0,[
for (i=[0:1:len(rgn)-1]) [ for (i=[0:1:len(rgn)-1]) [
sum([ sum(concat([0],[
for (j=[0:1:len(rgn)-1]) if (i!=j) for (j=[0:1:len(rgn)-1]) if (i!=j)
point_in_polygon(rgn[i][0],rgn[j])>=0? 1 : 0 point_in_polygon(rgn[i][0],rgn[j])>=0? 1 : 0
]), ])),
rgn[i] rgn[i]
] ]
]) ])