Bugfix: skip arc compensation when holes are not round

degen-loop-screen
Alessandro Ranellucci 2012-05-02 16:28:47 +02:00
parent 847cf3c5b8
commit dde71418d4
1 changed files with 3 additions and 1 deletions

View File

@ -200,7 +200,9 @@ sub make_perimeters {
my $new_radius = (scale($Slic3r::flow_width) + sqrt((scale($Slic3r::flow_width)**2) + (4*($radius**2)))) / 2;
# holes are always turned to contours, so reverse point order before and after
$hole->reverse;
@$hole = map Slic3r::Point->new($_), @{ +($hole->offset(+ ($new_radius - $radius)))[0] };
my @offsetted = $hole->offset(+ ($new_radius - $radius));
# skip arc compensation when hole is not round (thus leads to multiple offsets)
@$hole = map Slic3r::Point->new($_), @{ $offsetted[0] } if @offsetted == 1;
$hole->reverse;
}