mirror of
https://git.mirrors.martin98.com/https://github.com/slic3r/Slic3r.git
synced 2025-05-19 03:37:37 +08:00
Fixed regression causing side gaps in solid infill
This commit is contained in:
parent
c97ced50ff
commit
b360b2bcea
@ -14,9 +14,10 @@ sub fill_surface {
|
|||||||
my $rotate_vector = $self->infill_direction($surface);
|
my $rotate_vector = $self->infill_direction($surface);
|
||||||
$self->rotate_points($expolygon, $rotate_vector);
|
$self->rotate_points($expolygon, $rotate_vector);
|
||||||
|
|
||||||
my ($expolygon_off) = $expolygon->offset_ex(scale 0.2);
|
my ($expolygon_off) = $expolygon->offset_ex(scale 0.3);
|
||||||
return {} if !$expolygon_off; # skip some very small polygons (which shouldn't arrive here)
|
return {} if !$expolygon_off; # skip some very small polygons (which shouldn't arrive here)
|
||||||
my $bounding_box = [ $expolygon_off->bounding_box ];
|
my ($expolygon_epsilon_off) = $expolygon->offset_ex(scale epsilon);
|
||||||
|
my $bounding_box = [ $expolygon->bounding_box ];
|
||||||
|
|
||||||
my $min_spacing = scale $params{flow_spacing};
|
my $min_spacing = scale $params{flow_spacing};
|
||||||
my $distance_between_lines = $min_spacing / $params{density};
|
my $distance_between_lines = $min_spacing / $params{density};
|
||||||
@ -46,7 +47,7 @@ sub fill_surface {
|
|||||||
$x += $distance_between_lines;
|
$x += $distance_between_lines;
|
||||||
}
|
}
|
||||||
my @paths = @{ Boost::Geometry::Utils::polygon_linestring_intersection(
|
my @paths = @{ Boost::Geometry::Utils::polygon_linestring_intersection(
|
||||||
$expolygon->boost_polygon,
|
$expolygon_epsilon_off->boost_polygon,
|
||||||
Boost::Geometry::Utils::linestring(@vertical_lines),
|
Boost::Geometry::Utils::linestring(@vertical_lines),
|
||||||
) };
|
) };
|
||||||
for (@paths) {
|
for (@paths) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user