Skip to content

Commit fc48e79

Browse files
committed
Fix infill offset if there are no walls
If there are no walls, the infill area will be equal to the part outline, so it should not be offsetted. CURA-7804
1 parent 991edf3 commit fc48e79

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/skin.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ void SkinInfillAreaComputation::generateInfill(SliceLayerPart& part, const Polyg
416416
const size_t wall_line_count = mesh.settings.get<size_t>("wall_line_count");
417417
const coord_t infill_line_distance = mesh.settings.get<coord_t>("infill_line_distance");
418418

419-
coord_t offset_from_inner_wall = -innermost_wall_line_width / 2;
419+
coord_t offset_from_inner_wall = 0;
420420
if (wall_line_count > 0)
421421
{ // calculate offset_from_inner_wall
422422
coord_t extra_perimeter_offset = 0; // to align concentric polygons across layers
@@ -442,7 +442,7 @@ void SkinInfillAreaComputation::generateInfill(SliceLayerPart& part, const Polyg
442442
}
443443
}
444444
}
445-
offset_from_inner_wall += extra_perimeter_offset;
445+
offset_from_inner_wall += extra_perimeter_offset - innermost_wall_line_width / 2;
446446
}
447447
Polygons infill = part.insets.back().offset(offset_from_inner_wall);
448448
infill = infill.difference(skin);

0 commit comments

Comments
 (0)