weight poly2poly movements by polygon area
This commit is contained in:
parent
cbfb92a462
commit
9f819e8398
2 changed files with 3 additions and 2 deletions
|
|
@ -872,8 +872,9 @@ var gs_kiri_print = exports;
|
|||
}
|
||||
return;
|
||||
}
|
||||
let area = poly.area();
|
||||
poly.forEachPoint(function(point, index) {
|
||||
dist = startPoint.distTo3D(point);
|
||||
dist = startPoint.distTo3D(point) * area * area;
|
||||
if (dist < mindist) {
|
||||
found = {poly:poly, index:index, point:point};
|
||||
mindist = dist;
|
||||
|
|
|
|||
Loading…
Reference in a new issue