mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 08:55:58 +08:00
Improvement of region classification numerical stability.
The Clipper library is not stable when calcuating offsets of contours with holes. Replaced a single call of offset2 with offset_ex(offset_ex()). This is not the most efficient solution, but it fixes this problem. Fixes https://github.com/prusa3d/Slic3r/issues/456
This commit is contained in:
parent
eaaac8b2a4
commit
d65835f89b
@ -447,7 +447,8 @@ void PrintObject::detect_surfaces_type()
|
|||||||
to_polygons(upper_layer->get_region(idx_region)->slices.surfaces) :
|
to_polygons(upper_layer->get_region(idx_region)->slices.surfaces) :
|
||||||
to_polygons(upper_layer->slices);
|
to_polygons(upper_layer->slices);
|
||||||
surfaces_append(top,
|
surfaces_append(top,
|
||||||
offset2_ex(diff(layerm_slices_surfaces, upper_slices, true), -offset, offset),
|
//FIXME implement offset2_ex working over ExPolygons, that should be a bit more efficient than calling offset_ex twice.
|
||||||
|
offset_ex(offset_ex(diff_ex(layerm_slices_surfaces, upper_slices, true), -offset), offset),
|
||||||
stTop);
|
stTop);
|
||||||
} else {
|
} else {
|
||||||
// if no upper layer, all surfaces of this one are solid
|
// if no upper layer, all surfaces of this one are solid
|
||||||
|
Loading…
x
Reference in New Issue
Block a user